Limit tags for the cassandra metrics by jolokia2_agent

I want to limit the tags for the cassandra metrics by jolokia2_agent

  listen = ":9273"
  limit = 10
  keep = ["az", "region"]
 urls = ["http://localhost:7777/jolokia"]

  name = "cassandra_internal"
  mbean = "org.apache.cassandra.internal:*"

  name = "cassandra_metrics"
  mbean = "org.apache.cassandra.metrics:name=*,scope=*,type=DroppedMessage"

  name = "cassandra_db"
  mbean = "org.apache.cassandra.db:*"

metrics produced by org.apache.cassandra.db:* have around 1800 tags. I want to reduce these tags. I have tried processors.tag_limit. But this doesn’t seem to work here.

2022-05-13T14:01:18Z I! Starting Telegraf 1.13.4
2022-05-13T14:01:18Z I! Loaded inputs: exec exec exec exec exec cpu jolokia2_agent
2022-05-13T14:01:18Z I! Loaded aggregators:
2022-05-13T14:01:18Z I! Loaded processors: tag_limit
2022-05-13T14:01:18Z I! Loaded outputs: prometheus_client

in logs I can see Loaded processors.

Am I doing something wrong? how to limit tags for jolokia2_agent.metrics?

If I use the following CSV file as my sample data:

"book","joe cool","usa",34.99,33

with this config:

  omit_hostname = true


  files = ["data.csv"]

  data_format = "csv"
  csv_header_row_count = 1
  csv_tag_columns = ["title", "author", "region"]

Then my data will look like:

file,author=joe\ cool,region=usa,title=book price=34.99,qty=33i 1652721178000000000

If I want to reduce the tags to only the title I can add:

  limit = 1
  keep = ["title"]

that reduces the number of tags to:

file,title=book price=34.99,qty=33i 1652721173000000000

I can also change the limit and start getting a random additional tag as well.

But this doesn’t seem to work here.

Can you share what you are getting? Have you tried setting the limit to 2 for the two tags you want? what happens then?