Managing Performance Service Configuration

You can perform operations to see and update the configuration of the performance service.

Performance Service Management Methods URL

Retrieve current running configuration

Configure a performance object

Execute a trace query

Performance Service Management Methods

GET /{cluster_id}/perf/config

Retrieve all performance service configurations

Path arguments: cluster_id: The ID of a cluster returned from GET /cluster-configs.

Returns a list of configurations which are dictionaries containing a 'name' property equal to the performance objects’s JMX mbean’s name, the rest of the properties match the configurable attributes to the object.

Example:

 curl http://127.0.0.1:8888/Test_Cluster/perf/config

Output:

        [
            {
                "refreshRate": 80000,
                "enabled": true,
                "name": "SolrUpdateHandlerStats",
                "ttl": 86400
            },
            {
                "refreshRate": 60000,
                "enabled": false,
                "name": "SolrRequestHandlerStats",
                "ttl": 604800
            },
            ...
        ]

POST /{cluster_id}/perf/config

Configure a list of performance objects. These would be applied immediately via jmx and update the dse.yaml to survive across reboots.

Path arguments: cluster_id: The ID of a cluster returned from GET /cluster-configs.

Body: A JSON array of dictionaries describing the attributes of the performance objects.

Response 200: Configurations applied successfully.

Example:

 curl -X POST
   http://127.0.0.1:8888/Test_Cluster/perf/config
   -d '[
     {
         "refreshRate": 80000,
         "enabled": true,
         "name": "SolrUpdateHandlerStats",
         "ttl": 86400
     },
     {
         "refreshRate": 60000,
         "enabled": true,
         "name": "SolrRequestHandlerStats",
         "ttl": 604800
     }
 ]'

POST /{cluster_id}/perf/trace

Executes a query with trace enabled and returns details of the execution.

Path arguments: cluster_id: The ID of a cluster returned from GET /cluster-configs.

Body: A JSON dictionary detailing the query to run.

Response 200: with the details of the execution.

Trace Option Description

consistency

consistency level with which to run the query

node

the node to function as coordinator

keyspace

keyspace from which to run query

query

query to run

Example:
 curl -X POST
   http://127.0.0.1:8888/Test_Cluster/perf/config
   -d '{"node": "127.0.0.1",
        "query": "select * from events",
        "keyspace": "system_traces",
        "consistency":"ALL"}'