You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@bookkeeper.apache.org by "AnonHxy (via GitHub)" <gi...@apache.org> on 2023/11/03 10:02:30 UTC

[PR] Cleanup layoutManager null-check when AbstractZkLedgerManagerFactory#newLedgerManagerFactory [bookkeeper]

AnonHxy opened a new pull request, #4124:
URL: https://github.com/apache/bookkeeper/pull/4124

   Descriptions of the changes in this PR:
   
   
   
   ### Motivation
   
   Remove the null-check from `AbstractZkLedgerManagerFactory#newLedgerManagerFactory`. The reason is that:
   1. the parameter `layoutManager` in `newLedgerManagerFactory()` method can never be null. So this check is unnecessory
   2. If the `layoutManager` is null and we return  `new FlatLedgerManagerFactory().initialize(conf, null, FlatLedgerManagerFactory.CUR_VERSION)`,  the 'zk' in `FlatLedgerManagerFactory` is null and could throw NPE when invoke the methods in the `FlatLedgerManagerFactory`.
   
   
   ### Changes
   
   1. Cleanup layoutManager null-check when `newLedgerManagerFactory()`
   2. Let `layoutManager` could never be null in `FlatLedgerManagerFactory`
   
   


-- 
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: commits-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Cleanup layoutManager null-check when AbstractZkLedgerManagerFactory#newLedgerManagerFactory [bookkeeper]

Posted by "AnonHxy (via GitHub)" <gi...@apache.org>.
AnonHxy commented on PR #4124:
URL: https://github.com/apache/bookkeeper/pull/4124#issuecomment-1806674429

   rerun failure checks


-- 
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: commits-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Cleanup layoutManager null-check when AbstractZkLedgerManagerFactory#newLedgerManagerFactory [bookkeeper]

Posted by "AnonHxy (via GitHub)" <gi...@apache.org>.
AnonHxy commented on PR #4124:
URL: https://github.com/apache/bookkeeper/pull/4124#issuecomment-1793449304

   rerun failure checks


-- 
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: commits-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Cleanup layoutManager null-check when AbstractZkLedgerManagerFactory#newLedgerManagerFactory [bookkeeper]

Posted by "AnonHxy (via GitHub)" <gi...@apache.org>.
AnonHxy commented on PR #4124:
URL: https://github.com/apache/bookkeeper/pull/4124#issuecomment-1793409848

   rerun failure checks


-- 
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: commits-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Cleanup layoutManager null-check when AbstractZkLedgerManagerFactory#newLedgerManagerFactory [bookkeeper]

Posted by "AnonHxy (via GitHub)" <gi...@apache.org>.
AnonHxy closed pull request #4124: Cleanup layoutManager null-check when AbstractZkLedgerManagerFactory#newLedgerManagerFactory
URL: https://github.com/apache/bookkeeper/pull/4124


-- 
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: commits-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Cleanup layoutManager null-check when AbstractZkLedgerManagerFactory#newLedgerManagerFactory [bookkeeper]

Posted by "AnonHxy (via GitHub)" <gi...@apache.org>.
AnonHxy commented on PR #4124:
URL: https://github.com/apache/bookkeeper/pull/4124#issuecomment-1808368909

   rerun failure checks


-- 
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: commits-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org