yuqi1129 opened a new pull request, #14051: URL: https://github.com/apache/gravitino/pull/14051
### What changes were proposed in this pull request? Throw `NonEmptySchemaException` when a non-cascading schema drop finds tables in JDBC common, Doris, StarRocks and ClickHouse. MySQL and OceanBase inherit the shared JDBC fix. Keep the existing SQL and cascade behavior. ### Why are the changes needed? The schema drop contract and REST error handler expect `NonEmptySchemaException`. Throwing generic state/argument exceptions currently produces HTTP 500 or 400 for a normal non-empty-schema rejection. Fix: #14050 ### Does this PR introduce _any_ user-facing change? Affected catalog clients receive `NonEmptySchemaException` and REST clients receive HTTP 409 when dropping a non-empty schema without cascade, instead of generic errors. No API signatures or configuration changes. ### How was this patch tested? - Four pre-fix non-empty-drop regression cases failed with the incorrect exception types. - After the fix: all 438 non-Docker tests in JDBC common, Doris, StarRocks and ClickHouse passed, plus all 11 `TestSchemaOperations` REST tests (449 total). - New coverage checks rejection before DROP, successful empty-schema drops, cascade behavior, JDBC resource closure, and the HTTP 409 response/error type. - Module Spotless checks and `git diff --check` passed. - Live database/Docker integration tests were not run locally. -- 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]
