[jira] [Updated] (BOOKKEEPER-555) Make BookieServer use Netty rather than a custom IO server

2013-02-11 Thread Ivan Kelly (JIRA)

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

Ivan Kelly updated BOOKKEEPER-555:
--

Attachment: 0001-BOOKKEEPER-555-Netty-Server-for-Bookie.patch

New patch addresses Rakesh's comments except for the import thing. What do you 
mean by organise? Alphabetize?

 Make BookieServer use Netty rather than a custom IO server
 --

 Key: BOOKKEEPER-555
 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-555
 Project: Bookkeeper
  Issue Type: Bug
Reporter: Ivan Kelly
Assignee: Ivan Kelly
 Fix For: 4.3.0

 Attachments: 0001-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, BOOKKEEPER-555.patch


 Move from the custom NIO server to netty. This will make it easier to do 
 things like add more server side threads and support SSL.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (BOOKKEEPER-555) Make BookieServer use Netty rather than a custom IO server

2013-02-11 Thread Hadoop QA (JIRA)

[ 
https://issues.apache.org/jira/browse/BOOKKEEPER-555?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13575765#comment-13575765
 ] 

Hadoop QA commented on BOOKKEEPER-555:
--

Testing JIRA BOOKKEEPER-555


Patch 
[0001-BOOKKEEPER-555-Netty-Server-for-Bookie.patch|https://issues.apache.org/jira/secure/attachment/12568814/0001-BOOKKEEPER-555-Netty-Server-for-Bookie.patch]
 downloaded at Mon Feb 11 12:11:12 UTC 2013



{color:green}+1 PATCH_APPLIES{color}
{color:green}+1 CLEAN{color}
{color:green}+1 RAW_PATCH_ANALYSIS{color}
.{color:green}+1{color} the patch does not introduce any @author tags
.{color:green}+1{color} the patch does not introduce any tabs
.{color:green}+1{color} the patch does not introduce any trailing spaces
.{color:green}+1{color} the patch does not introduce any line longer than 
120
.{color:green}+1{color} the patch does adds/modifies 2 testcase(s)
{color:green}+1 RAT{color}
.{color:green}+1{color} the patch does not seem to introduce new RAT 
warnings
{color:green}+1 JAVADOC{color}
.{color:green}+1{color} the patch does not seem to introduce new Javadoc 
warnings
{color:green}+1 COMPILE{color}
.{color:green}+1{color} HEAD compiles
.{color:green}+1{color} patch compiles
.{color:green}+1{color} the patch does not seem to introduce new javac 
warnings
{color:green}+1 FINDBUGS{color}
.{color:green}+1{color} the patch does not seem to introduce new Findbugs 
warnings
{color:green}+1 TESTS{color}
.Tests run: 815
{color:green}+1 DISTRO{color}
.{color:green}+1{color} distro tarball builds with the patch 


{color:green}*+1 Overall result, good!, no -1s*{color}


The full output of the test-patch run is available at

.   https://builds.apache.org/job/bookkeeper-trunk-precommit-build/264/

 Make BookieServer use Netty rather than a custom IO server
 --

 Key: BOOKKEEPER-555
 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-555
 Project: Bookkeeper
  Issue Type: Bug
Reporter: Ivan Kelly
Assignee: Ivan Kelly
 Fix For: 4.3.0

 Attachments: 0001-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, BOOKKEEPER-555.patch


 Move from the custom NIO server to netty. This will make it easier to do 
 things like add more server side threads and support SSL.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (BOOKKEEPER-555) Make BookieServer use Netty rather than a custom IO server

2013-02-11 Thread Rakesh R (JIRA)

[ 
https://issues.apache.org/jira/browse/BOOKKEEPER-555?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13575781#comment-13575781
 ] 

Rakesh R commented on BOOKKEEPER-555:
-

Thanks [~iv...@yahoo-inc.com] for the patch.

{quote}What do you mean by organise? Alphabetize?{quote}
Unused imports exists in these classes(BookieNettyServer, BookieServer, 
BookieServerBean), just wants to clear it:)

 Make BookieServer use Netty rather than a custom IO server
 --

 Key: BOOKKEEPER-555
 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-555
 Project: Bookkeeper
  Issue Type: Bug
