This is not what JavaRebel does. JavaRebel (as described) hot-swaps classes in memory. This is unacceptable in the case of existing connections to the system, since updated classes can violate the client logic.
As soon as the company I worked with had a similar problem and it was resolved as follows:
- An intelligent router was used as load balancing.
- the new version has been deployed up to 50% of the nodes of the (new) cluster
- new connections were delivered strictly to these updated nodes, old were balanced between the old nodes.
- old nodes were disconnected (one by one to keep the number of clients per node within)
- at the same time, the new version was deployed to stand-alone "old" nodes, and they were created as new nodes.
- due to EJB clustering, sessions and beans were assembled by other old nodes
- in the end (in a few hours) there is only one old node left, having one instance of the old version and all clients using the old version, with it
- when the last old client disconnected that node was too down
Now I am not a network guy and can not give you a lot of details (for example, what is the equipment of the router, etc.). My understanding of this can be set up quite easily, except that, if I remember correctly, we had to configure an additional Weblogic domain to deploy new versions of the application (otherwise it would be contrary to the old JNDI name).
Hope this helps.
PS Ichorus made a comment saying the application is being deployed to client servers. Thus, a router trick may not be possible. Now I see only one viable solution right now (now 21:52, I may not notice things :)) -
- Development of a new version with JNDI names with version; for example, if the client bean was under ejb / Customer in version 1, in version 2 it was under ejb / Customer2
- You have a business facade in an application with a stable basic interface (Factory-style), which, when asked by the Customer bean, tries to find the highest JNDI name (not for every call, of course, it can cache for an hour or so). This facade could (and should) be deployed as a standalone application - and was never or very rarely updated
- Now each new client will have access to deploy the latest application, and the applications will not conflict.
This approach requires careful planning and testing, but IMHO should work.
I recently changed several applications in the same way that they coexisted in the same domain (before they used the same JNDI name for different data sources).
Vladimir Dyuzhev October 21 '08 at 19:02 2008-10-21 19:02
source share