-
Bug
-
Resolution: Won't Do
-
Major
-
2.5
-
None
-
Medium
-
Workaround Exists
-
The problem lies in the fact that both connect() and close() in JChannel are synchronized on the same object, the channel. Now lets assume that you have called connect() on the channel. This will eventually take us to the join(Address mbr) in ClientGmsImpl. Now if the channel cannot connect for some reason the code will be stuck here in the while(!leaving) clause until such time that the connection can be established. Now if the user in the meantime decides to quit you will have to call close() on the channel. Unfortuanately nothing will happen since the initial connect is still holding the lock to the channel. Deadlock.
Now to how to create the hanging join. That is pretty simple by just setting the disable_initial_coord flag and making sure that the entity set to be the coordinator is not available (i.e. not started). I know that you intend to deprecate this flag eventually but first of all we totally depend on this flag for a correct behaviour in our environment and secondly I assume that you will introduce something similar in the upcoming 3.0 version.