Skip to content

Conversation

@vldpyatkov
Copy link
Contributor

No description provided.

*/
public static boolean bootstrap(final BootstrapOptions opts) throws InterruptedException {
final NodeImpl node = new NodeImpl();
final NodeImpl node = new NodeImpl("unittest", new PeerId("127.0.0.1", 0));
Copy link
Contributor

Choose a reason for hiding this comment

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

Am I right that JRaftUtils isn't a part of test package? If true it's strange to see "unittest" and "new PeerId("127.0.0.1", 0)" here. Is there any sense in bootstrap method in non-test environment? If not, did you consider moving bootstrap to test env?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Rename it to bootstrap.
I do not know to do with the method, and it is need or not in our purposes.

if (opts.getfSMCallerExecutorDisruptor() == null) {
opts.setfSMCallerExecutorDisruptor(new StripedDisruptor<FSMCallerImpl.ApplyTask>(
"JRaft-FSMCaller-Disruptor",
opts.getRaftOptions().getDisruptorBufferSize(),
Copy link
Contributor

Choose a reason for hiding this comment

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

Could you please clarify purposes of each disraptor?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The queue is for process state machine events on the RAFT node.

@asfgit asfgit closed this in 7a09d67 Aug 3, 2021
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