I'm using a "Scheduler" (implementing org.jboss.varia.scheduler.Schedulable) to do some taks and the logic is inside a SLSB.
The problem is that if I change the .jar with the SLSB and restart the application (changing application.xml) the application stop working (because a ClassCastException with the Home interfaces), but the timer doesn't work anymore too.
I'm using the "ServiceLocator" (from Sun) to access and caching the Home interfaces, so there should be the problem, but I was wondering if is there some way to "flush" the centralized class loader to refresh the interfaces... may be I should not duplicate the home interfaces inside the .jar with the "timer" class.
Thanks in advance,
The ServiceLocator pattern doesn't understand redeployment.
If you redeploy a shared class you also need to redeploy
Separating the home/remote interfaces in a separate
jar that does not get redeployed will also solve the problem.