You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@bookkeeper.apache.org by "Ivan Kelly (Created) (JIRA)" <ji...@apache.org> on 2011/10/19 10:56:10 UTC

[jira] [Created] (BOOKKEEPER-87) TestHedwigHub exhausts direct buffer memory with netty 3.2.4.Final

TestHedwigHub exhausts direct buffer memory with netty 3.2.4.Final
------------------------------------------------------------------

                 Key: BOOKKEEPER-87
                 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-87
             Project: Bookkeeper
          Issue Type: Bug
            Reporter: Ivan Kelly


The error below happens. This happens because the test starts and stops a lot of bookies, and hedwig hub for each test. Each of these allocates some Direct Buffer memory, which doesn't automatically get returned the the pool once the test is finished. The DirectByteBuffers do seem to be garbage collected, but they don't actually clean up the direct buffer memory until an internal cleaner runs later. I can't find a way to run this manually.

This happens since BOOKKEEPER-65, as the new netty allocates more direct buffers. A work around for the problem for the moment is to run test with 1G heap.
$ mvn test -DargLine="-Xmx1G"


<snip>
Running org.apache.hedwig.server.integration.TestHedwigHub
Tests run: 92, Failures: 0, Errors: 47, Skipped: 0, Time elapsed: 60.523 sec <<< FAILURE!

Results :

