-
Notifications
You must be signed in to change notification settings - Fork 14.6k
MINOR: Move RaftManager interface to raft module #20366
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
base: trunk
Are you sure you want to change the base?
MINOR: Move RaftManager interface to raft module #20366
Conversation
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.
Please fix the build error
|
Updated. Add license header to new file to fix build error. Thanks. |
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.
@Yunyung thanks for this patch
long createdTimeMs | ||
); | ||
|
||
void register(RaftClient.Listener<T> listener); |
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.
register
and leaderAndEpoch
are also a part of RaftClient
APIs. We could remove them from RaftManager
, since callers can use client
instead.
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.
Great. Done.
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, LGTM
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.
@Yunyung: LGTM
override def voterNode(id: Int, listener: ListenerName): Option[Node] = { | ||
client.voterNode(id, listener).toScala | ||
override def voterNode(id: Int, listener: ListenerName): Optional[Node] = { | ||
client.voterNode(id, listener) |
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.
If the delegation is only a single line and the client
is an interface, perhaps we don't need to wrap it with RaftManager
RaftManager
interface to raft module, and remove theregister
andleaderAndEpoch
methods since they are already part ofthe RaftClient APIs.