|
From: Peter d. H. <pe...@de...> - 2003-12-05 17:57:33
|
We found another Orion 2.0.2 bug recently: when deploying two Spring-based webapps on the same Orion server, we got into major classloading issues where loaded in one application would end up in the other. The problem turned out to be that, Orion does not seem to correctly set the Thread context classloader for the second and subsequent webapps that it initialises. Because Spring uses the context classloader throughout this means that any class loaded by name during Spring initialisation will get loaded from the wrong webapp. Oops. We ended up creating a version of org.springframework.web.context.ContextLoaderServlet with one extra line in init(): Thread.currentThread().setContextClassLoader(getClass().getClassLoader()); Suddenly all our problems disappeared. - Peter |