Reiner Rosin <[EMAIL PROTECTED]> writes
>Another way might be to influence the right people to change the EJB specs.
>I think there is a strong need to add the possibility to have own threads
>within the EJB server.

Or perhaps better still would be a standard way to start / run some sort
of mini "servlet processes" within the same JVM as the EJB container.
Basically like Rickard's XS eXtensible Server framework ideas, but with
standardized hooks to plug things together in other servers too.

The quoted example of a Job Scheduling system seems to fit this model
quite nicely - sleeping until a job needs to be run, then making the
necessary EJB wake up calls "from the outside".

Obviously some form of "sandbox" like security policy may be required /
desirable to guard the main EJB Container but that's an implementation
detail.

Such standardized "in-process servlet" hooks would certainly help people
to write more server-independent code in all those cases where you need
a "standalone server class accessible as a JNDI resource" to stay clean
within the EJB Architecture model, and particularly when the resource is
only required during the lifetime of the EJB Server.


Given that EJB is primarily a synchronous request-response architecture
(at the moment), IMHO people are trying to use threads in the EJBean to
mostly mimic an asynchronous request, which is probably far cleaner and
simpler if done on the client side using existing EJB semantics.
Equally, one could also argue this scenario may also be achieved using a
JMS Pub/Sub channel(s) for the client / server invocation and response.

Remember, EJB is not always "The answer, the whole answer, and nothing
but the answer" to mis-quote a famous phrase - your application
architecture may well have EJB for only part of the solution.


Just a thought.


- Jorgen

------------------------------------------------------------
| Software Technologies  ----:----  http://www.SwTech.com/ |
| ----------->  One-stop Developer Reference  <----------- |
| Technical reference for professional software developers |
------------------------------------------------------------

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to