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

[elasticsearch] Always report transport address in node_stats #36582

Merged

Conversation

miltonhultgren
Copy link
Contributor

@miltonhultgren miltonhultgren commented Sep 13, 2023

In the node_stats metricset we were relying on Metricbeat to populate service.address and then later in the Stack Monitoring UI use that to display the IP of the nodes.

Two problems existed with that approach:

  1. Metricbeat will populate service.address with the IP/address of the host it connects to in order to collect the metrics, and if you're using scope: cluster that might be a load balancer or it will just be the address of the single node that gets connected, duplicated for all nodes
  2. The address populated will be the HTTP address, not the Elasticsearch transport address, which is what Internal Collection reports (and the variables in the Stack Monitoring UI refer to)

This PR changes so that we manually populate service.address by setting event.Host to the transport IP of the node being reported so that each node reports their unique transport IP.

@botelastic botelastic bot added the needs_team Indicates that the issue/PR needs a Team:* label label Sep 13, 2023
@mergify
Copy link
Contributor

mergify bot commented Sep 13, 2023

This pull request does not have a backport label.
If this is a bug or security fix, could you label this PR @miltonhultgren? 🙏.
For such, you'll need to label your PR with:

  • The upcoming major version of the Elastic Stack
  • The upcoming minor version of the Elastic Stack (if you're not pushing a breaking change)

To fixup this pull request, you need to add the backport labels for the needed
branches, such as:

  • backport-v8./d.0 is the label to automatically backport to the 8./d branch. /d is the digit

@elasticmachine
Copy link
Collaborator

elasticmachine commented Sep 13, 2023

💚 Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview preview

Expand to view the summary

Build stats

  • Start Time: 2023-09-20T13:08:02.504+0000

  • Duration: 55 min 44 sec

Test stats 🧪

Test Results
Failed 0
Passed 4413
Skipped 913
Total 5326

💚 Flaky test report

Tests succeeded.

🤖 GitHub comments

Expand to view the GitHub comments

To re-run your PR in the CI, just comment with:

  • /test : Re-trigger the build.

  • /package : Generate the packages and run the E2E tests.

  • /beats-tester : Run the installation tests with beats-tester.

  • run elasticsearch-ci/docs : Re-trigger the docs validation. (use unformatted text in the comment!)

@miltonhultgren miltonhultgren added Team:Infra Monitoring UI - DEPRECATED Infrastructure Monitoring UI team - DEPRECATED - Use Team:Monitoring backport-v8.10.0 Automated backport with mergify labels Sep 13, 2023
@botelastic botelastic bot removed the needs_team Indicates that the issue/PR needs a Team:* label label Sep 13, 2023
@miltonhultgren miltonhultgren added module Module:elasticsearch Elasticsearch Beats modules labels Sep 13, 2023
@miltonhultgren miltonhultgren marked this pull request as ready for review September 13, 2023 18:47
@miltonhultgren miltonhultgren requested a review from a team as a code owner September 13, 2023 18:47
@miltonhultgren miltonhultgren enabled auto-merge (squash) September 20, 2023 13:07
@miltonhultgren miltonhultgren merged commit 24c3388 into elastic:main Sep 20, 2023
26 checks passed
mergify bot pushed a commit that referenced this pull request Sep 20, 2023
miltonhultgren added a commit that referenced this pull request Sep 21, 2023
Scholar-Li pushed a commit to Scholar-Li/beats that referenced this pull request Feb 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-v8.10.0 Automated backport with mergify Module:elasticsearch Elasticsearch Beats modules module Team:Infra Monitoring UI - DEPRECATED Infrastructure Monitoring UI team - DEPRECATED - Use Team:Monitoring
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants