Hey
Sebastien Alborini wrote:
> > Hm...yeah, that's true. The parent check is not enough, I realize that now.
> > Any suggestions on improvement? Should we check parent of parent too..or?
>
> Hi,
>
> I don't know, but the approach you took when you did the changes was "in
> the case of different jars (external ejb-ref), optimization is not
> possible, so don't allow it".
>
> Why would you think of "in the case of different jars, make optimization
> possible (ie merge, or whatever, the classloaders, during deployment)"?
> Would it be difficult/dangerous?
>
> It would be more efficient:
> - optimized calls
> - no checks necessary in JRMPCI (see the embedded tomcat test, they seem
> to take some time)
I just changed the JRMPCI optimization test. Instead of checking
classloaders I now check whether the class of the called method is the
same as the class of the "container-local" class.
This would allow the following to be optimized:
* Bean2Bean calls in same application
* Servlet2Bean calls in same EAR
* Bean2Bean calls between different applications (!) *if* the JAR's
where added to lib/ext as well so that all classes are loaded through
the system classloader.
The last one obviously makes it impossible to do hot deployment, but, if
you really want to put your beans in different JAR files and you still
want to use the call optimization, then it will work for you with the
drawback of disabling hot deployment. It's a tradeoff.
Sebastien, can you check out the new code and do the servlet test? I
don't have a Tomcat in-vm setup here so I can't test myself.
/Rickard
--
Rickard �berg
Email: [EMAIL PROTECTED]
http://www.telkel.com
http://www.jboss.org
http://www.dreambean.com