Due to the non deterministic nature of thread scheduling this is hard to replicate since it requires, the call to changeRate to come in at that specific point, AFAICT this will only happen after the consumer is first created, so the condition is far more likely to occur if you are creating and closing consumers frequently.
However I can easily get the condition to occur by inserting an artifical Thread.sleep(10) here: | | if (sendCount == num) | { | | *** here | try | { | Thread.sleep(10); | } | catch (Exception e) | { | | } | ** end here | | | clientAccepting = false; | | firstTime = false; | } | Adding proper synchronization around changeRate solves the problem, View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4135625#4135625 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4135625 _______________________________________________ jboss-user mailing list jboss-user@lists.jboss.org https://lists.jboss.org/mailman/listinfo/jboss-user