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

[Heartbeat] Run Once mode #28437

Closed
andrewvc opened this issue Oct 14, 2021 · 2 comments · Fixed by #28548
Closed

[Heartbeat] Run Once mode #28437

andrewvc opened this issue Oct 14, 2021 · 2 comments · Fixed by #28548
Assignees
Labels
enhancement Heartbeat Team:obs-ds-hosted-services Label for the Observability Hosted Services team v7.16.0

Comments

@andrewvc
Copy link
Contributor

Heartbeat could use a mode in which it starts, runs each monitor exactly once, then exits.

This was mostly accomplished in #25972
But now I'm thinking it would be better to just put all the monitors in heartbeat.monitors and add a new heartbeat.run_once: true boolean that just changes the way heartbeat.monitors is handled instead.

This is experimental.

@andrewvc andrewvc added enhancement Heartbeat Team:obs-ds-hosted-services Label for the Observability Hosted Services team v7.16.0 labels Oct 14, 2021
@andrewvc andrewvc self-assigned this Oct 14, 2021
@elasticmachine
Copy link
Collaborator

Pinging @elastic/uptime (Team:Uptime)

andrewvc added a commit to andrewvc/beats that referenced this issue Oct 19, 2021
Fixes elastic#28437. This is an improvement over
elastic#25972 which had a more complicated
config interface.
andrewvc added a commit that referenced this issue Oct 20, 2021
* [Heartbeat] Make run_once syntax a boolean

Fixes #28437. This is an improvement over
#25972 which had a more complicated
config interface.

* Fix python tests

* Fix python
mergify bot pushed a commit that referenced this issue Oct 20, 2021
* [Heartbeat] Make run_once syntax a boolean

Fixes #28437. This is an improvement over
#25972 which had a more complicated
config interface.

* Fix python tests

* Fix python

(cherry picked from commit d31cae9)
Icedroid pushed a commit to Icedroid/beats that referenced this issue Nov 1, 2021
* [Heartbeat] Make run_once syntax a boolean

Fixes elastic#28437. This is an improvement over
elastic#25972 which had a more complicated
config interface.

* Fix python tests

* Fix python
@shahzad31
Copy link
Contributor

post FF testing

Works flawlessly , step to test

  1. Build heartbeat locally
  2. Turn the flag heartbeat.run_once: true on
  3. Run an example monitor
  4. Start heartbeat, it shut down after only one run
  5. Tried it couple times,
  6. worked each time
  7. Verified the data within uptime plugin
  8. 3 pings present for 3 runs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Heartbeat Team:obs-ds-hosted-services Label for the Observability Hosted Services team v7.16.0
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants