AutoDetect – BETA

Available APIs

/api/autodetect/applications/

Detect application components for selected servers.

GET

Lists only logs related to transactions.

Attributes

Node

id (read-only) Unique ID for Application Component Template in our system.
Name (read-only) The name of the Application Component Template.
existing_process_groups (read-only) Existing application component with associated servers.
servers (read-only) List of servers that match template.
polled_data (read-only) Suggested Polled Data elements for this component.
logs (read-only) Suggested Logs for this component.
alerts (read-only) Suggested Alerts for this component.

Arguments

  • s – List of server id’s.
curl --user {EMAIL}:{API_KEY} https://wwws.appfirst.com/api/api/autodetect/applications/?s[]=10&s[]=11&s[]=12
{
    "id": 35, 
    "name": "HBase v0.94",
    "existing_process_groups": [], 
    "servers": [
        {
            "nickname": "hbase1-hbmaster0", 
            "id": 10
        }, 
        {
            "nickname": "hbase1-hbregion1", 
            "id": 11
        }
    ],
    "polled_data": [
        {
            "detail": "jmx_command[sys.app.Hbase.stores] -P org.apache.hadoop.hbase.regionserver.HRegionServer -O hadoop:service=RegionServer,name=RegionServerStatistics -A stores", 
            "name": "sys.app.Hbase.stores", 
            "id": 516
        }, 
        {
            "detail": "python /usr/share/appfirst/plugins/libexec/check_hbase.py --callQueueLength", 
            "name": "hbase_callQueueLength", 
            "id": 481
        }, 
        {
            "detail": "python /usr/share/appfirst/plugins/libexec/check_hbase.py --blockCacheExpressCachingRatio", 
            "name": "hbase_blockCacheExpressCachingRatio", 
            "id": 480
        }
    ], 
    "logs": [
        {
            "id": 74, 
            "name": "/var/log/hbase/*.log", 
            "detail": "FILE"
        }
    ], 
    "alerts": [
        {
            "id": 51, 
            "name": "hbase_average_response_time", 
            "detail": "Network (Average Response Time) above 500 milliseconds for 1 min"
        }, 
        {
            "id": 52, 
            "name": "hbase_network_connections", 
            "detail": "Network (Number of Connections) above 500 for 1 min"
        }
    ], 
}, 

/api/autodetect/resources/

Create resources for an Application Component

PUT

Create a new Application Component or add to an existing Application Component

Arguments

  • app_id – Id of the Application Component Template
  • new_process_group_name – Name of new Application Component if creating new (optional – only needed when creating new)
  • process_group_id – Id of existing Application Component (optional – only needed if adding to existing)
  • servers – List of servers to include in component.
  • logs – List of log id’s from auto detect to include in component.
  • alerts – List of alert id’s from auto detect to include in component.
  • polled_data – List of polled data id’s from auto detect to include in component.

Arguments Example

curl --user {EMAIL}:{API_KEY} https://wwws.appfirst.com/api/autodetect/resources/ -X PUT -d "app_id=35&new_process_group_name=HBase v0.94&servers=[10,11]&logs=[74]&alerts=[51,52]"
{
    "message": "success" 
}