Reporter: Ivan Kelly
Assignee: Ivan Kelly
 Fix For: 4.3.0

 Attachments: 0001-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, BOOKKEEPER-555.patch


 Move from the custom NIO server to netty. This will make it easier to do 
 things like add more server side threads and support SSL.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Updated] (BOOKKEEPER-554) fd leaking when move ledger index file

2013-02-11 Thread Ivan Kelly (JIRA)

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

Ivan Kelly updated BOOKKEEPER-554:
--

Attachment: 0001-BOOKKEEPER-554.patch

Added @VisibleForTesting annotation. Once latest patch gets +1, ill push it in.

 fd leaking when move ledger index file
 --

 Key: BOOKKEEPER-554
 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-554
 Project: Bookkeeper
  Issue Type: Bug
  Components: bookkeeper-server
Affects Versions: 4.2.0
Reporter: Sijie Guo
Assignee: Sijie Guo
 Fix For: 4.3.0

 Attachments: 0001-BOOKKEEPER-554.patch, BOOKKEEPER-554.diff


 a file info is get when moving ledger index, but it doesn't release after 
 use. so the reference counting for file info stays more than zero, the file 
 channel would never be closed even the file is evicted from ledger cache.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (BOOKKEEPER-554) fd leaking when move ledger index file

2013-02-11 Thread Hadoop QA (JIRA)

[ 
https://issues.apache.org/jira/browse/BOOKKEEPER-554?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13575806#comment-13575806
 ] 

Hadoop QA commented on BOOKKEEPER-554:
--

Testing JIRA BOOKKEEPER-554


Patch 
[0001-BOOKKEEPER-554.patch|https://issues.apache.org/jira/secure/attachment/12568821/0001-BOOKKEEPER-554.patch]
 downloaded at Mon Feb 11 13:55:54 UTC 2013



{color:green}+1 PATCH_APPLIES{color}
{color:green}+1 CLEAN{color}
{color:green}+1 RAW_PATCH_ANALYSIS{color}
.{color:green}+1{color} the patch does not introduce any @author tags
.{color:green}+1{color} the patch does not introduce any tabs
.{color:green}+1{color} the patch does not introduce any trailing spaces
.{color:green}+1{color} the patch does not introduce any line longer than 
120
.{color:green}+1{color} the patch does adds/modifies 1 testcase(s)
{color:green}+1 RAT{color}
.{color:green}+1{color} the patch does not seem to introduce new RAT 
warnings
{color:green}+1 JAVADOC{color}
.{color:green}+1{color} the patch does not seem to introduce new Javadoc 
warnings
{color:green}+1 COMPILE{color}
.{color:green}+1{color} HEAD compiles
.{color:green}+1{color} patch compiles
.{color:green}+1{color} the patch does not seem to introduce new javac 
warnings
{color:green}+1 FINDBUGS{color}
.{color:green}+1{color} the patch does not seem to introduce new Findbugs 
warnings
{color:green}+1 TESTS{color}
.Tests run: 816
{color:green}+1 DISTRO{color}
.{color:green}+1{color} distro tarball builds with the patch 


{color:green}*+1 Overall result, good!, no -1s*{color}


The full output of the test-patch run is available at

.   https://builds.apache.org/job/bookkeeper-trunk-precommit-build/265/

 fd leaking when move ledger index file
 --

 Key: BOOKKEEPER-554
 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-554
 Project: Bookkeeper
  Issue Type: Bug
  Components: bookkeeper-server
Affects Versions: 4.2.0
Reporter: Sijie Guo
Assignee: Sijie Guo
 Fix For: 4.3.0

 Attachments: 0001-BOOKKEEPER-554.patch, BOOKKEEPER-554.diff


 a file info is get when moving ledger index, but it doesn't release after 
 use. so the reference counting for file info stays more than zero, the file 
 channel would never be closed even the file is evicted from ledger cache.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Updated] (BOOKKEEPER-555) Make BookieServer use Netty rather than a custom IO server

2013-02-11 Thread Ivan Kelly (JIRA)

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

Ivan Kelly updated BOOKKEEPER-555:
--

Attachment: 0001-BOOKKEEPER-555-Netty-Server-for-Bookie.patch

Ah, had completely missed those. Fixed now.

 Make BookieServer use Netty rather than a custom IO server
 --

 Key: BOOKKEEPER-555
 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-555
 Project: Bookkeeper
  Issue Type: Bug
Reporter: Ivan Kelly
Assignee: Ivan Kelly
 Fix For: 4.3.0

 Attachments: 0001-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0001-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, BOOKKEEPER-555.patch


 Move from the custom NIO server to netty. This will make it easier to do 
 things like add more server side threads and support SSL.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (BOOKKEEPER-555) Make BookieServer use Netty rather than a custom IO server

2013-02-11 Thread Hadoop QA (JIRA)

[ 
https://issues.apache.org/jira/browse/BOOKKEEPER-555?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13575832#comment-13575832
 ] 

Hadoop QA commented on BOOKKEEPER-555:
--

Testing JIRA BOOKKEEPER-555


Patch 
[0001-BOOKKEEPER-555-Netty-Server-for-Bookie.patch|https://issues.apache.org/jira/secure/attachment/12568824/0001-BOOKKEEPER-555-Netty-Server-for-Bookie.patch]
 downloaded at Mon Feb 11 14:51:12 UTC 2013



{color:green}+1 PATCH_APPLIES{color}
{color:green}+1 CLEAN{color}
{color:green}+1 RAW_PATCH_ANALYSIS{color}
.{color:green}+1{color} the patch does not introduce any @author tags
.{color:green}+1{color} the patch does not introduce any tabs
.{color:green}+1{color} the patch does not introduce any trailing spaces
.{color:green}+1{color} the patch does not introduce any line longer than 
120
.{color:green}+1{color} the patch does adds/modifies 2 testcase(s)
{color:green}+1 RAT{color}
.{color:green}+1{color} the patch does not seem to introduce new RAT 
warnings
{color:green}+1 JAVADOC{color}
.{color:green}+1{color} the patch does not seem to introduce new Javadoc 
warnings
{color:green}+1 COMPILE{color}
.{color:green}+1{color} HEAD compiles
.{color:green}+1{color} patch compiles
.{color:green}+1{color} the patch does not seem to introduce new javac 
warnings
{color:green}+1 FINDBUGS{color}
.{color:green}+1{color} the patch does not seem to introduce new Findbugs 
warnings
{color:green}+1 TESTS{color}
.Tests run: 815
{color:green}+1 DISTRO{color}
.{color:green}+1{color} distro tarball builds with the patch 


{color:green}*+1 Overall result, good!, no -1s*{color}


The full output of the test-patch run is available at

.   https://builds.apache.org/job/bookkeeper-trunk-precommit-build/266/

 Make BookieServer use Netty rather than a custom IO server
 --

 Key: BOOKKEEPER-555
 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-555
 Project: Bookkeeper
  Issue Type: Bug
Reporter: Ivan Kelly
Assignee: Ivan Kelly
 Fix For: 4.3.0

 Attachments: 0001-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0001-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, BOOKKEEPER-555.patch


 Move from the custom NIO server to netty. This will make it easier to do 
 things like add more server side threads and support SSL.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (BOOKKEEPER-49) bookkeeper - parallel async read same entry of same ledger will fail

2013-02-11 Thread Matteo Merli (JIRA)

[ 
https://issues.apache.org/jira/browse/BOOKKEEPER-49?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13575867#comment-13575867
 ] 

Matteo Merli commented on BOOKKEEPER-49:


Rakesh, I think that there should be an Id on the request and that should be 
addressed in BOOKKEEPER-558. Once that jira is resolved we'll just need to keep 
the map with the key + reqId.

 bookkeeper - parallel async read same entry of same ledger will fail
 

 Key: BOOKKEEPER-49
 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-49
 Project: Bookkeeper
  Issue Type: Bug
  Components: bookkeeper-client
Affects Versions: 4.0.0, 4.1.0
Reporter: Sijie Guo
Assignee: Sijie Guo
 Fix For: 4.3.0

 Attachments: 
 0001-BOOKKEEPER-49-bookkeeper-parallel-async-read-same-en.patch


 all ledgers shared a PerChannelBookieClient. 
 PerChannelBookieClient put all the read requests in a 
 ConcurrentHashMapCompletionKey, ReadCompletion map called readCompletions, 
 which is indexed by CompletionKey. If two read requests have same entryId and 
 same ledgerId, they have the same CompletionKey, the latter one will 
 overwrite the previous one. So a read request's callback will not be invoked.
 we may need to chain the callbacks for same completion keys.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (BOOKKEEPER-49) bookkeeper - parallel async read same entry of same ledger will fail

2013-02-11 Thread Rakesh R (JIRA)

[ 
https://issues.apache.org/jira/browse/BOOKKEEPER-49?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13575900#comment-13575900
 ] 

Rakesh R commented on BOOKKEEPER-49:


Oh ok. Once BOOKKEEPER-558 is in, will revisit again. Could you please link 
with BOOKKEEPER-558.

 bookkeeper - parallel async read same entry of same ledger will fail
 

 Key: BOOKKEEPER-49
 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-49
 Project: Bookkeeper
  Issue Type: Bug
  Components: bookkeeper-client
Affects Versions: 4.0.0, 4.1.0
Reporter: Sijie Guo
Assignee: Sijie Guo
 Fix For: 4.3.0

 Attachments: 
 0001-BOOKKEEPER-49-bookkeeper-parallel-async-read-same-en.patch


 all ledgers shared a PerChannelBookieClient. 
 PerChannelBookieClient put all the read requests in a 
 ConcurrentHashMapCompletionKey, ReadCompletion map called readCompletions, 
 which is indexed by CompletionKey. If two read requests have same entryId and 
 same ledgerId, they have the same CompletionKey, the latter one will 
 overwrite the previous one. So a read request's callback will not be invoked.
 we may need to chain the callbacks for same completion keys.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Created] (BOOKKEEPER-568) NPE during GC with HierarchicalLedgerManager

