[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.technology.equinox] Re: Equinox in a Servlet Container Threading Model

Michael Suwiryo schrieb:
> Hi,
> 
> I'm trying to find documentation/information about threading model in 
> Equinox especially when deploy in a Servlet Container.

I guess the best available documentation out there is the source code
itself. :) Unfortunately, I don't think that it is documented elsewhere.

> a) How is a single request from client to server handled on the server?
> b) Does the processing happen on the App.Server HTTP Thread that intercepts 
> the request?
> c) Does the OSGI runtime (Equinox) inside the J2EE App. Server have any 
> daemon threads (threads that outlive a user request)?

I assume that you are using the ServletBridge in this case. The
ServletBridge launches and Equinox framework instance. This instance has
background threads running for event processing and other stuff. Maybe
there is some documentation about this out there.

For a regular HTTP request cycle no additional threads are created. All
processing of the ServletBridge happens in the app server request
processing thread.

> d) How is the Eclipse Jobs API implemented in the J2EE App. Server?

It's the same implementation that runs inside Eclipse RCP, i.e. it's not
implemented differently. The Jobs API processes jobs on different
threads. If you schedule a new job from within a servlet, the job is
executed on a different thread. The Jobs plug-in can be configured to
set the daemon flag on created flags.

> e) In the case of RAP (multi-user scenario), is there any thread 
> synchronization involved in the OSGI runtime?

The RAP thread model is indeed very different. You may ask this question
on the RAP newsgroup.

-Gunnar

-- 
Gunnar Wagenknecht
gunnar@xxxxxxxxxxxxxxx
http://wagenknecht.org/