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

feat(redis_info): add option to fetch cluster info #8464

Merged
merged 4 commits into from
Jun 12, 2024

Conversation

tyxieblub
Copy link
Contributor

SUMMARY

Adds support for getting cluster information. It does not use, redis-py's cluster_info() because I couldn't get it to work when the cluster is yet to be configured. Hence the execute_command which works in that case.

It's optional and can be invoked with adding cluster: true to the task:

- name: Get server cluster information
  community.general.redis_info:
    cluster: true
  register: result

And returns the additionnal data in the cluster_info variable alongside info.

ISSUE TYPE
  • Feature Pull Request
COMPONENT NAME
  • redis_info

@ansibullbot
Copy link
Collaborator

@ansibullbot ansibullbot added feature This issue/PR relates to a feature request module module plugins plugin (any type) labels Jun 4, 2024
@tyxieblub tyxieblub force-pushed the redis-cluster-info branch from 3e923a8 to d91f7ab Compare June 4, 2024 16:59
@felixfontein felixfontein added check-before-release PR will be looked at again shortly before release and merged if possible. backport-9 Automatically create a backport for the stable-9 branch labels Jun 6, 2024
Copy link
Collaborator

@felixfontein felixfontein left a comment

Choose a reason for hiding this comment

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

Thanks for your contribution!

plugins/modules/redis_info.py Outdated Show resolved Hide resolved
plugins/modules/redis_info.py Outdated Show resolved Hide resolved
plugins/modules/redis_info.py Outdated Show resolved Hide resolved
plugins/modules/redis_info.py Outdated Show resolved Hide resolved
tyxieblub and others added 2 commits June 10, 2024 08:39
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: Felix Fontein <felix@fontein.de>
@tyxieblub
Copy link
Contributor Author

Thanks for the review, I applied everything!

Copy link
Contributor

@levonet levonet left a comment

Choose a reason for hiding this comment

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

I have nothing to add. Thanks for the contribution.

@felixfontein felixfontein removed the check-before-release PR will be looked at again shortly before release and merged if possible. label Jun 12, 2024
@felixfontein felixfontein merged commit 800bc01 into ansible-collections:main Jun 12, 2024
132 checks passed
Copy link

patchback bot commented Jun 12, 2024

Backport to stable-9: 💚 backport PR created

✅ Backport PR branch: patchback/backports/stable-9/800bc0111277770bff3b26ff527431d57dadb8ff/pr-8464

Backported as #8493

🤖 @patchback
I'm built with octomachinery and
my source is open — https://github.com/sanitizers/patchback-github-app.

patchback bot pushed a commit that referenced this pull request Jun 12, 2024
* feat(redis_info): add option to fetch cluster info

* add changelog fragment

* update description

Co-authored-by: Felix Fontein <felix@fontein.de>

* Apply suggestions from code review

Co-authored-by: Felix Fontein <felix@fontein.de>

---------

Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 800bc01)
@felixfontein
Copy link
Collaborator

@tyxieblub thanks for your contribution!
@levonet thanks for reviewing!

felixfontein pushed a commit that referenced this pull request Jun 13, 2024
…o fetch cluster info (#8493)

feat(redis_info): add option to fetch cluster info (#8464)

* feat(redis_info): add option to fetch cluster info

* add changelog fragment

* update description

Co-authored-by: Felix Fontein <felix@fontein.de>

* Apply suggestions from code review

Co-authored-by: Felix Fontein <felix@fontein.de>

---------

Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit 800bc01)

Co-authored-by: joris <5111464+tyxieblub@users.noreply.github.com>
Massl123 pushed a commit to Massl123/community.general that referenced this pull request Feb 7, 2025
…ns#8464)

* feat(redis_info): add option to fetch cluster info

* add changelog fragment

* update description

Co-authored-by: Felix Fontein <felix@fontein.de>

* Apply suggestions from code review

Co-authored-by: Felix Fontein <felix@fontein.de>

---------

Co-authored-by: Felix Fontein <felix@fontein.de>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport-9 Automatically create a backport for the stable-9 branch feature This issue/PR relates to a feature request module module plugins plugin (any type)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants