You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@bookkeeper.apache.org by GitBox <gi...@apache.org> on 2018/03/12 21:22:49 UTC
[GitHub] merlimat opened a new pull request #1249: Fixed Journal static empty array list recycling
merlimat opened a new pull request #1249: Fixed Journal static empty array list recycling
URL: https://github.com/apache/bookkeeper/pull/1249
When `journalSyncData=false`, we passing `EMPTY_ARRAY_LIST` to the `ForceWriteThread` when the journal is rolled over.
I have seen this exception:
```
18:39:52.285 [ForceWriteThread] ERROR org.apache.bookkeeper.bookie.BookieCriticalThread - Uncaught exception in thread ForceWriteThread and is exiting!
java.lang.NullPointerException: null
at io.netty.util.Recycler$DefaultHandle.recycle(Recycler.java:219) ~[io.netty-netty-all-4.1.21.Final.jar:4.1.21.Final]
at org.apache.bookkeeper.common.collections.RecyclableArrayList.recycle(RecyclableArrayList.java:55) ~[org.apache.bookkeeper-bookkeeper-server-shaded-4.7.0-SNAPSHOT.jar:4.7.0-SNAPSHOT]
at org.apache.bookkeeper.bookie.Journal$ForceWriteRequest.recycle(Journal.java:402) ~[org.apache.bookkeeper-bookkeeper-server-shaded-4.7.0-SNAPSHOT.jar:4.7.0-SNAPSHOT]
at org.apache.bookkeeper.bookie.Journal$ForceWriteRequest.access$1(Journal.java:399) ~[org.apache.bookkeeper-bookkeeper-server-shaded-4.7.0-SNAPSHOT.jar:4.7.0-SNAPSHOT]
at org.apache.bookkeeper.bookie.Journal$ForceWriteThread.run(Journal.java:506) ~[org.apache.bookkeeper-bookkeeper-server-shaded-4.7.0-SNAPSHOT.jar:4.7.0-SNAPSHOT]
```
This is due to calling `recycle()` twice on the same `EMPTY_ARRAY_LIST` instance. The solution is that `EMPTY_ARRAY_LIST` should not be a pooled instance and we should check that before recycling.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services