zhangshenghang opened a new pull request, #13436: URL: https://github.com/apache/seatunnel/pull/13436
Yes, I'm contributing to [Apache SeaTunnel](https://github.com/apache/seatunnel). ## What documentation issues were found While verifying connector/transform documentation against the source code on `dev`, the following real inaccuracies were found: 1. **Doris source** (`docs/{en,zh}/connectors/source/Doris.md`): - Type mapping table claimed `LARGEINT → STRING`, but `AbstractDorisTypeConverter` (lines 188–193) maps `DORIS_LARGEINT` to `DECIMAL(20,0)` (locked by `DorisTypeConvertorV2Test`). - `DECIMAL` mapping used an outdated JDBC-javadoc formula ("column size + 1"); the converters use the column precision/scale directly, falling back to `DECIMAL(38, 10)` when the column does not define them. 2. **Doris sink** (`docs/{en,zh}/connectors/sink/Doris.md`): - The `doris.config` description listed `row_delimiter` as a common key. No such key exists in the connector (`LoadConstants.LINE_DELIMITER_KEY = "line_delimiter"`) or in Doris Stream Load; the documented key would silently not take effect. - zh FAQ "Are Doris column names case-sensitive?" was much thinner than the en version and referenced a nonexistent `column_mapping` option; aligned with the en answer (default `case_sensitive = true` behavior, `Rename` transform suggestion). 3. **MongoDB source** (`docs/{en,zh}/connectors/source/MongoDB.md`): - Key features marked `[x] exactly-once`, contradicting the connector: `MongoSplit` carries no read offset and `MongodbSplitEnumerator.snapshotState` only persists pending splits, so restore re-reads documents (at-least-once). The doc's own Description section already documented this. Unchecked to `[ ]`. - The `flat.sync-string` sample output showed Canonical Extended JSON (`$numberInt`/`$numberLong`/...), but `BsonToRowDataConverters.convertToString` serializes documents with `JsonMode.RELAXED`; rewrote the sample to the actual output (plain numbers, ISO-8601 date strings). 4. **Iceberg sink** (`docs/{en,zh}/connectors/sink/Iceberg.md`): - en `case_sensitive` description referenced a nonexistent `schema [config]` option (copy-pasted from the source doc); the sink has no such option (`IcebergSinkFactory.optionRule()`). Reworded to match the zh description (column name matching). - `schema_save_mode`/`data_save_mode` cells said "please refer to ... below", but those sections were removed from the doc in #10262 — dangling references. Added `schema_save_mode [Enum]` and `data_save_mode [Enum]` sections listing the allowed values from `SchemaSaveMode`/`DataSaveMode` (en + zh). 5. **Kafka sink** (`docs/en/connectors/sink/Kafka.md`): - `format` row claimed the default field separator is `", "`; `KafkaBaseOptions.DEFAULT_FIELD_DELIMITER = ","` (and the zh doc already said `,`). Fixed. 6. **Socket source** (`docs/{en,zh}/connectors/source/Socket.md`): - Description claimed "there is no read-timeout setting" while the same doc documents `read_timeout_ms` (default 0) 20 lines below (introduced by #12974, which updated the option table but not the paragraph). Reworded. 7. **RegexExtract transform** (`docs/{en,zh}/transforms/regexextract.md`): - Docs documented `table_match_regex` (option row, section, two example usages), but `RegexExtractTransformFactory.optionRule()` does not declare it. Since transform configs reject unknown keys (`ConfigValidator.validateUnknownKeys`), any job following the docs fails with "unknown option keys: [table_match_regex]". Removed the option from docs/examples so they match current behavior. Note for maintainers: every sibling multi-table transform factory declares `TABLE_MATCH_REGEX`, and the base class still reads it, so adding `.optional(TransformCommonOptions.TABLE_MATCH_REGEX)` to the factory looks like the right follow-up code fix — happy to file/prepare that separately. 8. **Filter / Split / FieldRename / RegexExtract transforms** (en + zh option tables): - `table_transform` default shown as `-`; `TransformCommonOptions.MULTI_TABLES` defaults to an empty list (`[]`), which sibling docs (field-mapper, filter-rowkind) already show. Aligned. ## What was changed 19 documentation files (10 en + 9 zh; zh Doris FAQ + zh Socket are single-language counterpart fixes): corrected type mappings, defaults, feature checkboxes, sample outputs, and removed/replaced statements that contradict the code; added the missing Iceberg save-mode enum sections in both languages. ## Areas/files updated - `docs/{en,zh}/connectors/source/Doris.md`, `docs/{en,zh}/connectors/sink/Doris.md` - `docs/{en,zh}/connectors/source/MongoDB.md` - `docs/{en,zh}/connectors/sink/Iceberg.md` - `docs/en/connectors/sink/Kafka.md` - `docs/{en,zh}/connectors/source/Socket.md` - `docs/{en,zh}/transforms/regexextract.md`, `docs/{en,zh}/transforms/filter.md`, `docs/{en,zh}/transforms/split.md`, `docs/{en,zh}/transforms/field-rename.md` ## English and Chinese docs both checked Yes. Every fix was applied to both language versions when the issue existed in both (all of the above except the en-only Kafka default separator, where zh was already correct — the en fix brings them in sync; and the zh-only Doris FAQ alignment, where en was already correct). ## Duplicate PR check (last 7 days) Searched open PRs by and mentioning docs for the last 7 days before implementing and again immediately before opening this PR (`gh pr list --search "created:>=2026-11-17"`). The recent docs PRs — #13410, #13401, #13390, #13380 (all "[Docs] Fix connector ... inaccuracies"), #13327 (CDC metadata/HTTP/Kafka source/transforms copy-encrypt-jsonpath-metadata-python-sql) and #13302 (JDBC type mappings/Kingbase/getting-started) — cover different connector files; none of them touches Doris, MongoDB source, Iceberg sink, Kafka sink, Socket source, or regexextract/filter/split/field-rename. This PR's file set was chosen to avoid all of them; no overlap. ## Verification - Re-ran a repo-wide relative-link check over `docs/` before and after the change: same 11 pre-existing results (all false positives inside code blocks plus one pre-existing `@site/` reference in `docs/zh/engines/zeta/rest-api-v2.md`, which is being modified by open PR #13380 so it was deliberately left untouched here). No new broken links introduced. - Checked code-fence balance and markdown table structure in all 19 modified files. - Every factual change was verified against the connector/transform source on `dev` (option definitions, defaults, converter logic, serializer output mode, enum values), with unit-test cross-checks where available (`DorisTypeConvertorV2Test`). - Full `./mvnw verify` was not run because this PR contains no code changes — the CI docs path check does not require a Maven build for `docs/**`-only changes. -- 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]
