Skip to content

DRAFT: Use new RA callback #7905

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

Draft
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

SimonUnge
Copy link
Contributor

Proposed Changes

Draft for @kjnilsson

Types of Changes

What types of changes does your code introduce to this project?
Put an x in the boxes that apply

  • Bug fix (non-breaking change which fixes issue #NNNN)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause an observable behavior change in existing systems)
  • Documentation improvements (corrections, new content, etc)
  • Cosmetic change (whitespace, formatting, etc)
  • Build system and/or CI

Checklist

Put an x in the boxes that apply.
You can also fill these out after creating the PR.
If you're unsure about any of them, don't hesitate to ask on the mailing list.
We're here to help!
This is simply a reminder of what we are going to look for before merging your code.

  • I have read the CONTRIBUTING.md document
  • I have signed the CA (see https://cla.pivotal.io/sign/rabbitmq)
  • I have added tests that prove my fix is effective or that my feature works
  • All tests pass locally with my changes
  • If relevant, I have added necessary documentation to https://github.com/rabbitmq/rabbitmq-website
  • If relevant, I have added this change to the first version(s) in release-notes that I expect to introduce it

Further Comments

If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc.

@mergify mergify bot added the bazel label Apr 14, 2023
@SimonUnge SimonUnge force-pushed the qq_using_new_ra_callback branch from 86a9039 to 0e15e86 Compare April 17, 2023 21:04
@kjnilsson
Copy link
Contributor

I think the general approach is pretty much what we designed. I am concerned that there are functions called in eval_members that are potentially blocking such as rabbit_nodes:list_running() and we'd have to see if it feasible to run all "grow" logic in a non blocking way to avoid locking the Ra leader process up.

That said this is very much on the right track and we just need to investigate a bit further if the logic can be made safe to run inside the ra process.

@SimonUnge
Copy link
Contributor Author

SimonUnge commented May 10, 2023

I think the general approach is pretty much what we designed. I am concerned that there are functions called in eval_members that are potentially blocking such as rabbit_nodes:list_running() and we'd have to see if it feasible to run all "grow" logic in a non blocking way to avoid locking the Ra leader process up.

That said this is very much on the right track and we just need to investigate a bit further if the logic can be made safe to run inside the ra process.

Awesome. Any hints on how to investigate?

I was thinking of somehow call the 'eval_members' in its own process, and somehow get the result back to the RA process to run the grow code.

@SimonUnge
Copy link
Contributor Author

@kjnilsson Perhaps the eval_member callback could provide an optional 'reply fun', and the implementer could use that fun to report the result to the instead of directly responding, i.e spawn a process that does the eval, and add the 'effects' to the fun, and the funs job would be to send a msg back to the ra_server_proc leader process?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants