youzipi commented on code in PR #17172:
URL: https://github.com/apache/pulsar/pull/17172#discussion_r952113910
##########
pulsar-broker/src/main/java/org/apache/pulsar/PulsarBrokerStarter.java:
##########
@@ -240,8 +240,8 @@ && isBlank(starterArguments.bookieConfigFile)) {
// init bookie server
if (starterArguments.runBookie) {
- checkNotNull(bookieConfig, "No ServerConfiguration for
Bookie");
- checkNotNull(bookieStatsProvider, "No Stats Provider for
Bookie");
+ Objects.requireNonNull(bookieConfig, "No ServerConfiguration
for Bookie");
Review Comment:
guava `chekNotNull` and jdk `Objects.requireNonNull` provide the same simple
semantic:
```java
if (obj == null)
throw new NullPointerException(message);
return obj;
```
@hangc0276
--
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]