Coder Social home page Coder Social logo

elastic / apm-contrib Goto Github PK

View Code? Open in Web Editor NEW
29.0 310.0 44.0 1.33 MB

Contrib repository for Elastic APM

Home Page: https://www.elastic.co/solutions/apm

License: Apache License 2.0

Java 59.48% Dockerfile 6.83% Go 4.00% JavaScript 8.38% Python 8.04% Shell 13.27%

apm-contrib's Introduction

Elastic APM Elastic APM Contrib

This repository includes contributions for Elastic APM.

What we doโ€ฆ

Project Repo Docs Contrib
APM Server apm-server ๐Ÿ“˜ elastic.co ๐Ÿ“‚ contrib
APM UI apm-ui ๐Ÿ“˜ elastic.co ๐Ÿ“‚ contrib
Android Agent (๐Ÿšง In Development) apm-agent-android ๐Ÿ“˜ elastic.co ๐Ÿ“‚ contrib
Go Agent apm-agent-go ๐Ÿ“˜ elastic.co ๐Ÿ“‚ contrib
iOS Agent (๐Ÿšง In Development) apm-agent-ios ๐Ÿ“˜ elastic.co ๐Ÿ“‚ contrib
Java Agent apm-agent-java ๐Ÿ“˜ elastic.co ๐Ÿ“‚ contrib
JavaScript RUM Agent apm-agent-rum-js ๐Ÿ“˜ elastic.co ๐Ÿ“‚ contrib
.NET Agent apm-agent-dotnet ๐Ÿ“˜ elastic.co ๐Ÿ“‚ contrib
Node.js Agent apm-agent-nodejs ๐Ÿ“˜ elastic.co ๐Ÿ“‚ contrib
PHP Agent apm-agent-php ๐Ÿ“˜ elastic.co ๐Ÿ“‚ contrib
Python Agent apm-agent-python ๐Ÿ“˜ elastic.co ๐Ÿ“‚ contrib
Ruby Agent apm-agent-ruby ๐Ÿ“˜ elastic.co ๐Ÿ“‚ contrib

APM Contrib Repository

This is a collection of code and recipes to be used in conjunction with Elastic APM. The code here is not necessarily maintained by the core Elastic APM Team.

Contributing

All contributions are welcome: recipes, visualizations, dashboards, ingest processors, ideas, documentation, and even something you drew up on a napkin.

For more information about contributing, see the relevant CONTRIBUTING file:

Community Developed Agents

The following agents are developed and maintained by members of the community.

Project Repo Docs Notes
Meteor Agent kschingiz/meteor-elastic-apm ๐Ÿ“˜ README

apm-contrib's People

Contributors

alexanderwert avatar astorm avatar axw avatar beniwohli avatar bmorelli25 avatar dependabot[bot] avatar felixbarny avatar formgeist avatar graphaelli avatar hmdhk avatar jahtalab avatar jonaskunz avatar mdindoffer avatar mikker avatar sergeykleyman avatar sorenlouv avatar sylvainjuge avatar v1v avatar watson avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

apm-contrib's Issues

[APM] APM Dashboards and Visualizations Break when apm-* is not Default Index Pattern and Auto Refresh On

Kibana version: 6.6.0, 6.5.1, 6.5.4 (tested)

Elasticsearch version: 6.6.0, 6.5.1, 6.5.4 (tested)

Server OS version: MacOS and Ubuntu 18.04.1

Browser version: Chrome Version 71.0.3578.98 (Official Build) (64-bit)

Browser OS version: macOS 10.14.1 (18B75)

Original install method (e.g. download page, yum, from source, etc.):
Docker on Mac
.deb on Ubuntu

Describe the bug:
When the apm-* index pattern is not selected as the default index patterns AND Auto Refresh is On the APM Dashboards and Visualizations break and respond with โ€œNo data to display for the selected metrics .โ€œ or simply are missing the data.
Examples:
Dashboard / [APM] Services
Dashboard / [APM] Transactions
Visualize / Transaction Per Minute [APM]

Steps to reproduce:

  1. Install Elasticsearch, Kibana, and APM Server and properly configure so they all communicate.

  2. Load Kibana APM Dashboards.

  3. Install a client APM Application and Generate and Send APM Data

