Java EE service engine optimization

Hi,

I saw this statement on the Java EE service engine in relation to Glassfish:

"In-process communication between components of application server and JBI components to increase request processing speed."

What does this mean exactly, if I let two EJB communicate with eachother over the NMR as a webservices with a SOAP bindings?

Will it be network HTTP/SOAP request, or is there some optimization? Ie only data marshalling between classloaders similar to in-JVM remote ejb communication (ie a pass-by-value kind of thing)?

What degree of performance penalty would I get for going through the router compared to using straight remote ejb interfaces?

thanks for any help,

-Kristoffer

[742 byte] By [ekrisjoa] at [2007-11-27 11:24:12]
# 1

...or even better, is it possible that the service engine somehow is able to optimize calls as local if these web service EJBs are located in the same service unit?

regards,

-Kristoffer

ekrisjoa at 2007-7-29 15:56:50 > top of Java-index,Enterprise & Remote Computing,Enterprise Technologies...
# 2

Actually, it's more like what you said in your second email. When you have a service developed using EJB and a service in a service container like BPEL on JBI side, and you need communication between these two, since ejb based web services don't interact with NMR, the normally mechanism would be to go through http/soap route, but Java EE Service Engine optimizes this so that the call between these two would be a local call.

Suresh-JBIa at 2007-7-29 15:56:50 > top of Java-index,Enterprise & Remote Computing,Enterprise Technologies...
# 3

This is good news! So if I equip my EJBs with local interfaces and package them in the same service unit, then the call would be like a call-by-reference without overhead of marshalling data? Is this correct?

Another question, is it possible to somehow dynamically choose a binding for an EJB? As i understood it is only possible to specify this in the wsdl at design time? Also things like location etc is not possible to know at design time, and I need some way of configuring this at runtime.

Is this possible?

regards,

-Kristoffer

ekrisjoa at 2007-7-29 15:56:50 > top of Java-index,Enterprise & Remote Computing,Enterprise Technologies...
# 4

I guess the reason why i am confused is because I can only see one way for invoking a SOAP/HTTP binding. A socket is accepted and a new thread is spawned on the provider side while the consumer is waiting for an response.

In this case it is not exactly clear what is happening because of optimzation. A lot of questions pops up, is a new thread spawned? what mechanism carry my data to the provider? Is there a network hop? What classloaders is involved? Do I need to make my data serializable? etc etc

Would it not be better if there were some internal protocol binding provided that exactly specifies this? And what if I only want to expose my web service internally within my application domain, and not as an external HTTP endpoint?

ekrisjoa at 2007-7-29 15:56:50 > top of Java-index,Enterprise & Remote Computing,Enterprise Technologies...
# 5

Kristoffer,

When two EJB's communicate through the NMR then they do not communicate through SOAP/HTTP bindings at all.

Check out the following links for discussions on how the JavaEE SE works.

- http://java.sun.com/developer/technicalArticles/J2EE/sunjavaee_engine/

- http://blogs.sun.com/fkieviet/entry/javaone_2007 (see link to BOF 8745)

cheers

jason

> I guess the reason why i am confused is because I can

> only see one way for invoking a SOAP/HTTP binding.

jason.baragrya at 2007-7-29 15:56:50 > top of Java-index,Enterprise & Remote Computing,Enterprise Technologies...
# 6

Thanks alot for the the info. Will read it through :-)

-Kristoffer

ekrisjoa at 2007-7-29 15:56:50 > top of Java-index,Enterprise & Remote Computing,Enterprise Technologies...