How to add label in Java apm agent

Kibana version: 7.4

Elasticsearch version: 7.4

APM Server version: 7.4

APM Agent language and version: java 1.9.0

Hi,

Could you guide to add "label" in java APM agent.

Hi @rijash,

You can use the global_labels configuration option to set labels that will be added to all events, transactions and errors that are created by the agent.

Alternatively, you could also use API to add dynamic tags at runtime by using Span.addTag(...) method.

Thanks Sylbain,

I am able to add the label using "global_labels". But i want the value for the label to be hyperlink.

So, that when i will click the value it will open a different page.

Could you please help me to make the value as hyperlink enabled.

Thanks.

Regards,
Rijash

I am not really sure to understand what do you mean by hyperlink here:
do you want to:

  • provide a tag which value is an URL like https://discuss.elastic.co/ which Kibana should wrap in <a> HTML tag to make it clickable ?
  • provide a tag value that can be used in Kibana to filter items that have the same tag by just clicking it

The first one is not supported for security as it would allow anyone with access to the application code to inject arbitrary links into Kibana UI.

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.