Dynamic configuration with property files
See original GitHub issueHi all, Currently I use elasticapm.properties (put in the same directory as the agent file) to configure the agent. In this file, I’ve following configuration for trace methods:
trace_methods=abc.xyz
trace_methods_duration_threshold=10ms
The configuration works fine until I want to modify trace_methods
. From the documentation, it say that trace_methods
supports dynamic configuration but when I remove or add new methods, it does not reload automatically. I have to restart the application manually to get the config applied.
Can you guys help me to troubleshoot this problem and get dynamic configuration working?
Thanks in advance.
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
How to configure application dynamically via property files
In some use cases, an application needs to define elements through a properties file and to be able to modify these elements dynamically...
Read more >Specifying an Application Configuration Property Dynamically
To specify application configuration properties, you can use the static approach or the dynamic approach. Using the static approach, you specify a property...
Read more >A Simple Implementation of Dynamic Configuration - Medium
With Apache Zookeeper, dynamic configuration properties can be organized in a directory structure such as “/namespace/profile/name”, where each ...
Read more >Dynamically set all properties files at runtime: - Stack Overflow
The only way to dynamically update properties of an app would be to use something like a configuration server. Read about it here....
Read more >How to create and store property file dynamically in Java?
It is represented by the Properties class in Java, you can store a properties file and read from it using the methods of...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I’ve found the issue, it’s a bug 🤦♂
https://github.com/elastic/apm-agent-java/blob/97a3d763a9468fcbb2e9c8a0241a5afecb5186fe/apm-agent-core/src/main/java/co/elastic/apm/agent/bci/ElasticApmAgent.java#L196
it should be
I also think that there is a delay before the configuration getting applied, so I’ve waited for 5 minutes. But nothing changes. It only applies when I restart the service.