airavata-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chathuri Wimalasena (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (AIRAVATA-1288) Investigate OpenJPA memory leak we are getting
Date Fri, 06 Jun 2014 19:52:01 GMT

    [ https://issues.apache.org/jira/browse/AIRAVATA-1288?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14020287#comment-14020287
] 

Chathuri Wimalasena commented on AIRAVATA-1288:
-----------------------------------------------

With help of openJPA community, we are able to fix the memory leak issue. It is a problem
with the way we close the entity manager. Previously we were doing 
finally {
            if (em != null && em.isOpen()) {
                em.close();
            }
}

Instead of that, we have to do 

finally {
            if (em != null && em.isOpen()) {
                if (em.getTransaction().isActive()){
                    em.getTransaction().rollback();
                }
                em.close();
            }
}

> Investigate OpenJPA memory leak we are getting
> ----------------------------------------------
>
>                 Key: AIRAVATA-1288
>                 URL: https://issues.apache.org/jira/browse/AIRAVATA-1288
>             Project: Airavata
>          Issue Type: Task
>            Reporter: Chathuri Wimalasena
>            Assignee: Chathuri Wimalasena
>




--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message