Hey Sebastian,
the main reason for using client generated ID's is that a client can send multiple commands for the same aggregate, without the need to wait for a return value of the first command. I don't think mysql key generator will have any trouble keeping up.
The disruptor commandbus solution solves another problem. I have seen cases where applications would have so many concurrent (and active) connections, that there was high contention. In such a case, using fewer connections in a smart way could help. The disruptor command bus can do exactly that.
The link you sent is interesting, to say the least. I don't think the UUID has anything to do with it. It is probably purely the use of a unique index. It seems that MySQL has difficulty managing large numbers of unique indexes. With a auto increment, mysql knows it doesn't need to check anything. There can't be any value equal to the generated one.
In the JPA Event Store, the unique key is the combination of the aggregate identifier and the event's sequence number. Using an auto-increment key in mysql is not really going to be a solution. But it may be interesting to find out if there is a way to remove the need for a unique index...
To be continued...
Allard
Hey!
Allard, when we had a chat a couple of weeks ago you sounded pretty confident that UUID keys on MySQL tables would make for a lesser performance hit that having an auto increment integer key. Your reasoning as I recall it was that you would very soon get congestion around the key generator (and the double round trips to the DB for getting the PK back). However, in the sentence after that you suggested us trying out the disruptor to only have a few threads doing the actual inserts which would mitigate the congestion problem, no? The auto increment key should of course only used locally in the specific table and would prove very useful for doing incremental maintenance jobs on the table as well.
Cheers
Sebastian
--
You received this message because you are subscribed to the Google Groups "Axon Framework Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
axonframewor...@googlegroups.com.
For more options, visit
https://groups.google.com/groups/opt_out.