dimas-b commented on code in PR #2714:
URL: https://github.com/apache/polaris/pull/2714#discussion_r2399635903


##########
runtime/service/src/main/java/org/apache/polaris/service/config/ProductionReadinessChecks.java:
##########
@@ -302,4 +302,36 @@ public ProductionReadinessCheck 
checkInsecureStorageSettings(
         ? ProductionReadinessCheck.OK
         : ProductionReadinessCheck.of(errors.toArray(new Error[0]));
   }
+
+  @Produces
+  public ProductionReadinessCheck checkOverlappingSiblingCheckSettings(
+      FeaturesConfiguration featureConfiguration) {
+    var optimizedSiblingCheck = FeatureConfiguration.OPTIMIZED_SIBLING_CHECK;
+    var errors = new ArrayList<Error>();
+    if 
(Boolean.parseBoolean(featureConfiguration.defaults().get(optimizedSiblingCheck.key())))
 {
+      errors.add(
+          Error.ofSevere(
+              "This setting is not recommended for production environments as 
it may lead to incorrect behavior, due to missing data for 
location_without_scheme column in case of migrating from older Polaris 
versions."

Review Comment:
   I'd prefer to avoid using the term "production". Correctness issues apply to 
all environments.
   
   How about `This setting should be used with care and only enabled in new 
realms. Enabling it in previously used realms and may lead to incorrect 
behavior, due to missing data for location_without_scheme column. Set the 
ALLOW_OPTIMIZED_SIBLING_CHECK flag to acknowledge this warning and enable 
Polaris to start.`.
   
   Then, I think we could add another feature flag 
`ALLOW_OPTIMIZED_SIBLING_CHECK` as a user-level safety. If 
`ALLOW_OPTIMIZED_SIBLING_CHECK` is `true` we do not flag  this as an error.
   
   WDYT?



-- 
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]

Reply via email to