Abyss-lord commented on code in PR #9221:
URL: https://github.com/apache/gravitino/pull/9221#discussion_r2558417222
##########
flink-connector/flink/src/test/java/org/apache/gravitino/flink/connector/integration/test/paimon/FlinkPaimonCatalogIT.java:
##########
@@ -74,7 +74,7 @@ void paimonSetup() {
@AfterAll
void paimonStop() {
- Preconditions.checkNotNull(metalake);
+ Preconditions.checkArgument(metalake != null);
Review Comment:
fix
##########
flink-connector/flink/src/main/java/org/apache/gravitino/flink/connector/store/GravitinoCatalogStoreFactory.java:
##########
@@ -56,12 +56,15 @@ public void open(Context context) throws CatalogException {
factoryHelper.validate();
ReadableConfig options = factoryHelper.getOptions();
- String gravitinoUri =
- Preconditions.checkNotNull(
- options.get(GRAVITINO_URI), "The %s must be set.",
GRAVITINO_URI.key());
- String gravitinoName =
- Preconditions.checkNotNull(
- options.get(GRAVITINO_METALAKE), "The %s must be set.",
GRAVITINO_METALAKE.key());
+
+ String gravitinoUri = options.get(GRAVITINO_URI);
+ String gravitinoName = options.get(GRAVITINO_METALAKE);
+ Preconditions.checkArgument(
+ gravitinoUri != null && gravitinoName != null,
+ "Both %s and %s must be set",
+ GRAVITINO_METALAKE.key(),
+ GRAVITINO_URI.key());
Review Comment:
fix
--
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]