2013-02-11 Thread Matteo Merli (JIRA)
Matteo Merli created BOOKKEEPER-568:
---

 Summary: NPE during GC with HierarchicalLedgerManager
 Key: BOOKKEEPER-568
 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-568
 Project: Bookkeeper
  Issue Type: Bug
  Components: bookkeeper-server
Affects Versions: 4.2.0
Reporter: Matteo Merli
Priority: Minor


{noformat}
2013-02-11 14:06:28,904 - WARN  - 
[GarbageCollectorThread:ScanAndCompareGarbageCollector@103] - Exception when 
iterating over the metadata {}
java.io.IOException: Error when check more elements
at 
org.apache.bookkeeper.meta.HierarchicalLedgerManager$HierarchicalLedgerRangeIterator.hasNext(HierarchicalLedgerManager.java:423)
at 
org.apache.bookkeeper.bookie.ScanAndCompareGarbageCollector.gc(ScanAndCompareGarbageCollector.java:75)
at 
org.apache.bookkeeper.bookie.GarbageCollectorThread.doGcLedgers(GarbageCollectorThread.java:302)
at 
org.apache.bookkeeper.bookie.GarbageCollectorThread.run(GarbageCollectorThread.java:271)
Caused by: java.lang.NullPointerException
at 
org.apache.bookkeeper.meta.HierarchicalLedgerManager$HierarchicalLedgerRangeIterator.hasNext(HierarchicalLedgerManager.java:419)
... 3 more
{noformat}

In the code below, l2NodesIter appears to be null.

{code}
public boolean hasNext() throws IOException {
   try {
  if (l1NodesIter == null) {
  l1NodesIter = zk.getChildren(ledgerRootPath, null).iterator();
  hasMoreElement = nextL1Node();
  } else if (!l2NodesIter.hasNext()) {
  hasMoreElement = nextL1Node();
  }
   } catch (Exception e) {
  throw new IOException(Error when check more elements, e);
   }
   return hasMoreElement;
}
{code}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (BOOKKEEPER-568) NPE during GC with HierarchicalLedgerManager

2013-02-11 Thread Matteo Merli (JIRA)

[ 
https://issues.apache.org/jira/browse/BOOKKEEPER-568?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13576182#comment-13576182
 ] 

Matteo Merli commented on BOOKKEEPER-568:
-

