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

Beats instance page #113086

Merged
merged 2 commits into from
Sep 28, 2021
Merged

Conversation

matschaffer
Copy link
Contributor

@matschaffer matschaffer commented Sep 27, 2021

Summary

Got the basics going so far

Screen Shot 2021-09-27 at 15 29 43

Part of #111757

Still need to work out:

  • Setup mode: just shows n/a right now
  • Pagination test: if I add what I found in ElasticsearchNodesPage I get a server side rejection. Need to see how that part is working

Checklist

Delete any items that are not applicable to this PR.

Risk Matrix

Delete this section if it is not applicable to this PR.

Before closing this PR, invite QA, stakeholders, and other developers to identify risks that should be tested prior to the change/feature release.

When forming the risk matrix, consider some of the following examples and how they may potentially impact the change:

Risk Probability Severity Mitigation/Notes
Multiple Spaces—unexpected behavior in non-default Kibana Space. Low High Integration tests will verify that all features are still supported in non-default Kibana Space and when user switches between spaces.
Multiple nodes—Elasticsearch polling might have race conditions when multiple Kibana nodes are polling for the same tasks. High Low Tasks are idempotent, so executing them multiple times will not result in logical error, but will degrade performance. To test for this case we add plenty of unit tests around this logic and document manual testing procedure.
Code should gracefully handle cases when feature X or plugin Y are disabled. Medium High Unit tests will verify that any feature flag or plugin combination still results in our service operational.
See more potential risk examples

For maintainers

@matschaffer matschaffer added v8.0.0 Team:Infra Monitoring UI - DEPRECATED DEPRECATED - Label for the Infra Monitoring UI team. Use Team:obs-ux-infra_services release_note:skip Skip the PR/issue when compiling release notes Feature:Stack Monitoring auto-backport Deprecated - use backport:version if exact versions are needed v7.16.0 Epic: Stack Monitoring de-angularization labels Sep 27, 2021
@matschaffer matschaffer self-assigned this Sep 27, 2021
@matschaffer matschaffer requested a review from a team as a code owner September 27, 2021 06:31
@matschaffer matschaffer requested review from a team September 27, 2021 06:31
@elasticmachine
Copy link
Contributor

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

@matschaffer
Copy link
Contributor Author

Looks like ES nodes also has broken setup mode behavior for react/master now, so could be we could merge with that not working correctly and fix next week.

@matschaffer
Copy link
Contributor Author

Looks like pagination doesn't work at all yet. So will have to figure out how to make that work.

@matschaffer
Copy link
Contributor Author

matschaffer commented Sep 28, 2021

Just noting that to test this I ended up using this to generate a docker compose, metricbeat, and docker compose up snippet:

// spit out 29 entries for docker-compose.yaml
for (let i = 2; i <= 30; i++) {
  console.log(`
  mb${i.toString().padStart(2, '0')}:
    <<: *extrabeat
  `);
}

// spit out 30 entries to add to metricbeat.yml
let list = [];
for (let i = 1; i <= 30; i++) {
  list.push(`http://mb${i.toString().padStart(2, '0')}:5066`);
}
console.log(JSON.stringify(list));

// spit out a docker compose for all 30 metricbeats (can probably just use `docker compose up -d`)
let upCmd = 'docker compose up -d ';
for (let i = 1; i <= 30; i++) {
  upCmd += `mb${i.toString().padStart(2, '0')} `;
}
console.log(upCmd);

With this yaml definition in docker-compose.yml

  mb01: &extrabeat
    image: docker.elastic.co/beats/metricbeat:${ELASTIC_VERSION}
    user: root
    environment:
      ELASTICSEARCH_HOSTS: https://node01:9200
      ELASTICSEARCH_USERNAME: elastic
      ELASTICSEARCH_PASSWORD: $ELASTIC_PASSWORD
    volumes:
      - ./metricbeat-extra.yml:/usr/share/metricbeat/metricbeat.yml
    networks:
      - es-network

And this metricbeat-extra.yml

metricbeat.config.modules:
  path: ${path.config}/modules.d/*.yml
  reload.enabled: false

output.elasticsearch:
  hosts: '${ELASTICSEARCH_HOSTS:elasticsearch:9200}'
  username: '${ELASTICSEARCH_USERNAME:}'
  password: '${ELASTICSEARCH_PASSWORD:}'
  protocol: 'https'
  ssl.verification_mode: 'none'

http.enabled: true

metricbeat.modules:
  - module: system
    period: 10s
    enabled: true

and add those to the main metricbeat.yml

- module: beat
  xpack.enabled: true
  period: 10s
  hosts: ["http://127.0.0.1:5066", "http://filebeat:5067", "http://apm-server:5068", "http://heartbeat:5069", "http://mb01:5066","http://mb02:5066","http://mb03:5066","http://mb04:5066","http://mb05:5066"... (the rest of what's generated)]

This way I could get 30 "extra" metricbeat instances that do almost nothing, but show up in the monitoring UI.

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
monitoring 605 607 +2

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
monitoring 946.6KB 951.2KB +4.6KB

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

cc @matschaffer

Copy link
Contributor

@phillipb phillipb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@matschaffer
Copy link
Contributor Author

Will handle pagination & setup mode in follow up PRs.

@matschaffer matschaffer merged commit ba49138 into elastic:master Sep 28, 2021
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Sep 28, 2021
* Beats instance page

* Remove unused getPaginationRouteOptions
@kibanamachine
Copy link
Contributor

💚 Backport successful

Status Branch Result
7.x

This backport PR will be merged automatically after passing CI.

@matschaffer matschaffer deleted the beats-instances-view branch September 28, 2021 14:03
kibanamachine added a commit that referenced this pull request Sep 28, 2021
* Beats instance page

* Remove unused getPaginationRouteOptions

Co-authored-by: Mat Schaffer <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Deprecated - use backport:version if exact versions are needed Epic: Stack Monitoring de-angularization Feature:Stack Monitoring release_note:skip Skip the PR/issue when compiling release notes Team:Infra Monitoring UI - DEPRECATED DEPRECATED - Label for the Infra Monitoring UI team. Use Team:obs-ux-infra_services v7.16.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants