menghaoranss commented on PR #39593: URL: https://github.com/apache/shardingsphere/pull/39593#issuecomment-5396176114
```markdown ### Result **Review Result: Mergeable** The patch correctly delegates preview fallback-schema resolution to `ShardingSphereDatabase`, while preserving explicit-schema precedence and forwarding the canonical schema to SQL federation. ### Evidence - [`PreviewExecutor`](https://github.com/apache/shardingsphere/blob/ca0aca025ee4de31693c31b859b6f5ceeac71ab6/proxy/backend/core/src/main/java/org/apache/shardingsphere/proxy/backend/handler/distsql/rul/PreviewExecutor.java#L86-L118) resolves the schema before constructing `SQLFederationEngine`; cursor, federation, and kernel-routing flows remain unchanged. - [`ShardingSphereDatabase#getDefaultSchemaName`](https://github.com/apache/shardingsphere/blob/ca0aca025ee4de31693c31b859b6f5ceeac71ab6/infra/common/src/main/java/org/apache/shardingsphere/infra/metadata/database/ShardingSphereDatabase.java#L303-L315) owns protocol normalization and canonical metadata casing. - The updated test verifies that the database fallback reaches the federation-engine constructor when no explicit schema exists. - Exact-head verification passed: 6 tests, 0 failures, 0 errors; Maven exit code 0. ### Coverage - Reviewed head: `ca0aca025ee4de31693c31b859b6f5ceeac71ab6` - Current base: `7c27b6e5240371ea1d1878c506f4fb76be691c7b` - Merge-base: `a6bd45f1aa07e9d714d8c9b9c7a173e082a5ca47` - Both authoritative GitHub files matched the local triple-dot scope and were reviewed. - Reviewed the preview default-schema cluster, including binding, explicit-schema precedence, metadata ownership, cursor handling, federation construction, kernel routing, and tests. - Completed root-cause, blast-radius/contracts, tests/runtime, and convergence passes with no findings or unresolved gaps. - This is a code-scope result only; CI was not reviewed. ``` -- 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]