I'm not sure if doing 
{code}
l2NodesIter == null || !l2NodesIter.hasNext()
{code}

 would be the correct check.

 NPE during GC with HierarchicalLedgerManager
 

 Key: BOOKKEEPER-568
 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-568
 Project: Bookkeeper
  Issue Type: Bug
  Components: bookkeeper-server
Affects Versions: 4.2.0
Reporter: Matteo Merli
Priority: Minor

 {noformat}
 2013-02-11 14:06:28,904 - WARN  - 
 [GarbageCollectorThread:ScanAndCompareGarbageCollector@103] - Exception when 
 iterating over the metadata {}
 java.io.IOException: Error when check more elements
   at 
 org.apache.bookkeeper.meta.HierarchicalLedgerManager$HierarchicalLedgerRangeIterator.hasNext(HierarchicalLedgerManager.java:423)
   at 
 org.apache.bookkeeper.bookie.ScanAndCompareGarbageCollector.gc(ScanAndCompareGarbageCollector.java:75)
   at 
 org.apache.bookkeeper.bookie.GarbageCollectorThread.doGcLedgers(GarbageCollectorThread.java:302)
   at 
 org.apache.bookkeeper.bookie.GarbageCollectorThread.run(GarbageCollectorThread.java:271)
 Caused by: java.lang.NullPointerException
   at 
 org.apache.bookkeeper.meta.HierarchicalLedgerManager$HierarchicalLedgerRangeIterator.hasNext(HierarchicalLedgerManager.java:419)
   ... 3 more
 {noformat}
 In the code below, l2NodesIter appears to be null.
 {code}
 public boolean hasNext() throws IOException {
try {
   if (l1NodesIter == null) {
   l1NodesIter = zk.getChildren(ledgerRootPath, null).iterator();
   hasMoreElement = nextL1Node();
   } else if (!l2NodesIter.hasNext()) {
   hasMoreElement = nextL1Node();
   }
} catch (Exception e) {
   throw new IOException(Error when check more elements, e);
}
return hasMoreElement;
 }
 {code}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (BOOKKEEPER-555) Make BookieServer use Netty rather than a custom IO server

2013-02-11 Thread Rakesh R (JIRA)

[ 
https://issues.apache.org/jira/browse/BOOKKEEPER-555?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13576362#comment-13576362
 ] 

Rakesh R commented on BOOKKEEPER-555:
-

Thanks [~ikelly], latest patch looks nice. Apart from the following point, the 
patch is ready to go in +1.

Just one clarification, latest patch BookieRequestHandler is not having 
@Sharable annotation. In my previous comment I mentioned to replace the 
@ChannelPipelineCoverage(which is deprecated) with @Sharable. Am I missing 
anything?

 Make BookieServer use Netty rather than a custom IO server
 --

 Key: BOOKKEEPER-555
 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-555
 Project: Bookkeeper
  Issue Type: Bug
Reporter: Ivan Kelly
Assignee: Ivan Kelly
 Fix For: 4.3.0

 Attachments: 0001-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0001-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, 
 0002-BOOKKEEPER-555-Netty-Server-for-Bookie.patch, BOOKKEEPER-555.patch


 Move from the custom NIO server to netty. This will make it easier to do 
 things like add more server side threads and support SSL.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (BOOKKEEPER-568) NPE during GC with HierarchicalLedgerManager

2013-02-11 Thread Sijie Guo (JIRA)

[ 
https://issues.apache.org/jira/browse/BOOKKEEPER-568?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13576374#comment-13576374
 ] 

Sijie Guo commented on BOOKKEEPER-568:
--

ah, it seems that this code doesn't handle calling hasNext twice. so second 
time call hasNext would fail with null pointer. the case would happened when 
there is no ledgers existed in bookkeeper.

[~merlimat] it is OK to fix as your suggestion. could you generate a patch for 
it? thanks.

 NPE during GC with HierarchicalLedgerManager
 

 Key: BOOKKEEPER-568
 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-568
 Project: Bookkeeper
  Issue Type: Bug
  Components: bookkeeper-server
