Robert Geisler [http://community.jboss.org/people/robert.geisler] created the 
discussion

"Re: EJB3 Session Bean Pool"

To view the discussion, visit: http://community.jboss.org/message/597828#597828

--------------------------------------------------------------
thank you, carlo for response.

of course you are right, one could extend StrictMaxPool and enlarge 
strictMaxSize semaphore. but what is the benefit of using the semaphore at all? 
isnt it an unnecessary overhead? we believe we do not need a maximum to limit 
creation of instances, but we need a maximum of pooled instances!

so i thought about a pool implementation backed by a simple array with length 
maxSize:
1. get() looks into the array and returns and removes the last element -if 
available;
2. otherwise create a new one, no maximum for creating instances (aka tolerant)!
3. instances that are released go back into the array -if they fit into it 
(maxSize = array length);
4. otherwise they are removed immediately.

this seems to be quite simple to implement...?
would you expect any issues with such an implementation?
--------------------------------------------------------------

Reply to this message by going to Community
[http://community.jboss.org/message/597828#597828]

Start a new discussion in EJB3 at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2029]

_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to