Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Metrics UI] Set up APM on our Metrics UI performance cluster #90311

Closed
jasonrhodes opened this issue Feb 4, 2021 · 10 comments
Closed

[Metrics UI] Set up APM on our Metrics UI performance cluster #90311

jasonrhodes opened this issue Feb 4, 2021 · 10 comments
Assignees
Labels
agent-nodejs chore Feature:Metrics UI Metrics UI feature performance Team:Infra Monitoring UI - DEPRECATED DEPRECATED - Label for the Infra Monitoring UI team. Use Team:obs-ux-infra_services

Comments

@jasonrhodes
Copy link
Member

jasonrhodes commented Feb 4, 2021

We have a private Metrics UI performance cluster where we need to run APM so we can evaluate performance.

AC:

  • APM node agent is running in this branch
  • APM server is running in a cloud instance (start with our performance cluster, but we can have a separate APM cluster if that ends up making sense)

Other tickets

  • APM RUM agent is running in this branch
  • Investigate and add custom spans
  • Analyze waffle map query using APM

Note: it would also be good to understand what, if any, custom spans we should consider introducing and make sure we understand how to do that in our own APM set up. If we add custom spans to our code, can we leave them there even if users don't use APM?

Note: We should check with the Synthetics team about writing synthetics tests that could test our UI and time things. We can spin that work into a new ticket.

@jasonrhodes jasonrhodes added Feature:Metrics UI Metrics UI feature performance Team:Infra Monitoring UI - DEPRECATED DEPRECATED - Label for the Infra Monitoring UI team. Use Team:obs-ux-infra_services labels Feb 4, 2021
@elasticmachine
Copy link
Contributor

Pinging @elastic/logs-metrics-ui (Team:logs-metrics-ui)

@jasonrhodes
Copy link
Member Author

@elastic/apm can someone help us understand our questions about instrumenting our code with APM spans? @elastic/apm-agent-node-js may also want to get involved here :)

@dgieselaar
Copy link
Member

@jasonrhodes perhaps useful for you as well: #90403

@vigneshshanmugam
Copy link
Member

Let us know how we can help here, I can provide help with both RUM and Synthetics.

@jasonrhodes
Copy link
Member Author

@dgieselaar @vigneshshanmugam thanks! When one of us picks this up in the next week or two, we'll reach out!

@estermv
Copy link
Contributor

estermv commented Mar 8, 2021

Kibana already comes with APM. To enable it, we need to add a config/apm.dev.js with the following content:

module.exports = {
  active: true,
  // Use if APM Server requires a token
  secretToken: <secret_token>,
  // Set custom APM Server URL (default: http://localhost:8200)
  serverUrl: '<server_url>',
};

I was able to setup a local kibana connected to the performance cluster and send some data to APM:
Screenshot 2021-03-08 at 19 16 24

@smith
Copy link
Contributor

smith commented Mar 8, 2021

You can also specify elastic.apm.active: true in your kibana.yml, but due to a bug (#79490), it won't pick up the setting unless you pass --config config/kibana.dev.yml to the yarn start command. This is nice because you may want to enable or disable it depending on which cluster you're connecting to.

@dgieselaar
Copy link
Member

If this is a cloud cluster (and it looks like it is), I'm not sure you can enable APM there. @sqren might know more. If you connect a local Kibana instance to it, that will collect APM data, but not if you go to the Kibana instance on cloud.

@estermv
Copy link
Contributor

estermv commented Mar 9, 2021

@dgieselaar you are right, it's a cloud cluster, but we enabled APM in a local kibana. We collect data from a local kibana instance, but that's what we want (for now) since we want to do some changes in our code and see how this affects performance.

@sorenlouv
Copy link
Member

sorenlouv commented Mar 9, 2021

@dgieselaar That's also my understanding, that it's still not possible to instrument Kibana on cloud (coming soon 🤞 )
From @estermv's comment it sounds like they are instrumenting a local kibana and sending it to an APM Server instance on cloud which should be fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
agent-nodejs chore Feature:Metrics UI Metrics UI feature performance Team:Infra Monitoring UI - DEPRECATED DEPRECATED - Label for the Infra Monitoring UI team. Use Team:obs-ux-infra_services
Projects
None yet
Development

No branches or pull requests

9 participants