Affects Versions: 4.2.0
Reporter: Matteo Merli
Priority: Minor

 {noformat}
 2013-02-11 14:06:28,904 - WARN  - 
 [GarbageCollectorThread:ScanAndCompareGarbageCollector@103] - Exception when 
 iterating over the metadata {}
 java.io.IOException: Error when check more elements
   at 
 org.apache.bookkeeper.meta.HierarchicalLedgerManager$HierarchicalLedgerRangeIterator.hasNext(HierarchicalLedgerManager.java:423)
   at 
 org.apache.bookkeeper.bookie.ScanAndCompareGarbageCollector.gc(ScanAndCompareGarbageCollector.java:75)
   at 
 org.apache.bookkeeper.bookie.GarbageCollectorThread.doGcLedgers(GarbageCollectorThread.java:302)
   at 
 org.apache.bookkeeper.bookie.GarbageCollectorThread.run(GarbageCollectorThread.java:271)
 Caused by: java.lang.NullPointerException
   at 
 org.apache.bookkeeper.meta.HierarchicalLedgerManager$HierarchicalLedgerRangeIterator.hasNext(HierarchicalLedgerManager.java:419)
   ... 3 more
 {noformat}
 In the code below, l2NodesIter appears to be null.
 {code}
 public boolean hasNext() throws IOException {
try {
   if (l1NodesIter == null) {
   l1NodesIter = zk.getChildren(ledgerRootPath, null).iterator();
   hasMoreElement = nextL1Node();
   } else if (!l2NodesIter.hasNext()) {
   hasMoreElement = nextL1Node();
   }
} catch (Exception e) {
   throw new IOException(Error when check more elements, e);
}
return hasMoreElement;
 }
 {code}

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (BOOKKEEPER-554) fd leaking when move ledger index file

2013-02-11 Thread Sijie Guo (JIRA)

[ 
https://issues.apache.org/jira/browse/BOOKKEEPER-554?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13576376#comment-13576376
 ] 

Sijie Guo commented on BOOKKEEPER-554:
--

+1 for the new patch. thanks Ivan. will commit it.

 fd leaking when move ledger index file
 --

 Key: BOOKKEEPER-554
 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-554
 Project: Bookkeeper
  Issue Type: Bug
  Components: bookkeeper-server
Affects Versions: 4.2.0
Reporter: Sijie Guo
Assignee: Sijie Guo
 Fix For: 4.3.0

 Attachments: 0001-BOOKKEEPER-554.patch, BOOKKEEPER-554.diff


 a file info is get when moving ledger index, but it doesn't release after 
 use. so the reference counting for file info stays more than zero, the file 
 channel would never be closed even the file is evicted from ledger cache.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (BOOKKEEPER-554) fd leaking when move ledger index file

2013-02-11 Thread Hudson (JIRA)

[ 
https://issues.apache.org/jira/browse/BOOKKEEPER-554?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13576397#comment-13576397
 ] 

Hudson commented on BOOKKEEPER-554:
---

Integrated in bookkeeper-trunk #98 (See 
[https://builds.apache.org/job/bookkeeper-trunk/98/])
BOOKKEEPER-554: fd leaking when move ledger index file (sijie, ivank via 
sijie) (Revision 1445033)

 Result = SUCCESS
sijie : 
Files : 
* /zookeeper/bookkeeper/trunk/CHANGES.txt
* 
/zookeeper/bookkeeper/trunk/bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/FileInfo.java
* 
/zookeeper/bookkeeper/trunk/bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/LedgerCacheImpl.java
* 
/zookeeper/bookkeeper/trunk/bookkeeper-server/src/test/java/org/apache/bookkeeper/bookie/LedgerCacheTest.java


 fd leaking when move ledger index file
 --

 Key: BOOKKEEPER-554
 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-554
 Project: Bookkeeper
  Issue Type: Bug
  Components: bookkeeper-server
Affects Versions: 4.2.0
Reporter: Sijie Guo
Assignee: Sijie Guo
 Fix For: 4.3.0

 Attachments: 0001-BOOKKEEPER-554.patch, BOOKKEEPER-554.diff


 a file info is get when moving ledger index, but it doesn't release after 
 use. so the reference counting for file info stays more than zero, the file 
 channel would never be closed even the file is evicted from ledger cache.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira