amalsaidov opened a new pull request, #13227: URL: https://github.com/apache/seatunnel/pull/13227
### Purpose of this pull request Part of #11007 (migrate connector validation to declarative `OptionRule`). The Opengauss CDC source declares `url` as required but never validated its content. A blank or whitespace-only `url` passed `--check` and only failed later with an opaque JDBC connection error. The DB2 CDC (#12931) and PostgreSQL CDC siblings already moved this check into the declarative rule, so this brings Opengauss in line. Change in `OpengaussIncrementalSourceFactory#optionRule()`: split the required group so `url` carries `notBlank(url)`, while `username` and `password` stay as plain required options. Because `url` resolves through its `base-url` fallback key, the validation also covers `base-url`, and a blank canonical `url` no longer silently falls back to a valid `base-url`. ### Does this PR introduce _any_ user-facing change? Yes. A blank or whitespace-only `url` (or `base-url`) is now rejected at `--check` time with a clear validation error instead of failing at connection time. Valid configurations are unaffected, and a supplied url is not trimmed or otherwise rewritten. The English and Chinese `Opengauss-CDC` option docs note that the value must not be empty or whitespace-only. ### How was this patch tested? Added unit tests to `OpengaussIncrementalSourceFactoryTest` covering accepted urls (including surrounding whitespace, which is preserved), blank and missing urls, the `base-url` fallback, and canonical-over-fallback precedence. ``` ./mvnw -pl seatunnel-connectors-v2/connector-cdc/connector-cdc-opengauss test -Dtest=OpengaussIncrementalSourceFactoryTest Tests run: 24, Failures: 0, Errors: 0, Skipped: 0 BUILD SUCCESS ``` No external openGauss instance is required; the validation runs entirely through `OptionRule`. ### Check list * [x] If necessary, please update the documentation to describe the new feature. * [ ] If any new Jar binary package adding in your PR, please add License Notice. 🤖 Generated with [Claude Code](https://claude.com/claude-code) -- 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]
