Is there a reason why the default implementation of HttpInvokerServiceExporter.createObjectInputStream does not supply a classloader to the CodebaseAwareObjectInputStream?
This prevents having spring.jar loaded by Tomcat's shared classloader and then passing application related classes into remote invocations (when those classes are under WEB-INF).
A trivial subclass of HttpInvokerServiceExporter solves the problem (for me at least), but it doesn't seem like I *should* have to do this.
BTW, +1 (more) for spring in that I can actually *fix* this without having to change spring code.Code:public class SharedLibHttpInvokerServiceExporter extends HttpInvokerServiceExporter { @Override protected ObjectInputStream createObjectInputStream(InputStream is) throws IOException { return new CodebaseAwareObjectInputStream(is, ClassUtils.getDefaultClassLoader(), null); } }
Thanks,
Kevin


Reply With Quote