-
Notifications
You must be signed in to change notification settings - Fork 33
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
Mas 3.0 dialyzer #800
Mas 3.0 dialyzer #800
Conversation
Work through dialyzer issues. Should just be one unresolved issue left
Add logging of socket
Otherwise if the last partition is a soft_retry_limit failure will never report as complete with errors
maybe_complete_fullsync function requires further mocking
Dialyzer has an error if we call terminate from system_terminate - appears to be related to the exit/1 funciton within terminate. This change brings a new function to log and return the reason for failure (previously part of terminate), so that the exit can happen in the parent function without causing a big DRY issue
{noreply, State4#state{error_exits = ErrorExits1, | ||
purgatory = Purgatory, | ||
dropped = Dropped}}; | ||
maybe_complete_fullsync(Running, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is more than just a refactoring...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are right, I was a bit lazy combining the two. Shall I revert out the commits associated with #799 and put in a separate PR?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the reference. This is fine.
@@ -47,7 +47,7 @@ | |||
cluster, | |||
fullsync_worker, | |||
work_dir = undefined, | |||
strategy :: keylist | aae, | |||
strategy :: keylist | aae | undefined, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The documentation says:
%% If the protocol version >= 2.0, and the cluster has aae enabled and the replication
%% configuration stanza enables the aae strategy (the default is keylist),
In other words, it assumes a default. I would expect the init function to then implement that default by initialising the state with keylist
alternatively to follow the logic.
At this moment there is a possible race condition when the server is started and a call legacy_status
comes in, this may crash the server (line 107). Dializer seems not to spot this, though.
Co-Authored-By: Thomas Arts <[email protected]>
Co-Authored-By: Thomas Arts <[email protected]>
Dialyzer fixes.
In gen_leader.erl the fix to dialyzer error on system_terminate/4 is clunky. It is not clear why system_terminate/4 had no return, and how moving the code around in this way means there is no no problem.
Rolled in for src/riak_repl2_fscoordinator.erl is a fix to the intermittently failing test #799. This had been incorrectly ignored in previous releases (given that it was accepted there were known problems in aae full-sync in these test cases) - but know following this fix has predictable (passing) behaviour