Tests in error: 
  testAsyncHubUnsubscribeWithInvalidSubscriberId[1](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
  testManualConsumeClient[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
  testManualConsumeClient[2](org.apache.hedwig.server.integration.TestHedwigHub)
  testAttachToSubscriptionSuccess[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
  testAttachToSubscriptionSuccess[2](org.apache.hedwig.server.integration.TestHedwigHub)
  testServerRedirect[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
  testServerRedirect[2](org.apache.hedwig.server.integration.TestHedwigHub)
  testSubscribeAndConsume[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
  testSubscribeAndConsume[2](org.apache.hedwig.server.integration.TestHedwigHub)
  testServerFailoverPublishOnly[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
  testServerFailoverPublishOnly[2](org.apache.hedwig.server.integration.TestHedwigHub)


--
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] (BOOKKEEPER-87) TestHedwigHub exhausts direct buffer memory with netty 3.2.4.Final

Posted by "Ivan Kelly (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/BOOKKEEPER-87?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ivan Kelly updated BOOKKEEPER-87:
---------------------------------

    Attachment: BOOKKEEPER-87.diff

Patch increases the max heap for hedwig server testing.
                
> TestHedwigHub exhausts direct buffer memory with netty 3.2.4.Final
> ------------------------------------------------------------------
>
>                 Key: BOOKKEEPER-87
>                 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-87
>             Project: Bookkeeper
>          Issue Type: Bug
>            Reporter: Ivan Kelly
>             Fix For: 4.0.0
>
>         Attachments: BOOKKEEPER-87.diff
>
>
> The error below happens. This happens because the test starts and stops a lot of bookies, and hedwig hub for each test. Each of these allocates some Direct Buffer memory, which doesn't automatically get returned the the pool once the test is finished. The DirectByteBuffers do seem to be garbage collected, but they don't actually clean up the direct buffer memory until an internal cleaner runs later. I can't find a way to run this manually.
> This happens since BOOKKEEPER-65, as the new netty allocates more direct buffers. A work around for the problem for the moment is to run test with 1G heap.
> $ mvn test -DargLine="-Xmx1G"
> <snip>
> Running org.apache.hedwig.server.integration.TestHedwigHub
> Tests run: 92, Failures: 0, Errors: 47, Skipped: 0, Time elapsed: 60.523 sec <<< FAILURE!
> Results :
> Tests in error: 
>   testAsyncHubUnsubscribeWithInvalidSubscriberId[1](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testManualConsumeClient[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testManualConsumeClient[2](org.apache.hedwig.server.integration.TestHedwigHub)
>   testAttachToSubscriptionSuccess[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testAttachToSubscriptionSuccess[2](org.apache.hedwig.server.integration.TestHedwigHub)
>   testServerRedirect[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testServerRedirect[2](org.apache.hedwig.server.integration.TestHedwigHub)
>   testSubscribeAndConsume[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testSubscribeAndConsume[2](org.apache.hedwig.server.integration.TestHedwigHub)
>   testServerFailoverPublishOnly[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testServerFailoverPublishOnly[2](org.apache.hedwig.server.integration.TestHedwigHub)

--
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] [Commented] (BOOKKEEPER-87) TestHedwigHub exhausts direct buffer memory with netty 3.2.4.Final

Posted by "Flavio Junqueira (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/BOOKKEEPER-87?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13151949#comment-13151949 ] 

Flavio Junqueira commented on BOOKKEEPER-87:
--------------------------------------------

+1
                
> TestHedwigHub exhausts direct buffer memory with netty 3.2.4.Final
> ------------------------------------------------------------------
>
>                 Key: BOOKKEEPER-87
>                 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-87
>             Project: Bookkeeper
>          Issue Type: Bug
>            Reporter: Ivan Kelly
>            Assignee: Ivan Kelly
>             Fix For: 4.0.0
>
>         Attachments: BOOKKEEPER-87.diff
>
>
> The error below happens. This happens because the test starts and stops a lot of bookies, and hedwig hub for each test. Each of these allocates some Direct Buffer memory, which doesn't automatically get returned the the pool once the test is finished. The DirectByteBuffers do seem to be garbage collected, but they don't actually clean up the direct buffer memory until an internal cleaner runs later. I can't find a way to run this manually.
> This happens since BOOKKEEPER-65, as the new netty allocates more direct buffers. A work around for the problem for the moment is to run test with 1G heap.
> $ mvn test -DargLine="-Xmx1G"
> <snip>
> Running org.apache.hedwig.server.integration.TestHedwigHub
> Tests run: 92, Failures: 0, Errors: 47, Skipped: 0, Time elapsed: 60.523 sec <<< FAILURE!
> Results :
> Tests in error: 
>   testAsyncHubUnsubscribeWithInvalidSubscriberId[1](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testManualConsumeClient[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testManualConsumeClient[2](org.apache.hedwig.server.integration.TestHedwigHub)
>   testAttachToSubscriptionSuccess[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testAttachToSubscriptionSuccess[2](org.apache.hedwig.server.integration.TestHedwigHub)
>   testServerRedirect[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testServerRedirect[2](org.apache.hedwig.server.integration.TestHedwigHub)
>   testSubscribeAndConsume[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testSubscribeAndConsume[2](org.apache.hedwig.server.integration.TestHedwigHub)
>   testServerFailoverPublishOnly[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testServerFailoverPublishOnly[2](org.apache.hedwig.server.integration.TestHedwigHub)

--
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] [Commented] (BOOKKEEPER-87) TestHedwigHub exhausts direct buffer memory with netty 3.2.4.Final

Posted by "Hudson (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/BOOKKEEPER-87?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13152062#comment-13152062 ] 

Hudson commented on BOOKKEEPER-87:
----------------------------------

Integrated in bookkeeper-trunk #225 (See [https://builds.apache.org/job/bookkeeper-trunk/225/])
    BOOKKEEPER-87: TestHedwigHub exhausts direct buffer memory with netty 3.2.4.Final (ivank via fpj)

fpj : 
Files : 
* /zookeeper/bookkeeper/trunk/CHANGES.txt
* /zookeeper/bookkeeper/trunk/bookkeeper-server/pom.xml
* /zookeeper/bookkeeper/trunk/hedwig-server/pom.xml

                
> TestHedwigHub exhausts direct buffer memory with netty 3.2.4.Final
> ------------------------------------------------------------------
>
>                 Key: BOOKKEEPER-87
>                 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-87
>             Project: Bookkeeper
>          Issue Type: Bug
>            Reporter: Ivan Kelly
>            Assignee: Ivan Kelly
>             Fix For: 4.0.0
>
>         Attachments: BOOKKEEPER-87.diff
>
>
> The error below happens. This happens because the test starts and stops a lot of bookies, and hedwig hub for each test. Each of these allocates some Direct Buffer memory, which doesn't automatically get returned the the pool once the test is finished. The DirectByteBuffers do seem to be garbage collected, but they don't actually clean up the direct buffer memory until an internal cleaner runs later. I can't find a way to run this manually.
> This happens since BOOKKEEPER-65, as the new netty allocates more direct buffers. A work around for the problem for the moment is to run test with 1G heap.
> $ mvn test -DargLine="-Xmx1G"
> <snip>
> Running org.apache.hedwig.server.integration.TestHedwigHub
> Tests run: 92, Failures: 0, Errors: 47, Skipped: 0, Time elapsed: 60.523 sec <<< FAILURE!
> Results :
> Tests in error: 
>   testAsyncHubUnsubscribeWithInvalidSubscriberId[1](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testManualConsumeClient[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testManualConsumeClient[2](org.apache.hedwig.server.integration.TestHedwigHub)
>   testAttachToSubscriptionSuccess[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testAttachToSubscriptionSuccess[2](org.apache.hedwig.server.integration.TestHedwigHub)
>   testServerRedirect[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testServerRedirect[2](org.apache.hedwig.server.integration.TestHedwigHub)
>   testSubscribeAndConsume[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testSubscribeAndConsume[2](org.apache.hedwig.server.integration.TestHedwigHub)
>   testServerFailoverPublishOnly[2](org.apache.hedwig.server.integration.TestHedwigHub): Direct buffer memory
>   testServerFailoverPublishOnly[2](org.apache.hedwig.server.integration.TestHedwigHub)

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