I am using the apm Java agent attached to a Spring application without any custom spans or transactions.
Is it possible to change or filter out the user metadata? Metadata | APM Overview [7.15] | Elastic
The user.name field get's populated automatically, but I don't want to store that value. Santize configuration is not helpful here unfortunately.
Technically you could set -Duser.name=something but the user.name is used extensively within applications as well as the agent, for example to determine the home directory and which user is running the process, so I suspect it would break things. You could post-facto sanitize the value held in the elastic database, eg regularly running a batch "anonymizing" procedure?
In my case the user.name field seems to be populated from Spring context (and is set to the name of user with active session), the -Duser.name flag doesn't seem to have any effect on that.
The transaction API has a setUser method, but I don't think I can use it together with attached agent, right?
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.