ambari-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jonathan Hurley (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (AMBARI-7021) Alerts: Create Group and Target REST Endpoints
Date Thu, 28 Aug 2014 00:52:58 GMT

    [ https://issues.apache.org/jira/browse/AMBARI-7021?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14113132#comment-14113132
] 

Jonathan Hurley commented on AMBARI-7021:
-----------------------------------------

Example of the AlertGroup endpoints:

GET api/v1/clusters/c1/alert_groups
{code}
{
  "href" : "http://localhost:8080/api/v1/clusters/c1/alert_groups",
  "items" : [
    {
      "href" : "http://localhost:8080/api/v1/clusters/c1/alert_groups/3",
      "AlertGroup" : {
        "cluster_name" : "c1",
        "default" : false,
        "id" : 3,
        "name" : "HDFS Critical Ones"
      }
    },
    {
      "href" : "http://localhost:8080/api/v1/clusters/c1/alert_groups/10",
      "AlertGroup" : {
        "cluster_name" : "c1",
        "default" : false,
        "id" : 10,
        "name" : "Test"
      }
    }
  ]
}
{code}

GET api/v1/clusters/c1/alert_groups/10
{code}
{
  "href" : "http://localhost:8080/api/v1/clusters/c1/alert_groups/10",
  "AlertGroup" : {
    "cluster_name" : "c1",
    "default" : false,
    "definitions" : [
      {
        "name" : "namenode_process",
        "label" : "NameNode Process",
        "service_name" : "HDFS",
        "component_name" : "NAMENODE",
        "id" : 4
      },
      {
        "name" : "secondary_namenode_process",
        "label" : "Secondary NameNode Process",
        "service_name" : "HDFS",
        "component_name" : "SECONDARY_NAMENODE",
        "id" : 2
      },
      {
        "name" : "datanode_process",
        "label" : "DateNode Process",
        "service_name" : "HDFS",
        "component_name" : "DATANODE",
        "id" : 3
      }
    ],
    "id" : 10,
    "name" : "Test",
    "targets" : [
      {
        "name" : "Administrators",
        "properties" : null,
        "id" : 4,
        "description" : "The Admins",
        "notification_type" : "EMAIL"
      }
    ]
  }
}
{code}

GET v1/alert_targets
{code}
{
  "href" : "http://localhost:8080/api/v1/alert_targets",
  "items" : [
    {
      "href" : "http://localhost:8080/api/v1/alert_targets/4",
      "AlertTarget" : {
        "id" : 4,
        "name" : "Administrators"
      }
    }
  ]
}
{code}

GET v1/alert_targets/4
{code}
{
  "href" : "http://localhost:8080/api/v1/alert_targets/4",
  "AlertTarget" : {
    "description" : "The Admins",
    "id" : 4,
    "name" : "Administrators",
    "notification_type" : "EMAIL",
    "properties" : null
  }
}
{code}

> Alerts: Create Group and Target REST Endpoints
> ----------------------------------------------
>
>                 Key: AMBARI-7021
>                 URL: https://issues.apache.org/jira/browse/AMBARI-7021
>             Project: Ambari
>          Issue Type: Task
>    Affects Versions: 1.8.0
>            Reporter: Jonathan Hurley
>            Assignee: Jonathan Hurley
>             Fix For: 1.8.0
>
>
> Add the initial REST endpoints for interacting with alert targets and groups. 



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message