|
Data
{
'last-10-minutes': [(timestamp, value), (timestamp, value), ...]
'last-hour': [(timestamp, value), (timestamp, value), ...]
'last-day': [(timestamp, value), ....]
}
timestamp is a Unix timestamp (seconds since 1970-01-01 00:00 GMT).
value is a floating point value.
The different lists have different resolutions: In the last-10-minutes and in the last-hour view, the values are consolidated per minute. The last-day view contains consolidated values every 5 minutes. The resolution dictionary reflects this and contains the value of the resolution in seconds. For example, in the last-day view, a value is consolidated every 5 minutes, which equals 5*60=300 seconds.
Important: Note that all static data is about 3 minutes old. In particular, this also applies to the last-10-minutes view.
Expand /Collapse All Subsections
Request:
Method:
|
GET
|
URL:
|
/cluster/deciders/NODEID/stats/free-memory
|
Arguments:
|
–
|
Response:
Return code
|
Arguments
|
Meaning
|
200
|
|
successfully returned a dictionary with the requested data
(in megabytes)
|
401
|
–
|
no login
|
403
|
–
|
not enough rights
|
404
|
–
|
decider node not found
|
500
|
–
|
internal server error
|
Example:
curl -u admin:admin http://localhost:8087/api/af/2.0/cluster/deciders/192.168.240.1:8086/stats/free-memory
{
"__name": "free-memory",
"__path": "/api/af/2.0/cluster/deciders/192.168.240.1:8086/stats/free-memory/",
"__subnodes": [
"last-10-minutes",
"last-hour",
"last-day"
]
}
To obtain the actual data, you must decide on the resolution that you want:
curl -u admin:admin http://localhost:8087/api/af/2.0/cluster/deciders/192.168.240.1:8086/stats/free-memory/last-hour
{
"__name": "last-hour",
"__path": "/api/af/2.0/cluster/deciders/192.168.240.1:8086/stats/free-memory/last-hour/",
"__subnodes": [],
"data": [
[
1352276474,
45.0
],
[ ..
}
|
Request:
Method:
|
GET
|
URL:
|
/cluster/deciders/NODEID/stats/requests-per-minute
|
Arguments:
|
–
|
Response:
Return code
|
Arguments
|
Meaning
|
200
|
{ ... }
|
successfully returned a dictionary with the requested data
|
401
|
–
|
no login
|
403
|
–
|
not enough rights
|
404
|
–
|
decider node not found
|
500
|
–
|
internal server error
|
Example:
$ curl -u admin:admin -H 'Content-Type: application/json' http://127.0.0.1:8087/api/af/2.0/cluster/deciders/127.0.0.1:8086/stats/requests-per-minute
{
"__name": "requests-per-minute",
"__path": "/api/af/2.0/cluster/deciders/127.0.0.1:8086/stats/requests-per-minute/",
"__subnodes": [
"last-10-minutes",
"last-hour",
"last-day"
]
}
|
Request:
Method:
|
GET
|
URL:
|
/cluster/deciders/NODEID/stats/load
|
Arguments:
|
–
|
Response:
Return code
|
Arguments
|
Meaning
|
200
|
{ ... }
|
successfully returned a dictionary with the requested data
|
401
|
–
|
no login
|
403
|
–
|
not enough rights
|
404
|
–
|
decider node not found
|
500
|
–
|
internal server error
|
Example:
$ curl -u admin:admin http://localhost:8087/api/af/2.0/cluster/deciders/192.168.240.1:8086/stats/load/last-hour
{
"__name": "last-hour",
"__path": "/api/af/2.0/cluster/deciders/192.168.240.1:8086/stats/load/last-hour/",
"__subnodes": [],
"data": [
[
1351785759,
0.51
],
[
1351785819,
0.18
],
...
[
1351789299,
0.16
]
],
"resolution": 60
}
|
Request:
Method:
|
GET
|
URL:
|
/cluster/deciders/NODEID/stats/free-log-diskspace
|
Arguments:
|
–
|
Response:
Return code
|
Arguments
|
Meaning
|
200
|
{ ... }
|
successfully returned a dictionary with the requested data
(in megabytes)
|
401
|
–
|
no login
|
403
|
–
|
not enough rights
|
404
|
–
|
decider node not found
|
500
|
–
|
internal server error
|
|
See also
REST Interface
Managing Deciders
|