You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@avalon.apache.org by Andrei Ivanov <my...@surfeu.fi> on 2002/06/01 10:43:40 UTC
Limiting resources used by Cornerstone's ServerSocketFactory
Hi,
What is the correct way to unallocate / limit resources (number of open
sockets etc) in Cornerston's ServerSocketFactory. My phoenix application
crashes with out of memory error under high request rates. Any examples?
Andrei
PS my server class extends
org.apache.avalon.cornerstone.services.connection.AbstractService; and
corresponding handler - handles connections.
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>
Re: Limiting resources used by Cornerstone's ServerSocketFactory
Posted by Peter Donald <pe...@apache.org>.
On Sat, 1 Jun 2002 18:43, Andrei Ivanov wrote:
> Hi,
> What is the correct way to unallocate / limit resources (number of open
> sockets etc) in Cornerston's ServerSocketFactory.
The SocketManager does not limit connections in any way but you can limit the
connections in ConnectionManager by passing in a ThreadPool that only has a
limited number of items in pool.
Without looking at the code I believe there was a method like
ThreadPool getThreadPool(ThreadManager)
or maybe
String getThreadPoolName()
Overide these in AbstractService and return a pool that has a fixed size. And
that should limit number of connections occuring.
--
Cheers,
Peter Donald
Sufficiently advanced science is
indistinguishable from magic"
-- Arthur C. Clarke
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>