Shawyeok commented on issue #14779: URL: https://github.com/apache/pulsar/issues/14779#issuecomment-1537981706
After analyze the broker log, I'm suspect that get cursors of the managed-ledger in new owner broker returns empty result (`consumers.isEmpty()` is true), hence no cursor was load. https://github.com/apache/pulsar/blob/09a6b588fe7df63c6cd8acb6699cab46f8f57bec/managed-ledger/src/main/java/org/apache/bookkeeper/mledger/impl/ManagedLedgerImpl.java#L498-L520 But cursor znode ctime indicates cursor is already created, but getChildren returns empty? This is the part that confuses me. ``` [zk: localhost:2181(CONNECTED) 0] stat /managed-ledgers/platform/dp/persistent/resume.complete.result-ai.bert.cv.change.nlp.sub-DLQ/ai.bert.cv.change.nlp.sub cZxid = 0x1510c7a7d2 ctime = Sat May 06 13:54:54 CST 2023 mZxid = 0x1510de2965 mtime = Sun May 07 14:18:15 CST 2023 pZxid = 0x1510c7a7d2 cversion = 0 dataVersion = 1 aclVersion = 0 ephemeralOwner = 0x0 dataLength = 34 numChildren = 0 [zk: localhost:2181(CONNECTED) 1] stat /managed-ledgers/platform/dp/persistent/resume.complete.result-ai.bert.cv.change.nlp.sub-DLQ cZxid = 0x1510c7a7ca ctime = Sat May 06 13:54:54 CST 2023 mZxid = 0x1510f5986f mtime = Mon May 08 11:31:12 CST 2023 pZxid = 0x1510c7a7d2 cversion = 1 dataVersion = 3 aclVersion = 0 ephemeralOwner = 0x0 dataLength = 9 numChildren = 1 [zk: localhost:2181(CONNECTED) 2] 2023-05-08 16:37:23,195 [myid:] - ERROR [main:ServiceUtils@42] - Exiting JVM with code 0 ``` btw, the version of zookeeper server is `3.6.2`. I added a log here to try verify my hypothesis above. ``` if (consumers.isEmpty()) { log.info("[{}] No cursors to recover", name); callback.initializeComplete(); return; } ``` More updates is coming... -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
