You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Knut Anders Hatlen (JIRA)" <ji...@apache.org> on 2012/04/24 14:15:34 UTC
[jira] [Created] (DERBY-5708) simpleThread test doesn't release
connection
Knut Anders Hatlen created DERBY-5708:
-----------------------------------------
Summary: simpleThread test doesn't release connection
Key: DERBY-5708
URL: https://issues.apache.org/jira/browse/DERBY-5708
Project: Derby
Issue Type: Bug
Components: Test
Affects Versions: 10.9.0.0
Reporter: Knut Anders Hatlen
Assignee: Knut Anders Hatlen
The simpleThread test, which is run by LangHarnessJavaTest, stores its connection in a static field. It doesn't close the connection, or clear the static field, before returning. So the connection is left open for the rest of the test run (potentially for the entire duration of suites.All).
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Closed] (DERBY-5708) simpleThread test doesn't release
connection
Posted by "Knut Anders Hatlen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DERBY-5708?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Knut Anders Hatlen closed DERBY-5708.
-------------------------------------
Resolution: Fixed
Fix Version/s: 10.9.0.0
Issue & fix info: (was: Patch Available)
Committed revision 1330197.
> simpleThread test doesn't release connection
> --------------------------------------------
>
> Key: DERBY-5708
> URL: https://issues.apache.org/jira/browse/DERBY-5708
> Project: Derby
> Issue Type: Bug
> Components: Test
> Affects Versions: 10.9.0.0
> Reporter: Knut Anders Hatlen
> Assignee: Knut Anders Hatlen
> Fix For: 10.9.0.0
>
> Attachments: d5708-1a.diff
>
>
> The simpleThread test, which is run by LangHarnessJavaTest, stores its connection in a static field. It doesn't close the connection, or clear the static field, before returning. So the connection is left open for the rest of the test run (potentially for the entire duration of suites.All).
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (DERBY-5708) simpleThread test doesn't release
connection
Posted by "Knut Anders Hatlen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DERBY-5708?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Knut Anders Hatlen updated DERBY-5708:
--------------------------------------
Attachment: d5708-1a.diff
The attached patch makes simpleTest close and forget the connection before returning.
It also fixes another problem with the test: The test starts four threads that use a shared connection to perform queries. However, it returns just after starting the tests, and doesn't wait to see if the threads succeeded. The patch makes it wait until the threads have completed before returning. (This part of the patch was needed to prevent the new cleanup code to close and null out the connection before the threads were done with it.)
The test is still a bit strange, though. For example, it ignores exceptions in the threads. Only wrong results cause a test failure.
> simpleThread test doesn't release connection
> --------------------------------------------
>
> Key: DERBY-5708
> URL: https://issues.apache.org/jira/browse/DERBY-5708
> Project: Derby
> Issue Type: Bug
> Components: Test
> Affects Versions: 10.9.0.0
> Reporter: Knut Anders Hatlen
> Assignee: Knut Anders Hatlen
> Attachments: d5708-1a.diff
>
>
> The simpleThread test, which is run by LangHarnessJavaTest, stores its connection in a static field. It doesn't close the connection, or clear the static field, before returning. So the connection is left open for the rest of the test run (potentially for the entire duration of suites.All).
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (DERBY-5708) simpleThread test doesn't release
connection
Posted by "Knut Anders Hatlen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DERBY-5708?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Knut Anders Hatlen updated DERBY-5708:
--------------------------------------
Issue & fix info: Patch Available
> simpleThread test doesn't release connection
> --------------------------------------------
>
> Key: DERBY-5708
> URL: https://issues.apache.org/jira/browse/DERBY-5708
> Project: Derby
> Issue Type: Bug
> Components: Test
> Affects Versions: 10.9.0.0
> Reporter: Knut Anders Hatlen
> Assignee: Knut Anders Hatlen
> Attachments: d5708-1a.diff
>
>
> The simpleThread test, which is run by LangHarnessJavaTest, stores its connection in a static field. It doesn't close the connection, or clear the static field, before returning. So the connection is left open for the rest of the test run (potentially for the entire duration of suites.All).
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira