# APM Integration Issue

**URL:** <https://discuss.elastic.co/t/apm-integration-issue/345468>\
**Category:** APM\
**Tags:** python\
**Created:** [October 20, 2023, 1:26pm UTC](https://discuss.elastic.co/t/apm-integration-issue/345468 "2023-10-20T13:26:28Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![fenixon](https://avatars.discourse-cdn.com/v4/letter/f/77aa72/32.png) [@fenixon](https://discuss.elastic.co/u/fenixon)\
**Post date:** [October 20, 2023, 1:26pm UTC](https://discuss.elastic.co/t/apm-integration-issue/345468/1 "2023-10-20T13:26:28Z")

</div>

{"log.level":"error","@timestamp":"2023-10-20T13:15:35.973Z","log.logger":"agentcfg","log.origin":{"file.name":"agentcfg/elasticsearch.go","file.line":134},"message":"refresh cache error: context deadline exceeded","service.name":"apm-server","ecs.version":"1.6.0"}  
{"log.level":"error","@timestamp":"2023-10-20T13:15:45.979Z","log.logger":"beater","log.origin":{"file.name":"beater/waitready.go","file.line":64},"message":"precondition failed: EOF","service.name":"apm-server","ecs.version":"1.6.0"}

I got this error in the apm-server.log file.

When i run the test command of elasticapm test it gives the success message. But i dont see the data in apm tab in kibana

D:\Master\ceburu-python\>python manage.py elasticapm test  
Trying to send a test error to APM Server using these settings:

SERVICE\_NAME: ceb-apm-service-local  
SECRET\_TOKEN: EFFHB8U3RQKS29T79Z2Y  
SERVER: [https://x.x.x.x.com:8200](https://x.x.x.x.com:8200)

Success! We tracked the error successfully!  
You should see it in the APM app in Kibana momentarily.  
Look for "TestException: Hi there!" in the Errors tab of the ceb-apm-service-local app

---

<div class="post-metadata">

**Author:** ![axw](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/axw/32/28197_2.png) [@axw](https://discuss.elastic.co/u/axw)\
**Post date:** [October 23, 2023, 1:55am UTC](https://discuss.elastic.co/t/apm-integration-issue/345468/2 "2023-10-23T01:55:10Z")

</div>

> [@fenixon](#):
>
> {"log.level":"error","@timestamp":"2023-10-20T13:15:35.973Z","log.logger":"agentcfg","log.origin":{"file.name":"agentcfg/elasticsearch.go","file.line":134},"message":"refresh cache error: context deadline exceeded","service.name":"apm-server","ecs.version":"1.6.0"}  
> {"log.level":"error","@timestamp":"2023-10-20T13:15:45.979Z","log.logger":"beater","log.origin":{"file.name":"beater/waitready.go","file.line":64},"message":"precondition failed: EOF","service.name":"apm-server","ecs.version":"1.6.0"}

apm-server is having trouble connecting to Elasticsearch. A couple of suggestions:

- double check that the Elasticsearch configuration in apm-server.yaml is correct
- check if you can successfully connect to/query Elasticsearch from the same machine on which apm-server is running

---

<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 20, 2023, 1:55am UTC](https://discuss.elastic.co/t/apm-integration-issue/345468/3 "2023-11-20T01:55:56Z")

</div>

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