You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tomee.apache.org by "David Blevins (JIRA)" <ji...@apache.org> on 2008/03/28 22:42:24 UTC
[jira] Created: (OPENEJB-786) Stateless Container StrictPooling
option ignored
Stateless Container StrictPooling option ignored
------------------------------------------------
Key: OPENEJB-786
URL: https://issues.apache.org/jira/browse/OPENEJB-786
Project: OpenEJB
Issue Type: Bug
Reporter: David Blevins
Fix For: 3.0.x
Setting PoolSize to 100 and StrictPooling to true should do exactly what you want (i.e. block requests in a wait state till one of the 100 instances are returned to the pool). If this isn't working it's definitely a bug.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OPENEJB-786) Stateless Container StrictPooling
option ignored
Posted by "Manu T George (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENEJB-786?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12583632#action_12583632 ]
Manu T George commented on OPENEJB-786:
---------------------------------------
Hi,
I believe that the problem is in the method poolInstance of the StatelessInstanceManager.
Currently we do
if (strictPooling) {
pool.push(bean);
poolQueue.notifyWaitingThreads();
}
We do not do a check here and since none of the methods are synchronized in the StatelessInstanceManager this will not work. A better thing to do is to check
if (strictPooling) {
if(pool.size() < poolLimit){
pool.push(bean);
poolQueue.notifyWaitingThreads();
} else {
freeInstance(callContext, (Instance)bean);
}
However I believe this also can fail in very rare cases. i.e when the thread executing this method is paused by the scheduler after the pool size check and another thread pushes a bean inside then the size will again exceed the poolLimit by 1. Now to prevent this we need to synchronize the size checks and the push/pop operations together in a block.
On the other hand if its ok for the pool size to slightly exceed the set size then the synchronisation is not required. The synchronisation will reduce performance while not doing will result in pool size exceeding the limit by 1.
Comments/Suggestions/Corrections Please :).
> Stateless Container StrictPooling option ignored
> ------------------------------------------------
>
> Key: OPENEJB-786
> URL: https://issues.apache.org/jira/browse/OPENEJB-786
> Project: OpenEJB
> Issue Type: Bug
> Reporter: David Blevins
> Fix For: 3.0.x
>
>
> Setting PoolSize to 100 and StrictPooling to true should do exactly what you want (i.e. block requests in a wait state till one of the 100 instances are returned to the pool). If this isn't working it's definitely a bug.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (OPENEJB-786) Stateless Container StrictPooling
option ignored
Posted by "Manu T George (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENEJB-786?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Manu T George resolved OPENEJB-786.
-----------------------------------
Resolution: Fixed
Fix Version/s: (was: 3.0.x)
3.0
Fixed by adding a check for pool size when pushing back to pool. Also checks and inserts/removals have been put inside synchronized blocks. Fixed in rev 643879
> Stateless Container StrictPooling option ignored
> ------------------------------------------------
>
> Key: OPENEJB-786
> URL: https://issues.apache.org/jira/browse/OPENEJB-786
> Project: OpenEJB
> Issue Type: Bug
> Reporter: David Blevins
> Assignee: Manu T George
> Fix For: 3.0
>
>
> Setting PoolSize to 100 and StrictPooling to true should do exactly what you want (i.e. block requests in a wait state till one of the 100 instances are returned to the pool). If this isn't working it's definitely a bug.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Reopened: (OPENEJB-786) Stateless Container StrictPooling
option ignored
Posted by "Manu T George (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENEJB-786?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Manu T George reopened OPENEJB-786:
-----------------------------------
On Large nos of clients (say 100) connecting simultaneously some errors are getting thrown. Need to analyze this
> Stateless Container StrictPooling option ignored
> ------------------------------------------------
>
> Key: OPENEJB-786
> URL: https://issues.apache.org/jira/browse/OPENEJB-786
> Project: OpenEJB
> Issue Type: Bug
> Reporter: David Blevins
> Assignee: Manu T George
> Fix For: 3.0
>
>
> Setting PoolSize to 100 and StrictPooling to true should do exactly what you want (i.e. block requests in a wait state till one of the 100 instances are returned to the pool). If this isn't working it's definitely a bug.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (OPENEJB-786) Stateless Container StrictPooling
option ignored
Posted by "Manu T George (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENEJB-786?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Manu T George resolved OPENEJB-786.
-----------------------------------
Resolution: Fixed
Fixed at revision 651451
> Stateless Container StrictPooling option ignored
> ------------------------------------------------
>
> Key: OPENEJB-786
> URL: https://issues.apache.org/jira/browse/OPENEJB-786
> Project: OpenEJB
> Issue Type: Bug
> Reporter: David Blevins
> Assignee: Manu T George
> Fix For: 3.0.1
>
> Attachments: stateless-pool.patch
>
>
> Setting PoolSize to 100 and StrictPooling to true should do exactly what you want (i.e. block requests in a wait state till one of the 100 instances are returned to the pool). If this isn't working it's definitely a bug.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OPENEJB-786) Stateless Container StrictPooling
option ignored
Posted by "Manu T George (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENEJB-786?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12584540#action_12584540 ]
Manu T George commented on OPENEJB-786:
---------------------------------------
Fixed at revision 643872
> Stateless Container StrictPooling option ignored
> ------------------------------------------------
>
> Key: OPENEJB-786
> URL: https://issues.apache.org/jira/browse/OPENEJB-786
> Project: OpenEJB
> Issue Type: Bug
> Reporter: David Blevins
> Assignee: Manu T George
> Fix For: 3.0.x
>
>
> Setting PoolSize to 100 and StrictPooling to true should do exactly what you want (i.e. block requests in a wait state till one of the 100 instances are returned to the pool). If this isn't working it's definitely a bug.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Closed: (OPENEJB-786) Stateless Container StrictPooling
option ignored
Posted by "Manu T George (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENEJB-786?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Manu T George closed OPENEJB-786.
---------------------------------
> Stateless Container StrictPooling option ignored
> ------------------------------------------------
>
> Key: OPENEJB-786
> URL: https://issues.apache.org/jira/browse/OPENEJB-786
> Project: OpenEJB
> Issue Type: Bug
> Reporter: David Blevins
> Assignee: Manu T George
> Fix For: 3.0.1
>
> Attachments: stateless-pool.patch
>
>
> Setting PoolSize to 100 and StrictPooling to true should do exactly what you want (i.e. block requests in a wait state till one of the 100 instances are returned to the pool). If this isn't working it's definitely a bug.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Assigned: (OPENEJB-786) Stateless Container StrictPooling
option ignored
Posted by "Manu T George (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENEJB-786?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Manu T George reassigned OPENEJB-786:
-------------------------------------
Assignee: Manu T George
> Stateless Container StrictPooling option ignored
> ------------------------------------------------
>
> Key: OPENEJB-786
> URL: https://issues.apache.org/jira/browse/OPENEJB-786
> Project: OpenEJB
> Issue Type: Bug
> Reporter: David Blevins
> Assignee: Manu T George
> Fix For: 3.0.x
>
>
> Setting PoolSize to 100 and StrictPooling to true should do exactly what you want (i.e. block requests in a wait state till one of the 100 instances are returned to the pool). If this isn't working it's definitely a bug.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (OPENEJB-786) Stateless Container StrictPooling
option ignored
Posted by "David Blevins (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENEJB-786?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
David Blevins updated OPENEJB-786:
----------------------------------
Fix Version/s: (was: 3.0)
3.0.1
> Stateless Container StrictPooling option ignored
> ------------------------------------------------
>
> Key: OPENEJB-786
> URL: https://issues.apache.org/jira/browse/OPENEJB-786
> Project: OpenEJB
> Issue Type: Bug
> Reporter: David Blevins
> Assignee: Manu T George
> Fix For: 3.0.1
>
> Attachments: stateless-pool.patch
>
>
> Setting PoolSize to 100 and StrictPooling to true should do exactly what you want (i.e. block requests in a wait state till one of the 100 instances are returned to the pool). If this isn't working it's definitely a bug.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (OPENEJB-786) Stateless Container StrictPooling
option ignored
Posted by "Manu T George (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENEJB-786?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Manu T George updated OPENEJB-786:
----------------------------------
Attachment: stateless-pool.patch
> Stateless Container StrictPooling option ignored
> ------------------------------------------------
>
> Key: OPENEJB-786
> URL: https://issues.apache.org/jira/browse/OPENEJB-786
> Project: OpenEJB
> Issue Type: Bug
> Reporter: David Blevins
> Assignee: Manu T George
> Fix For: 3.0
>
> Attachments: stateless-pool.patch
>
>
> Setting PoolSize to 100 and StrictPooling to true should do exactly what you want (i.e. block requests in a wait state till one of the 100 instances are returned to the pool). If this isn't working it's definitely a bug.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.