[Stack Monitoring] [Kibana] Avoid querying /api/status on every cycle #31118
Open
Description
@afharo opened #29911 to move the url generation for the kibana module into the init phase.
As-written the PR might cause problems in the event kibana is upgraded without upgrading (or at least restarting) metricbeat.
@afharo proposed this instead:
- During the first init, retrieve
GET /api/status
to build the finalGET /api/stats
URL - Use the final URL for every subsequent call
- Check that
kibana.version
coming fromGET /api/stats
didn't change. If it changes, go back to 1.
Acceptance criteria:
- /api/status not called on every 10s metricbeat cycle
- metricbeat notices and changes behavior accordingly if kibana changes versions during a single metricbeat process run