influxdata / influxdata/kapacitor
Group by part of tag
- Dominant language
- Go
- Stars
- 2.4k
- Forks
- 479
- Avg merge
- 4d 16h
- Merged PRs (30d)
- 4
Description
Hi,
I have a field and some tags and I am trying to aggregate them per 10s using either stream (preferrable) or batch.
So far it is working fine, but now I need to **aggregate using only a part of one of the tags**.
E.g. (let's say these happened within the same 10s and I use mean to aggregate):
|machine |area |CPU|
|-----|---|---|
|A01 |RF12 |12|
|A02 |XF93 |08|
|A03 |RF12 |16|
|B01 |AF02 |14|
I want to use only the first digit of the machine, so the result to be:
|machine |area |CPU|
|-----|---|---|
|A |RF12 |14|
|A |XF93 |08|
|B |AF02 |14|
Any ideas on how this could be done?
Thank you!
Contributor guide
Research direction
No source files, tests, or entry points are identified in the issue. Start by locating Kapacitor's stream and batch grouping or aggregation behavior, then define the intended tag-part grouping and a test using the sample data; done means it produces the three shown groups.
Written by the indexing model from the issue text.
Assessment
- Domain
- stream-processing
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100