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

Implement module "site" for configuring distributed monitoring #654

Merged
merged 21 commits into from
Oct 9, 2024

Conversation

lgetwan
Copy link
Contributor

@lgetwan lgetwan commented Aug 20, 2024

Pull request type

Please check the type of change your PR introduces:

  • Bugfix
  • Feature
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes, no API changes)
  • Build related changes
  • Documentation content changes
  • Other (please describe):

What is the current behavior?

There was no module for managing distributed monitoring sites.

What is the new behavior?

Now there is.

Other information

Thanks to the usage of IDs in the site management REST API, it was possible to make this module idempotent. If you run into problems, please let us know.

@lgetwan lgetwan added the module:site This affects the site module label Aug 20, 2024
@robin-checkmk robin-checkmk self-assigned this Aug 20, 2024
Copy link
Member

@robin-checkmk robin-checkmk left a comment

Choose a reason for hiding this comment

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

Can we discuss the module name?
The UI calls it "Distributed monitoring", but the REST API "Site Management".
My issue here is, that the latter sounds a lot like what our server role does.
We also follow the UI in other places IIRC, as the REST API made some interesting naming choices.
I am also happy, if we find a one-word name, or at least something shorter than distributed_monitoring or site_management.

Note to myself: After this is figured out, update README.

@lgetwan
Copy link
Contributor Author

lgetwan commented Aug 21, 2024

I also disliked the module name tbo, so I changed it to distmon, which is short and recognizable.
Also removed Python Typing to make it Python2.7 compatible.
Changelog was also added lately.

@lgetwan lgetwan changed the title Implement module "site_management" for configuring distributed monitoring Implement module "distmon" for configuring distributed monitoring Aug 21, 2024
Copy link
Member

@robin-checkmk robin-checkmk left a comment

Choose a reason for hiding this comment

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

I am getting the overall feeling, that it might make sense, to abstract the module more from the REST API. The structure of the module could probably be flatter than that of the API. That is not to say, that this is not a good first version, we just might want to keep it in mind for a later review.

plugins/doc_fragments/distmon_options.py Outdated Show resolved Hide resolved
plugins/doc_fragments/distmon_options.py Outdated Show resolved Hide resolved
plugins/doc_fragments/distmon_options.py Outdated Show resolved Hide resolved
plugins/doc_fragments/distmon_options.py Outdated Show resolved Hide resolved
plugins/doc_fragments/distmon_options.py Outdated Show resolved Hide resolved
plugins/doc_fragments/distmon_options.py Outdated Show resolved Hide resolved
plugins/doc_fragments/distmon_options.py Outdated Show resolved Hide resolved
plugins/doc_fragments/distmon_options.py Outdated Show resolved Hide resolved
plugins/doc_fragments/distmon_options.py Outdated Show resolved Hide resolved
plugins/doc_fragments/distmon_options.py Outdated Show resolved Hide resolved
@lgetwan lgetwan changed the title Implement module "distmon" for configuring distributed monitoring Implement module "site" for configuring distributed monitoring Aug 27, 2024
@lgetwan
Copy link
Contributor Author

lgetwan commented Aug 27, 2024

Currently, the integration tests are not correct. I have to refine them. But from my point of view, the module itself is ready for some first manual tests.

@lgetwan
Copy link
Contributor Author

lgetwan commented Aug 28, 2024

Looks like the integration tests runs into this problem: actions/runner-images#6680
Probably, the tests take too long?

@robin-checkmk
Copy link
Member

Looks like the integration tests runs into this problem: actions/runner-images#6680 Probably, the tests take too long?

I'll investigate, but I doubt, it is a timeout issue, we have/had tests, which run longer. It might be resource exhaustion.

@lgetwan
Copy link
Contributor Author

lgetwan commented Aug 28, 2024

It was indeed resource exhaustion. I reduced the number of remote sites to be created. Now github is happy.

Copy link
Member

@robin-checkmk robin-checkmk left a comment

Choose a reason for hiding this comment

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

I am happy with the changes. Pending a code review, we are good to merge.

@robin-checkmk robin-checkmk added the release:5.3.0 Affects the mentioned release. label Sep 5, 2024
@lgetwan lgetwan added the enhancement New feature or request label Sep 9, 2024
@github-actions github-actions bot added the documentation Improvements or additions to documentation label Sep 24, 2024
@robin-checkmk robin-checkmk linked an issue Sep 26, 2024 that may be closed by this pull request
@mike1098
Copy link

I tested the following without issues against 2.2.0p33cee:

  • Creating a site connection
  • Loging in to a site
  • Changing an attribute of a site connection
  • Logout from a site
  • Remove a site

Will discuss with my colleague as soon as he is back from vacation but I would say its working good.
Thank you for all the effort spent.

@robin-checkmk robin-checkmk mentioned this pull request Sep 30, 2024
7 tasks
@robin-checkmk robin-checkmk merged commit ddd5b50 into devel Oct 9, 2024
30 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators Oct 9, 2024
@robin-checkmk robin-checkmk deleted the feature/module-distributed branch October 9, 2024 06:39
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
documentation Improvements or additions to documentation enhancement New feature or request module:site This affects the site module release:5.3.0 Affects the mentioned release.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[FEED]Add Site Management
3 participants