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(mria_lb): add incompatibility reasons to custom compatibility check #181

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

SergeTupchiy
Copy link
Contributor

@SergeTupchiy SergeTupchiy commented Jun 21, 2024

Fixes EMQX-12103

@@ -190,6 +191,13 @@ do_update(State = #s{core_nodes = OldCoreNodes, node_info = OldNodeInfo}) ->
ping_new_nodes(NewCoreNodes, DiscoveredReplicants),
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This makes a replicant a running member of the cluster, even though it has no compatible core node to connect to and, thus, is not fully initialized.
The node is returned from mria:running_nodes/0 and can be used in various RPCs at EMQX layer resulting in numerous levels.
Perhaps we should add some mria_membership status as connecting and don't include disconnected replicants to the running nodes list.

@ieQu1
Copy link
Member

ieQu1 commented Jun 25, 2024

Sorry for late review, but it looks like mria protocol version should be bumped?

@ieQu1
Copy link
Member

ieQu1 commented Jul 8, 2024

I think this compatibility error can be checked and reported entirely in EMQX application code. No need to cross multiple API levels to report a warning. Since EMQX owns and implements the version check, there's nothing preventing it, architecture-wise, from making an RPC to check version of its peer.

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

Successfully merging this pull request may close these issues.

2 participants