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

replicaset: validate name in replicaset_locate_master #462

Merged
merged 1 commit into from
Jan 30, 2024

Conversation

Serpentian
Copy link
Contributor

Currently, the name validation is not used, when locate_master() is called. It makes an explicit call via the connection to obtain a future object in order to figure out, whether the node is a master.

We should not make any calls to a replica until the time, we definitely know, that its name and uuid was validated. Let's use replica_call instead of conn.call.

Follow-up #426

NO_DOC=bugfix

Copy link
Collaborator

@Gerold103 Gerold103 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 the patch!

vshard/replicaset.lua Outdated Show resolved Hide resolved
@Serpentian Serpentian force-pushed the name-validation-follow-up branch 2 times, most recently from c56639f to 2d8178b Compare January 26, 2024 16:19
@Serpentian Serpentian requested a review from Gerold103 January 26, 2024 16:21
Copy link
Collaborator

@Gerold103 Gerold103 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 the fix!

vshard/replicaset.lua Outdated Show resolved Hide resolved
@Serpentian Serpentian force-pushed the name-validation-follow-up branch from 2d8178b to 1f1fe44 Compare January 29, 2024 21:09
Currently, the name validation is not used, when locate_master()
is called. It makes an explicit call via the connection to obtain a
future object in order to figure out, whether the node is a master.

We should not make any calls to a replica until the time, we definitely
know, that its name and uuid was validated. Let's use replica_call
instead of conn.call.

Follow-up tarantool#426

NO_DOC=bugfix
@Serpentian Serpentian force-pushed the name-validation-follow-up branch from 1f1fe44 to a5360e8 Compare January 29, 2024 21:16
@Serpentian Serpentian requested a review from Gerold103 January 29, 2024 21:17
Copy link
Collaborator

@Gerold103 Gerold103 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 the fixes!

@Gerold103 Gerold103 merged commit 686bde3 into tarantool:master Jan 30, 2024
7 of 8 checks passed
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