ws-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andreas Schoelver <tengri_let...@web.de>
Subject Re: jetty with XML-RPC
Date Wed, 23 Feb 2005 20:32:24 GMT
To be really sure, take a look at the sources.

>    server.addHandler("some.name", new MyHandler());

The XmlRpcServer is instantiated once.
The handler is instantiated once (new MyHandler())
and added to the server instance.

The is only one server instance but it uses multiple workers.
Each worker gets a reference to the handler.

To duplicate the handler, it would at least have to support the 
interface 'Clonable' to allow others to clone it.
The class 'Object' does not support Clonable on it's own.

addHandler only expects an instance of Object.
It makes no assumptions on whether the handler is clonable.
(The server's code shows that it does not even try to find out.)

The only thing being cloned is the requestParams Vector
of XmlRpcRequestProcessor.

So long
Andreas

On Mon, 21 Feb 2005 14:48:36 +0200
Paolo Campanella <paolo@mighty.co.za> wrote:

[...]
> To be really sure, you should make your servlet slow (put in a sleep
> statement). Or else, you would really have to test it under high load:
> if Jetty's maintaining a pool of handlers (the typical behaviour I
> believe; certainly the case in my own configuration) and the servlet
> executes too quickly, it can _appear_ to have just one handler.
> 
> 
> Bye
> 
> Paolo
> 
> 

Mime
View raw message