Skip to content

[core] Validate schema after applying schema changes#8063

Open
leaves12138 wants to merge 1 commit into
apache:masterfrom
leaves12138:fix-reset-sequence-group-validation
Open

[core] Validate schema after applying schema changes#8063
leaves12138 wants to merge 1 commit into
apache:masterfrom
leaves12138:fix-reset-sequence-group-validation

Conversation

@leaves12138
Copy link
Copy Markdown
Contributor

Purpose

SchemaManager.generateTableSchema can produce an invalid option combination after applying schema changes. For example, resetting fields.<seq>.sequence-group may leave a field-specific aggregate-function that requires that sequence group, and the failure is only exposed later when the table is loaded.

Changes

  • Validate the generated TableSchema before returning it from SchemaManager.generateTableSchema.
  • Add regression coverage for resetting a sequence group used by fields.<field>.aggregate-function.
  • Keep last_non_null_value behavior unchanged, since it does not require a sequence group.

Tests

mvn -U -pl paimon-core -am -DskipITs -Dcheckstyle.skip -Drat.skip=true -Dspotless.check.skip=true -DfailIfNoTests=false -Dtest=SchemaManagerTest#testResetSequenceGroupForAggregateFunction+testResetSequenceGroupForLastNonNullAggregateFunction test

@leaves12138 leaves12138 force-pushed the fix-reset-sequence-group-validation branch from 7b82a97 to 041a61f Compare June 1, 2026 10:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant