feat!: consume collectd data using a flow#6
Conversation
There was a problem hiding this comment.
There are 3 alternatives:
- Improve that script to handle the case of
collectdmessages with more than one values. - use the script provided by feat: translate collect metrics into tedge measurements tedge-flows-examples#121.
- Extend tedge flows with a builtin
collectdtransformation.
My preference is for the first option: simple and less dependencies across independent repos.
There was a problem hiding this comment.
We decided for option 1.
- feat: translate collect metrics into tedge measurements tedge-flows-examples#121 will be closed
- The script of that PR has been updated to take care of
collectdmessages with more than one values.
|
|
||
| steps = [ | ||
| { script = "collectd-to-te-measurements.js" }, | ||
| { builtin = "group-measurements", interval = "1s", config = { time_window = "500ms" } }, |
There was a problem hiding this comment.
Using group-measurements introduces a dependency on the version of thin-edge that will integrate thin-edge/thin-edge.io#4136.
To have a simpler dependency on 2.0.0, we can comment out this line.
There was a problem hiding this comment.
Finally, we decided to release a temporary solution with a script group-measurements.js.
See c7e0b73
There was a problem hiding this comment.
@didier-wenzek I pushed a commit to add an explicit dependency on thin-edge.io >= 2.0.0, 99c3588
ccae09f to
c7e0b73
Compare
| group: tedge | ||
| owner: tedge | ||
| - src: ./src/collectd | ||
| dst: /etc/tedge/mappers/local/flows/collectd/ |
There was a problem hiding this comment.
I pushed a fix (d1b5c6c) to the dst folder as it was missing the collectd/. Previously it didn't have the collectd/ suffix, so it resulted in the flow.toml being placed at /etc/tedge/mappers/local/flows/flow.toml
| version = "1.0.0" | ||
| description = "Convert collectd messages to thin-edge.io measurements" |
There was a problem hiding this comment.
I added some minor meta information just so it is more descriptive when using tedge flows list --mapper local.
reubenmiller
left a comment
There was a problem hiding this comment.
I pushed a few very minor fixes after testing the new package manually in the tedge-demo-container, but overall it works nicely.
|
@didier-wenzek You'll have to squash the fix-up commits that I added before merging (as we don't have PR checks to block them). |
Signed-off-by: Didier Wenzek <didier.wenzek@free.fr>
This is a temporary solution, waiting for tedge builtin flow transformer `group-measurements` Signed-off-by: Didier Wenzek <didier.wenzek@free.fr>
d1b5c6c to
283d691
Compare
tedge-mapper-collectdbeing deprecated: use a flow to consumecollectddata