Cluster Nodes Report

GET /api/v1.2/reports/cluster_nodes

This API provides the cluster nodes report in JSON format.

Note

  • If the difference between the start and end dates is greater than 60 days, the system defaults to a 1-month window from the current date.
  • If either the start date or end date is not provided, then the system defaults to a 1-month window from the current date.
  • To get data for a window that is greater than 60 days, create a ticket with Qubole Support.

Required Role

The following users can make this API call:

  • Users who belong to the system-user or system-admin group.
  • Users who belong to a group associated with a role that allows viewing cluster nodes reports. See Managing Groups and Managing Roles for more information.

Parameters

Parameter Description
start_date The date from which you want the report (inclusive). This parameter supports the timestamp in the UTC timezone (YYYY-MM-DDTHH:MM:SSZ) format. The date cannot be earlier than 90 days.
end_date The date until which you want the report (inclusive). The API default is today. This parameter also supports timestamp in the UTC timezone (YYYY-MM-DDTHH:MM:SSZ) format.

Response Parameters

Parameter Description
start_date The starting date of the report.
end_date The ending date of the report.

An array of:

role The role of the instance (master or worker).
cluster_id The ID of the cluster.
public_ip The public hostname of the cluster node.
ec2_instance_id The ec2 instance ID of the cluster node.
private_ip The private hostname of the cluster node.
start_time The time at which the cluster node was started.
end_time The time at which the cluster node was terminated.

Examples

Goal

To get the default report.

curl -i -X GET -H "X-AUTH-TOKEN: $AUTH_TOKEN" \
-H "Accept: application/json" \
"https://api.qubole.com/api/v1.2/reports/cluster_nodes"

Note

The above syntax uses https://api.qubole.com as the endpoint. Qubole provides other endpoints to access QDS that are described in Supported Qubole Endpoints on Different Cloud Providers.

Goal

To get the report for clusters online during a specific time period.

curl -i -X GET -H "X-AUTH-TOKEN: $AUTH_TOKEN" \
-H "Accept: application/json" \
"https://api.qubole.com/api/v1.2/reports/cluster_nodes?start_date=2014-04-01&end_date=2014-04-21"

Note

The above syntax uses https://api.qubole.com as the endpoint. Qubole provides other endpoints to access QDS that are described in Supported Qubole Endpoints on Different Cloud Providers.

Sample Response

{
  "end_date": "2014-04-21T10:00:00Z",
  "cluster_nodes": [
    {
      "ec2_instance_id":"i-437ad9ac",
      "private_ip":"ip-10-40-7-209.ec2.internal",
      "start_time":"2015-02-12T06:59:42Z",
      "role":"master",
      "public_ip":"ec2-23-20-255-83.compute-1.amazonaws.com",
      "end_time":"2015-02-12T08:13:52Z",
      "cluster_id":10268
    },
    {
      "ec2_instance_id":"i-887bd867",
      "private_ip":"ip-10-165-32-171.ec2.internal",
      "start_time":"2015-02-12T06:59:42Z",
      "role":"node0001",
      "public_ip":"ec2-54-144-51-140.compute-1.amazonaws.com",
      "end_time":"2015-02-12T08:13:52Z",
      "cluster_id":10268
    }
  ],
  "start_date": "2014-04-01T05:00:00Z"
}