[
https://issues.apache.org/jira/browse/CHUKWA-384?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12746747#action_12746747
]
Eric Yang commented on CHUKWA-384:
----------------------------------
The charting widget could be modified with the following changes in mind:
{
"id":"rest_metrics",
"title":"Metrics From Rest API",
"version":"0.1",
"categories":"System Metrics,Cluster,Status",
"module":"iframe/jsp/single-series-chart-javascript.jsp",
"description":"Display cluster related stats by percentage",
"screendump":"\/images\/server_load.gif",
"refresh":"15",
"parameters":[
*{"name":"series","type":"string","value":"series_name","edit":"0"},*
*{"name":"data","type":"string","value":"http://localhost:8080/hicc/jsp/test.jsp","edit":"0"},*
{"name":"y_axis_max","type":"string","value":"100","edit":"0"},
{"name":"display_percentage","type":"string","value":"1","edit":"0"},
{"name":"period","type":"custom","control":"period_control","value":"","label":"Period"},
{"name":"width","type":"select","value":"300","label":"Width","options":[{"label":"300","value":"300"},{"label":"1200","value":"1200"}]},
{"name":"height","type":"select","value":"200","label":"Height","options":[{"label":"200","value":"200"},{"label":"1000","value":"1000"}]},
{"name":"legend","type":"radio","value":"on","label":"Show
Legends","options":[{"label":"On","value":"on"},{"label":"Off","value":"off"}]}
]}
By using the *series*,*data* key value pair, it will fetch data from the remote
REST API data source. The remote data source should return:
{"name":"series_name","data":[[x,y],[x2,y2]]}
Multiple data could be submitted, and the system will send ajax request to
fetch each series. Let me know if this works for you.
> REST API for HICC
> -----------------
>
> Key: CHUKWA-384
> URL: https://issues.apache.org/jira/browse/CHUKWA-384
> Project: Hadoop Chukwa
> Issue Type: New Feature
> Reporter: Stephen Nelson
> Assignee: Eric Yang
> Original Estimate: 240h
> Remaining Estimate: 240h
>
> Currently, the HICC graphing JSP is capable of reading any JDBC-compatible
> database and graphing the results, but it isn't able to parse JSON or other
> data from REST data sources. It would be good to define a REST data format
> and add the ability for the HICC graph JSP to request and understand this
> format.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.