-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cc-tile-metrics: init small metrics tile component for overview #240
Comments
Applications metrics in Clever Cloud
Summary :Metrics are store as geotime series (GTS) in Warp 10. A geotime series contains two parts :
RAM / CPU
Fetching the dataThe fetch endpointCall the Warp 10 fetch endpoint (https://www.warp10.io/content/03_Documentation/03_Interacting_with_Warp_10/04_Fetching_data/01_Fetching_data)
curl -vvv -H 'X-Warp10-Token: <READ_TOKEN>' 'https://c1-warp10-clevercloud-customers.services.clever-cloud.com/api/v0/fetch?&now=now×pan=P1H&selector=mem.available_percent\{app_id=app_958b2ff1-XXXX-XXXX-XXXX-XXXXXXXXXXXX\}&format=json'
The exec endpointCall the Warp 10 exec endpoint (https://www.warp10.io/content/03_Documentation/03_Interacting_with_Warp_10/09_Analysing_data) exec a warpscript.
curl -X POST --data @warpscript.mc2 'https://c1-warp10-clevercloud-customers.services.clever-cloud.com/api/v0/exec'
outputThe output is a list of GTS looking like as followed
Handle the granularity / How to split on instancesIn Clever Cloud, each instance has is owned Hence, we have this ordinal inclusion rules : In other words, each GTS (dictionary) in the output list should be an instance. Token / RightsThere is a token api in Clever Cloud to get the right token depending of the user If we need something more complex or a more specific output, easier to be handle ?
Increase performanceMany things can be done to increase Fetch performance. As not many points are needed for this component. The data can be sample during the fetch using the ex : curl -vvv -H 'X-Warp10-Token: TOKEN.' 'https://c1-warp10-clevercloud-customers.services.clever-cloud.com/api/v0/fetch?&now=now×pan=P1H&sample=0.01&selector=mem.available_percent\{app_id=app_XXX\}&format=json' |
I highly recommand to use the |
@Galimede Here are some details:
^^ Those are just ideas, I'll let you see what's best. |
TODO:
|
@Galimede Note for later, now that we chose to select "round" hours time windows, the number is not the live one. We need to discuss this. |
Feedbacks:
|
We need to move colors to the theme and reuse tokens |
Blocked by: CleverCloud/clever-client.js#70 |
Display
We need a small tile component to display some rough metrics (CPU and RAM).
Details about the chart
Inputs
Outputs
None
Wording / i18n
Data & smart component integration
The text was updated successfully, but these errors were encountered: