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

[Metricbeat] Add state_statefulset replicas.ready #26088

Merged
merged 1 commit into from
Jun 9, 2021

Conversation

ninaspitfire
Copy link
Contributor

Add a "replicas.ready" field to the state_statefulset metricset of the
Kubernetes module.

This is drawn from the "readyReplicas" value in the Kubernetes
StatefulSetStatus API response.

What does this PR do?

Adds a replicas.ready field to the Kubernetes state_statefulset metricset.

Why is it important?

Allows the operator to define alerts on ready/unready replicas in a StatefulSet.

Checklist

  • My code follows the style guidelines of this project
  • [] I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • [] I have made corresponding change to the default configuration files
  • I have added tests that prove my fix is effective or that my feature works
  • I have added an entry in CHANGELOG.next.asciidoc or CHANGELOG-developer.next.asciidoc.

How to test this PR locally

MODULE=kubernetes mage -v test

Related issues

Add a "replicas.ready" field to the state_statefulset metricset of the
Kubernetes module.

This is drawn from the "readyReplicas" value in the Kubernetes
StatefulSetStatus API response.
@botelastic botelastic bot added the needs_team Indicates that the issue/PR needs a Team:* label label Jun 2, 2021
@ninaspitfire ninaspitfire added Metricbeat Metricbeat Team:Integrations Label for the Integrations team labels Jun 2, 2021
@elasticmachine
Copy link
Collaborator

Pinging @elastic/integrations (Team:Integrations)

@botelastic botelastic bot removed the needs_team Indicates that the issue/PR needs a Team:* label label Jun 2, 2021
@ninaspitfire
Copy link
Contributor Author

cc @eedugon

@elasticmachine
Copy link
Collaborator

💚 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

Expand to view the summary

Build stats

  • Build Cause: Pull request #26088 opened

  • Start Time: 2021-06-02T01:48:54.407+0000

  • Duration: 86 min 18 sec

  • Commit: 5648c96

Test stats 🧪

Test Results
Failed 0
Passed 8125
Skipped 2354
Total 10479

Trends 🧪

Image of Build Times

Image of Tests

💚 Flaky test report

Tests succeeded.

Expand to view the summary

Test stats 🧪

Test Results
Failed 0
Passed 8125
Skipped 2354
Total 10479

@ninaspitfire ninaspitfire requested review from jsoriano and ChrsMark June 2, 2021 23:59
Copy link
Member

@ChrsMark ChrsMark left a comment

Choose a reason for hiding this comment

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

lgtm, thanks @Jarpy!
It will require a change in https://github.com/elastic/integrations/tree/master/packages/kubernetes too to add the extra field.

Can you open an issue there @Jarpy please and assign it to me so as not to forget about it?

@ninaspitfire
Copy link
Contributor Author

Thanks, @ChrsMark. <3

Not sure how to handle backports, is that all automated these days?

@ChrsMark ChrsMark merged commit dbde7db into elastic:master Jun 9, 2021
ChrsMark pushed a commit to ChrsMark/beats that referenced this pull request Jun 9, 2021
Add a "replicas.ready" field to the state_statefulset metricset of the
Kubernetes module.

This is drawn from the "readyReplicas" value in the Kubernetes
StatefulSetStatus API response.

(cherry picked from commit dbde7db)
@ChrsMark
Copy link
Member

ChrsMark commented Jun 9, 2021

Nope, we still handle the backports manually. I opened the backport for 7.14 so we are just fine here!

ChrsMark added a commit that referenced this pull request Jun 10, 2021
Add a "replicas.ready" field to the state_statefulset metricset of the
Kubernetes module.

This is drawn from the "readyReplicas" value in the Kubernetes
StatefulSetStatus API response.

(cherry picked from commit dbde7db)

Co-authored-by: Toby McLaughlin <[email protected]>
@ninaspitfire
Copy link
Contributor Author

Sweet. Thanks so much, @ChrsMark.

@ninaspitfire ninaspitfire deleted the statefulset-replicas-ready branch June 15, 2021 01:29
mdelapenya added a commit to mdelapenya/beats that referenced this pull request Jun 21, 2021
* master: (26 commits)
  Report total and free CPU for vSphere virtual machines (elastic#26167)
  [filebeat] Add preserve_original_event option to o365audit input (elastic#26273)
  Change xml processor names in script processor to match convention (elastic#26263)
  [Oracle] Fixing default values for paths in config template (elastic#26276)
  Add more ECS fields to logs (elastic#25998)
  [Heartbeat] Fix broken invocation of synth package (elastic#26228)
  rename sqs file name (elastic#26227)
  Populate the agent action result if there is no matching action handlers (elastic#26152)
  Add ISO8601 as supported timestamp type (elastic#25564)
  Move Filebeat azure module to GA (elastic#26168)
  Filebeat azure module pipeline fixes and changes (elastic#26148)
  libbeat: monitor version (elastic#26214)
  Add new parser to filestream input: container (elastic#26115)
  [Metricbeat] Add state_statefulset replicas.ready (elastic#26088)
  Disable test processors system test for windows 10 (elastic#26216)
  Fix startup with failing configuration (elastic#26126)
  Remove 32 bits version of Elastic Agent. (elastic#25708)
  Chane fleetmode detection to ony use management.enabled (elastic#26180)
  Make `filestream` input GA (elastic#26127)
  libbeat/idxmgmt/ilm: fix alias creation (elastic#26146)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Metricbeat Metricbeat Team:Integrations Label for the Integrations team v7.14.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Include kube_statefulset_status_replicas_ready metric in kubernetes Metricbeat module
3 participants