For Quick setup of all this you can use this docker-compose
https://gist.github.com/bvader/9665fa7b3bd69457517e41a7c28b4725

And this for the application. It is a Java Spring Boot App.
https://gist.github.com/bvader/cc9fea7e6f8f709dfa2ad14776eed7fe

  1. Load other data and create another index pattern. Example install another beat e.g. metricbeat or filebeat and properly configure, setup and start this should create another index pattern... or you can just create your own new data and index pattern manually.

  2. Set the Default Index Pattern to a pattern other than apm-*

  3. Navigate to an APM Dashboard or Visualization such as Dashboard / [APM] Services
    Set the Time Frame to Last 15 Minutes
    Set Auto Refresh to 5 sec.

  4. Observe when first refresh occurs that โ€œNo data to display for the selected metrics .โ€œ message is displayed for Dashboard / [APM] Services

  5. If you select another dashboard such as Dashboard / [APM] Transaction you will just see no data reported / flat line where the data should be.

  6. Go back and set apm-* as the default and navigate back to the Dashboards and observe the Dashboards and visualizations work correctly.

Expected behavior:
The APM Dashboards and APM Visualization should properly display the visualizations / data with automatic refresh on when apm-* is not selected as the Default Index Pattern.

Screenshots (if relevant):

Dashboard / [APM] Services
apm-* is set as Default Index Pattern and Auto Refresh On

screen shot 2019-01-25 at 11 40 21 am

Dashboard / [APM] Services
apm-* is not set as Default Index Pattern and Auto Refresh On

screen shot 2019-01-25 at 11 40 05 am

Dashboard / [APM] Transactions
apm-* is set as Default Index Pattern and Auto Refresh On

screen shot 2019-01-25 at 11 39 10 am

Dashboard / [APM] Transactions
apm-* is not set as Default Index Pattern and Auto Refresh On

screen shot 2019-01-25 at 11 39 30 am

Errors in browser console (if relevant):

Provide logs and/or server output (if relevant):

Any additional context:

Test results: Load dashboards from apm-contrib. 7.x viz will only show 7.x data

In this test we have to check that the data show in the apm-contrib dashboards for the 7.x version only show 7.x data.

Test steps

  • Prepare a couple of Docker compose files one for 6.6.1 and another for 7.0.0-rc1, to make it I have used the integration test tool compose.py
    • Run ./script/compose.py start 6.6.1 --release --with-agent-go-net-http then docker-compose -f docker-compose.yml stop
    • Rename docker-compose.yml file to docker-compose-6.6.1.yml
    • Run ./script/compose.py start 7.0.0-rc1 --bc --with-agent-go-net-http then docker-compose -f docker-compose.yml stop
    • Rename docker-compose.yml file to docker-compose-7.0.0-rc1.yml
    • edit the files to use the same Docker volume
      • Change `"path.data=/usr/share/elasticsearch/data/6.6.1" to "path.data=/usr/share/elasticsearch/data/esdata" on docker-compose-6.6.1.yml
      • Change `"path.data=/usr/share/elasticsearch/data/7.0.0" to "path.data=/usr/share/elasticsearch/data/esdata" on docker-compose-7.0.0-rc1.yml
  • Start 6.6.1 docker-compose -f docker-compose-6.6.1.yml up -d
  • Configure APM
  • Generate some data accesing to http://localhost:8080/foo-6.6.1, http://localhost:8080/foo, and http://localhost:8080/oof
  • Check that the data is show in the APM UI
  • Stop 6.6.1 docker-compose -f docker-compose-6.6.0.yml stop
  • Wait a couple of minutes to have a time gap between the data
  • Start 7.0.0-rc1 docker-compose -f docker-compose-7.0.0-rc1.yml up -d
  • Generate some data accesing to http://localhost:8080/foo-7.0.0-rc1, http://localhost:8080/foo, and http://localhost:8080/oof
  • Download the dashboards from https://github.com/elastic/apm-contrib/tree/master/apm-ui/7.x
  • Import the dashboard on kibana
  • Check that the data show in the dashboards is only from 7.0.0-rc1 version

Issues found

  • On 7.0.0-rc1, when I go to Discover it said that some shards failed and I see a bunch of the following error in the logs, the solution it is to remove the index pattern and create it again.
{"type": "server", "timestamp": "2019-03-22T10:51:24,993+0000", "level": "DEBUG", "component": "o.e.a.s.TransportSearchAction", "cluster.name": "docker-cluster", "node.name": "c95aab0bc3f6", "cluster.uuid": "uH43uCTXQNKZmC3BLzyVnw", "node.id": "Ps0q-MrPR26LYNUsgy-dag",  "message": "[2053] Failed to execute fetch phase" , 
"stacktrace": ["org.elasticsearch.transport.RemoteTransportException: [c95aab0bc3f6][172.31.0.2:9300][indices:data/read/search[phase/fetch/id]]",
"Caused by: org.elasticsearch.script.ScriptException: runtime error",
"at org.elasticsearch.painless.PainlessScript.convertToScriptException(PainlessScript.java:94) ~[?:?]",
"at org.elasticsearch.painless.PainlessScript$Script.execute(doc['context.service.name'].value:28) ~[?:?]",
"at org.elasticsearch.search.fetch.subphase.ScriptFieldsFetchSubPhase.hitsExecute(ScriptFieldsFetchSubPhase.java:67) ~[elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.search.fetch.FetchPhase.execute(FetchPhase.java:177) ~[elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.search.SearchService.lambda$executeFetchPhase$3(SearchService.java:539) ~[elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.search.SearchService$3.doRun(SearchService.java:379) [elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37) [elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.common.util.concurrent.TimedRunnable.doRun(TimedRunnable.java:41) [elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingAbstractRunnable.doRun(ThreadContext.java:751) [elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37) [elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]",
"at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]",
"at java.lang.Thread.run(Thread.java:834) [?:?]",
"Caused by: java.lang.IllegalArgumentException: No field found for [context.service.name] in mapping with types []",
"at org.elasticsearch.search.lookup.LeafDocLookup.get(LeafDocLookup.java:94) ~[elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.search.lookup.LeafDocLookup.get(LeafDocLookup.java:41) ~[elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.painless.PainlessScript$Script.execute(doc['context.service.name'].value:5) ~[?:?]",
"at org.elasticsearch.search.fetch.subphase.ScriptFieldsFetchSubPhase.hitsExecute(ScriptFieldsFetchSubPhase.java:67) ~[elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.search.fetch.FetchPhase.execute(FetchPhase.java:177) ~[elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.search.SearchService.lambda$executeFetchPhase$3(SearchService.java:539) ~[elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.search.SearchService$3.doRun(SearchService.java:379) ~[elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37) ~[elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.common.util.concurrent.TimedRunnable.doRun(TimedRunnable.java:41) ~[elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingAbstractRunnable.doRun(ThreadContext.java:751) ~[elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37) ~[elasticsearch-7.0.0-rc1.jar:7.0.0-rc1]",
"at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) ~[?:?]",
"at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) ~[?:?]",
"at java.lang.Thread.run(Thread.java:834) ~[?:?]"] }
  • APM Error Details shows data from 6.6.1
    APM  Error Details-KO
  • APM Errors shows data from 6.6.1
    APM  Errors-KO
  • APM Span Details shows data from 6.6.1
    APM  Span Details-KO
  • APM Transactions shows data from 6.6.1
    APM  Transactions-KO

Dashboards without issues

APM Services show the proper data
APM  Services - OK

PHP Agent Supports v2 API

Dears,

There is a PHP agent that only supports v1 API for the APM server,

I asked the maintainer about his plan regarding v2 support, but I think that he may be busy for now, and currently, so we decided to fork it, and just do some updates that make it support v2 API,

here is the package https://github.com/speakol-ads/elastic-apm-php-agent also, we forked the laravel agent that depends on it and updated it, you can find it here https://github.com/speakol-ads/elastic-apm-laravel

We just wanted to help the php community, if you have any recommendation before adding the mentioned packages in your list, just ping me, and also what are the steps required to list them here?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.