chukwa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bill Graham (JIRA)" <j...@apache.org>
Subject [jira] Updated: (CHUKWA-515) REST API for Agent
Date Fri, 03 Sep 2010 19:29:33 GMT

     [ https://issues.apache.org/jira/browse/CHUKWA-515?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Bill Graham updated CHUKWA-515:
-------------------------------

    Attachment: CHUKWA-515-1.patch

Attaching CHUKWA-515-1.patch, which has full CRUD support. The read API is as described above.
The add and delete APIs can be tested with commands like this:

{noformat}
# AdaptorParms is optional in the event that the adaptor doesn't take params.
# Offset is optional and defaults to 0
curl -d '{ "DataType" : "TestDataType", "AdaptorClass" : "org.apache.hadoop.chukwa.util.ConstRateAdapr",
"AdaptorParams" : "1000", "Offset" : "0" }' -H "Content-Type: application/json" http://localhost:9094/rest/v1/adaptor

curl -X DELETE http://localhost:9094/rest/v1/adapto/[adaptor_id]
{noformat}

I've included a generic {{OffsetStatsManager}} in {{org.apache.hadoop.chukwa.datacollection}}
that can be used by anything that tracks data by offset from a given point. This could be
useful on the collector if we were to implement a similar collector REST API.

Let me know if you have any comments about the API, the request format, the response format,
variable names, whatever. 

> REST API for Agent
> ------------------
>
>                 Key: CHUKWA-515
>                 URL: https://issues.apache.org/jira/browse/CHUKWA-515
>             Project: Chukwa
>          Issue Type: Sub-task
>          Components: data collection
>            Reporter: Bill Graham
>            Assignee: Bill Graham
>         Attachments: CHUKWA-515-1.patch
>
>
> Develop a REST interface for the Agent to expose Adaptor CRUD operations.
> * Request URI:
> {noformat}
> GET /rest/v1/adaptor HTTP/1.0
> {noformat}
> * For now I'm shooting for the XML and plain text response, but ultimately we can support
optional params:
> {noformat}
> viewType=[json|xml|text] (default is XML?)
> {noformat}
> I'm planning on using Jetty similar to how the collector does. We could have some common
code that delegates requests to different handlers based on the URI. The current telnet interface
will remain as-is.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message