"ypsilon" wrote : Can you point me to a scenario where the classloader would
lead to a ClassCastException? Does this only occur upon redeployments?
|
Correct, in general
| public class DoesntGetRedeployed
| {
| public static Collection staticCollection = ...;
| }
|
| public class CodeThatGetsRedeployed
| {
| public void doSomethingBeforeRedeploy()
| {
| DoesntGetRedeployed.add(this);
| }
|
| public void doSomethingAfterRedeploy()
| {
| Object x = DoesntGetRedeployed.get();
| // x instanceof CodeThatGetsRedeployed == false
| }
| }
|
Although, I'd be impressed if you could come up with such a situation
WITHIN A TRANSACTION! :-)
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4029419#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...