# I need to create an Alert in case APM stop working. Does Kibana have anything that could help with it?

**URL:** <https://discuss.elastic.co/t/i-need-to-create-an-alert-in-case-apm-stop-working-does-kibana-have-anything-that-could-help-with-it/346070>\
**Category:** APM\
**Tags:** elastic-stack-alerting, java\
**Created:** [October 30, 2023, 8:07pm UTC](https://discuss.elastic.co/t/i-need-to-create-an-alert-in-case-apm-stop-working-does-kibana-have-anything-that-could-help-with-it/346070 "2023-10-30T20:07:07Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![SamuelSMendes](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/samuelsmendes/32/104246_2.png) [@SamuelSMendes](https://discuss.elastic.co/u/SamuelSMendes)\
**Post date:** [October 30, 2023, 8:07pm UTC](https://discuss.elastic.co/t/i-need-to-create-an-alert-in-case-apm-stop-working-does-kibana-have-anything-that-could-help-with-it/346070/1 "2023-10-30T20:07:07Z")

</div>

I've installed multiple Java APM agents and would like to monitor them in a sense that if any stop responding I get an alert. The same principle would be for the Elastic-Agent. I saw some alerts for metrics and logs threshold but couldn't reach a sense for the way to approach.

If anyone could help on this it would be great!

Elastic Cloud 8.5.1

---

<div class="post-metadata">

**Author:** ![Jack\_Shirazi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jack_shirazi/32/91641_2.png) [@Jack\_Shirazi](https://discuss.elastic.co/u/Jack_Shirazi)\
**Post date:** [October 31, 2023, 2:35pm UTC](https://discuss.elastic.co/t/i-need-to-create-an-alert-in-case-apm-stop-working-does-kibana-have-anything-that-could-help-with-it/346070/2 "2023-10-31T14:35:49Z")

</div>

Not directly answering your request, but the Java agent has [health metrics](https://www.elastic.co/guide/en/apm/agent/java/current/metrics.html#metrics-agenthealth) - you would need to enable them and the experimental flag. Then you can choose a metric that should always be non-zero and alert if the value is not \>0 in some interval?

---

<div class="post-metadata">

**Author:** ![SamuelSMendes](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/samuelsmendes/32/104246_2.png) [@SamuelSMendes](https://discuss.elastic.co/u/SamuelSMendes)\
**Post date:** [October 31, 2023, 3:13pm UTC](https://discuss.elastic.co/t/i-need-to-create-an-alert-in-case-apm-stop-working-does-kibana-have-anything-that-could-help-with-it/346070/3 "2023-10-31T15:13:30Z")

</div>

Thank you for the reply, that certainly seems very useful for my case. But I'm not sure as for how I would set it on my configuration.

I configure the APM directly unto the application conf file like this:

```auto
wrapper.java.additional.17 = -javaagent:C:\Program Files\APP SERVICE\elastic-apm-agent-1.43.0.jar
wrapper.java.additional.18 = -Delastic.apm.service_name=APP-SERVICE
wrapper.java.additional.19 = -Delastic.apm.server_urls=https://<host>apm.westus2.azure.elastic-cloud.com:443
wrapper.java.additional.20 = -Delastic.apm.secret_token=<token>
wrapper.java.additional.21 = -Delastic.apm.environment=test
wrapper.java.additional.22 = -Delastic.apm.application_packages=com.hp,com.hpe

```

Is there a specific flag I could add so I have these health metrics?

---

<div class="post-metadata">

**Author:** ![Jack\_Shirazi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jack_shirazi/32/91641_2.png) [@Jack\_Shirazi](https://discuss.elastic.co/u/Jack_Shirazi)\
**Post date:** [October 31, 2023, 6:09pm UTC](https://discuss.elastic.co/t/i-need-to-create-an-alert-in-case-apm-stop-working-does-kibana-have-anything-that-could-help-with-it/346070/4 "2023-10-31T18:09:34Z")

</div>

-Delastic.apm.agent\_reporter\_health\_metrics=true  
-Delastic.apm.agent\_background\_overhead\_metrics=true

---

<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:** [November 28, 2023, 6:09pm UTC](https://discuss.elastic.co/t/i-need-to-create-an-alert-in-case-apm-stop-working-does-kibana-have-anything-that-could-help-with-it/346070/5 "2023-11-28T18:09:57Z")

</div>

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