These are chat archives for atomix/atomix

2nd
Nov 2016
terrytan
@txm119161336_twitter
Nov 02 2016 02:16
@kuujo dan online?
mstennie
@mstennie
Nov 02 2016 09:17
Hey everyone, did someone here performed some performance testing on CopyCat ? If yes, I am interested to see the results.
mstennie
@mstennie
Nov 02 2016 19:08
Other question: How do you advise us to deal with different version of the state machine? What if I want to change the internals of the state machine (add a field or an hash map)? What are the best practices? Thanks
Jordan Halterman
@kuujo
Nov 02 2016 19:57

@mstennie some people have done performance testing, but I'm not one of them. While some work has been put into performance improvements, the focus has mostly gone towards usability and correctness.

As for state machine versions, this is something that has to be handled by the user. TBH it's something that would be a great addition to Copycat but doesn't exist yet. So, the way I would suggest dealing with versions is by creating a separate class for each version and adding a version field to a base command for all state machine commands. In the actual StateMachine implementation, read the version for each command and proxy the command to the correct state machine.

Of course, you'll probably want some state to be shared across versions as well, which can be handled by shared data structures.

I'm interested in making versioning happen in Copycat, though. I think my idea would be to add an optional version field to Operation and add some annotations for the state machine to annotate versioned command handler methods. But it would just be syntactic sugar for the same logic I just described.

But state machines still have to maintain support for all versions. Beyond that, there's the possibility of supporting upgrade paths for the log, but I think an abstraction for versions at all is the first step.
mstennie
@mstennie
Nov 02 2016 20:19
@kuujo Yes I think that it would be a great addition. Couldn't it be something that could be handle by a leader? A change of version committed in the logs when a quorum of servers agree to move on to the next version. Version 2 could be initialised with a snapshot of version 1 at that moment. I am just two weeks old using Copycat so excuse me if what I say is stupid :)