# Elastic experimental java agent set up

**URL:** <https://discuss.elastic.co/t/elastic-experimental-java-agent-set-up/217955>\
**Category:** APM\
**Tags:** java\
**Created:** [February 5, 2020, 10:12am UTC](https://discuss.elastic.co/t/elastic-experimental-java-agent-set-up/217955 "2020-02-05T10:12:05Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![TomHolik](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tomholik/32/51972_2.png) [@TomHolik](https://discuss.elastic.co/u/TomHolik)\
**Post date:** [February 5, 2020, 10:12am UTC](https://discuss.elastic.co/t/elastic-experimental-java-agent-set-up/217955/1 "2020-02-05T10:12:05Z")

</div>

**Kibana version** :  
6.8.2  
**Fresh install**  
**Wildfly**

Hey, I have a question regarding experimental automatic set up java agent methods.

- [Automatic setup with `apm-agent-attach-standalone.jar`](https://www.elastic.co/guide/en/apm/agent/java/1.x/setup-attach-cli.html)
- [Programmatic API setup to self-attach](https://www.elastic.co/guide/en/apm/agent/java/1.x/setup-attach-api.html)

What does in this case experimental mean? Is it safe to use it on production (bug free and stable) or it just could be replaced/deleted in future?

Thanks

---

<div class="post-metadata">

**Author:** ![felixbarny](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/felixbarny/32/27341_2.png) [@felixbarny](https://discuss.elastic.co/u/felixbarny)\
**Post date:** [February 5, 2020, 10:45am UTC](https://discuss.elastic.co/t/elastic-experimental-java-agent-set-up/217955/2 "2020-02-05T10:45:50Z")

</div>

This is not going to be replaced. We have plans to make this work for OSGi and similar environments in the future, but that requires some refactoring.

See also the caveats section for more details what's not working: [https://www.elastic.co/guide/en/apm/agent/java/1.x/setup-attach-cli.html#setup-attach-cli-caveats](https://www.elastic.co/guide/en/apm/agent/java/1.x/setup-attach-cli.html#setup-attach-cli-caveats)

As a rule of thumb: if it's working for your server (you don't see a wall of exceptions), there's no difference in stability compared to the regular setup.

You might be able to work around those exceptions with some manual OSGi configuration: `org.osgi.framework.bootdelegation=co.elastic.apm.agent.*`

Where to add this varies based on the server and OSGi container. For some, there is already a file which already includes a list of packages. So search for `bootdelegation` in your server directory and add `co.elastic.apm.agent.*` to the existing list.

---

<div class="post-metadata">

**Author:** ![TomHolik](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tomholik/32/51972_2.png) [@TomHolik](https://discuss.elastic.co/u/TomHolik)\
**Post date:** [February 5, 2020, 11:00am UTC](https://discuss.elastic.co/t/elastic-experimental-java-agent-set-up/217955/3 "2020-02-05T11:00:02Z")

</div>

Thanks for fast response! Ok will give it a try

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [February 26, 2020, 7:00am UTC](https://discuss.elastic.co/t/elastic-experimental-java-agent-set-up/217955/4 "2020-02-26T07:00:05Z")

</div>

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