rdblue commented on code in PR #9620:
URL: https://github.com/apache/iceberg/pull/9620#discussion_r1483619256
##########
core/src/main/java/org/apache/iceberg/view/ViewMetadata.java:
##########
@@ -450,6 +452,15 @@ public ViewMetadata build() {
ViewProperties.VERSION_HISTORY_SIZE,
historySize);
+ if (!PropertyUtil.propertyAsBoolean(
+ properties,
+ ViewProperties.REPLACE_DROP_DIALECT_ALLOWED,
+ ViewProperties.REPLACE_DROP_DIALECT_ALLOWED_DEFAULT)) {
+ for (int i = Math.max(1, startingViewVersionsSize); i <
versions.size(); i++) {
+ checkIfDialectIsDropped(versions.get(i - 1), versions.get(i));
Review Comment:
This check is overbroad. This check should not cause a view to be completely
broken just because a different client put the view into a bad state. Instead,
this check should only run to validate the changes made by the caller.
This also makes a bad assumption about view versions. Consecutive view
version numbers have no meaning. The current view version may not be the
highest number, since the current version ID is tracked separately.
This PR needs to validate that when the current view version changes, there
are no dropped dialects.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]