commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Terry K <tyrone.k...@thomson.com>
Subject selection algorithm used by borrowObject
Date Tue, 23 Oct 2007 22:25:39 GMT

Out of a collection of idle objects to choose from, which object will the
borrowObject() method return? Is it the oldest idle object? A random object?
The next object in an arraylist?

I want to pool JMS sessions and ideally would prefer an Iterator of the idle
objects to check for messages. Otherwise, i will have to borrow all objects
testing for messages then return all the objects back into the pool. 
Convoluted, I know.

On the other hand I want to round-robin utilise the pooled JMS Sessions.

Alll feedback welcome.


-- 
View this message in context: http://www.nabble.com/selection-algorithm-used-by-borrowObject-tf4680786.html#a13375069
Sent from the Commons - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
For additional commands, e-mail: user-help@commons.apache.org


Mime
View raw message