db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Knut Anders Hatlen (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (DERBY-5706) Clean up statements in CreateTableFromQueryTest
Date Tue, 24 Apr 2012 09:57:34 GMT

     [ https://issues.apache.org/jira/browse/DERBY-5706?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Knut Anders Hatlen updated DERBY-5706:
--------------------------------------

    Attachment: d5706-1a.diff

Attaching a patch that removes the statement field and instead calls createStatement() as
needed in the test methods. This also allowed removal of tearDown() and simplification of
setUp().

The patch additionally removes unused imports and closes a ResultSet that's left open.
                
> Clean up statements in CreateTableFromQueryTest
> -----------------------------------------------
>
>                 Key: DERBY-5706
>                 URL: https://issues.apache.org/jira/browse/DERBY-5706
>             Project: Derby
>          Issue Type: Improvement
>          Components: Test
>    Affects Versions: 10.9.0.0
>            Reporter: Knut Anders Hatlen
>            Assignee: Knut Anders Hatlen
>            Priority: Minor
>         Attachments: d5706-1a.diff
>
>
> CreateTableFromQueryTest has a Statement field that it closes, but doesn't null out,
in tearDown(). Since the field isn't nulled out, it cannot be garbage collected, and one Statement
per test case will be left on the heap after completion.

--
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

        

Mime
View raw message