-
15. Re: Solving the backward compatibility issue -- working with clients of old versions
ataylor Dec 13, 2012 7:53 AM (in response to jmesnil)Ok, I have made some changes and I think we have solved it, these are 3 fold and can be found on my branch https://github.com/andytaylor/hornetq/tree/serialization_issues.
firsly i have changed back DiscoveryGroupConfiguration so the class description is the same as 2.2, I have then added write/readObject methods, if jgroups is used then we serialize the BroadcastEndpointFactoryConfiguration manually, if its UDPBroadcastGroupConfiguration then we dont do anything on the write and rebuild it on the read, this means that this will work with both 2.2 and 2.3 with no changes or flags needed.
secondly, i had to move Pair.java back to its old location, i gues moving the API packages is a no no if they are needed for serialization, we should do this for 3.0.
lastly, fixed an issue with PacketDecoder on server locator, it needs to be transient and re created in the readObject method.
Howard is testing this now.
-
16. Re: Solving the backward compatibility issue -- working with clients of old versions
gaohoward Dec 13, 2012 8:34 AM (in response to ataylor)looks like it work well both with AS7 and standalone hornetq. Only the 'null' issue is left alone. I need to figure out a solution...
-
17. Re: Solving the backward compatibility issue -- working with clients of old versions
gaohoward Dec 13, 2012 10:08 AM (in response to ataylor)ok, i made some changes to ServerLocatorImpl so that if the initialConnectors is empty, it will always be a null. For every place where an empty array is required, I give a proper conversion.
it works now. I'll do more tests.
-
18. Re: Solving the backward compatibility issue -- working with clients of old versions
clebert.suconic Dec 13, 2012 5:58 PM (in response to ataylor)It looks good...
just one minor observation:
if you could just fix the alignments on these new statements you are adding:
if(localBindPort < 0)
^^ it would be better to keep the space as everything else. We don't have checkstyle now but we are that on our wish list.. better to avoiding adding future checkstyle errors
Also: I will ask you a favour: Please add a big javadoc warning on ServerLocator that any new control field needs to be transient as that class is serialized over the wire
-
19. Re: Solving the backward compatibility issue -- working with clients of old versions
gaohoward Dec 14, 2012 12:59 AM (in response to clebert.suconic)will do that. Just let you know it's now all working well. I'll co-op with andy to get the commit done.