psm analytics stop

Use this command to stop a service created with Oracle Analytics Cloud - Classic.

Syntax

In the following syntax, line breaks have been added for clarity. Do not include them when entering the command.

psm analytics stop -s|--service-name service-name 
  -c|--config-payload path-to-json-payload
    [-of|--output-format json|html|short]

Parameters

All parameters are required unless otherwise noted.

Parameter Description

-s|--service-name service-name

Specifies the name of the service.

-c|—config-payload

Path to the JSON file that contains the configuration parameters for accessing the service.

-of|-–output-format (Optional) Desired output format.

Accepted values: json, html, short

JSON Payload

The JSON payload has the following syntax:

{
    "force":"",
    "allServiceHosts":"",
    "components":{
        "analytics":{
            "hosts":""
        }
    }
}
Parameter Description

force

(Optional) Set to True to force the operation, even if blocking errors are generated.

allServiceHosts

(Optional) Set to True to apply the command to all host names associated with the service name. This parameter can be the only parameter in the payload.

components

Container for the analytics component and host information.

analytics

The service type.

hosts

The host name of the service. The host name is the fully qualified name of the Virtual Machine. For example, in a service named analytics, the host name takes the format analytics-bi-1.

Examples

The following example stops the Example1Service service.

$ psm analytics stop -s Example1Service -c /tmp/stop-service-payload.json 
"Accepted"
Job ID : 34348

The payload for this command can be one of the following:

{
    "components":{
        "analytics":{
            "hosts":"[Example1Service-bi-1]"
        }
    }
}

or

{
    "allServiceHosts":"true"
}

Note that this command returns a job ID. To see the status of your stop operation, use this ID with the psm analytics operation-status command:

$ psm analytics operation-status -j 34348

When you see the message:

    "operationId":364,
    "operationType":"STOP_SERVICE",
    "serviceId":364,
    "serviceName":"Example1Service",
    "serviceType":"analytics",
    "startDate":"2017-02-28T21:08:31.022+0000",
    "status":"SUCCEED",
    "summaryMessage":"STOP_SERVICE"

the service was successfully stopped.