Skip to content

[Docs] Fix IoTDB, Http, Paimon, SelectDB, Neo4j and Phoenix doc inaccuracies - #12758

Merged
nzw921rx merged 1 commit into
apache:devfrom
zhangshenghang:docs-fix-batch-20261013
Oct 19, 2026
Merged

nzw921rx merged 1 commit into
apache:devfrom
zhangshenghang:docs-fix-batch-20261013

Conversation

@zhangshenghang

Copy link
Copy Markdown
Member

Purpose of this PR

This PR fixes a batch of real documentation writing issues found by comparing the docs against the actual connector/transform source code on the current dev branch. Every fix below was verified against the code before editing.

Issues found and changes

IoTDB / IoTDBv2 (docs/{en,zh}/connectors/source/IoTDB.md, IoTDBv2.md)

  • Both docs described the num_partitions fallback with an inverted condition. The code (IoTDBSourceSplitEnumerator.java:172, IoTDBv2SourceSplitEnumerator.java:154) reduces the partition count to upper_bound - lower_bound when the time range is smaller than num_partitions, not the other way around. Fixed the zh option tables and the split-rule example blocks in both languages.
  • The partition interval was written as [lower_bound, upper_bound) while the generated predicate is time >= lower_bound and time < upper_bound + 1, i.e. both bounds are inclusive. Fixed to [lower_bound, upper_bound] (en+zh), consistent with the examples in the same section.
  • IoTDBv2 docs marked stream as supported, but IoTDBv2Source.getBoundedness() returns Boundedness.BOUNDED. Changed the feature checkbox to unchecked (en+zh).
  • Also corrected the same inverted condition in the javadoc of both split enumerators, which is where the doc text originally came from (comment-only change, no behavior change).

Http source (docs/{en,zh}/connectors/source/Http.md)

  • pageing.start_page_number is declared longType() in HttpSourceOptions.java but documented as Int. Fixed to Long.
  • schema is conditionally required (HttpSourceFactory.optionRule() has .conditional(FORMAT, JSON, SCHEMA)), but the option table said No. Marked as conditional in both languages.

Paimon sink (docs/{en,zh}/connectors/sink/Paimon.md)

  • The FAQ told users to set paimon.auto-create-table = true, an option that has never existed in the connector (verified by grep and git log -S). Following it is a silent no-op. Removed it; table auto-creation is driven by schema_save_mode.
  • zh doc referenced the S3 property fs.s3a.aws.credentials, missing the .provider suffix (the en doc and both docs' own examples use the correct fs.s3a.aws.credentials.provider). Fixed.
  • The zh "Changelog Producer" section had a wrong heading (更新日志, colliding with the real release-notes section) and wrongly claimed changelog-producer=input is mandatory. Rewritten to mirror the en doc: all four modes are supported, default is none.

SelectDB Cloud sink (docs/{en,zh}/connectors/sink/SelectDB-Cloud.md)

  • Added the missing option rows sink.label-prefix (default: random UUID per job) and sink.flush.queue-size (default: 1), both defined in SelectDBSinkOptions.java and consumed by the sink.

JsonPath transform (docs/{en,zh}/transforms/jsonpath.md)

  • The example result table showed c1_map_array = [{"key1": "value1", "key2": "value2"}], but the example input contains c_string_1/2/3 keys and two map entries. Fixed the output to match what the transform actually produces from the given input.

Neo4j source (docs/{en,zh}/connectors/source/Neo4j.md)

  • The note said "use exactly one authentication method", but Neo4jAuthenticationConditions only requires at least one, and DriverBuilder applies a precedence (username/password > bearer token > Kerberos) when several are set. Aligned the note with the sink doc, which documents the actual behavior.

Phoenix (docs/{en,zh}/connectors/source/Phoenix.md)

  • query was marked unconditionally required, but the shared JDBC source factory only requires url and driver; query is an alternative to table_path/table_list. Marked as conditional (consistent with Jdbc.md, which documents query as optional).

Areas updated

16 documentation files under docs/en and docs/zh (connectors: IoTDB, IoTDBv2, Http, Paimon, SelectDB-Cloud, Neo4j, Phoenix; transforms: jsonpath) plus 2 comment-only javadoc fixes in the IoTDB/IoTDBv2 split enumerators. 18 files changed, 29 insertions, 25 deletions.

English and Chinese docs

Yes — every fix was applied to both the English and Chinese versions of the same page so the two languages stay in sync. Several of the issues (num_partitions condition, Paimon FAQ, Paimon Changelog Producer section, Http rows) existed in both languages.

Duplicate check

Before submitting I listed all PRs created in the last 7 days: #12730, #12709, #12693, #12679 (my previous docs batches), #12675 (MQTT), #12663. I reviewed the file lists of each via gh pr diff --name-only. This PR only touches pages and issues not covered by any of them (IoTDB/IoTDBv2, Http, Paimon sink, SelectDB-Cloud, Neo4j source, Phoenix, jsonpath); none of the fixed issues overlap with those PRs.

Verification

  • git diff reviewed line by line against the corresponding code (option definitions, OptionRules, split-enumerator logic).
  • ./mvnw -q spotless:apply -pl seatunnel-connectors-v2/connector-iotdb,seatunnel-connectors-v2/connector-iotdb-v2 — passes with no further changes (covers the two javadoc edits).
  • Markdown table integrity check (consistent column counts) on all modified tables — passes.
  • Relative-link resolution check on all 16 modified markdown files — all links resolve.
  • Full ./mvnw verify was not run because this change is documentation-only; it does not affect compiled code paths beyond comments.

…uracies

- IoTDB/IoTDBv2: fix inverted num_partitions fallback condition, correct the
  partition interval notation, and stop claiming stream support for IoTDBv2
  (the source is bounded-only); align the stale javadoc in both split
  enumerators that documented the same inverted condition
- Http: correct pageing.start_page_number type (Int -> Long) and mark schema
  as conditionally required when format = json
- Paimon sink: remove reference to nonexistent paimon.auto-create-table option,
  fix zh S3 credentials property name (fs.s3a.aws.credentials.provider), and
  fix the zh Changelog Producer section (wrong heading, and wrong claim that
  changelog-producer=input is mandatory)
- SelectDB Cloud sink: document sink.label-prefix and sink.flush.queue-size
- JsonPath transform: fix example output to match the example input
- Neo4j source: correct authentication note to match actual precedence behavior
- Phoenix: mark query as conditionally required per the JDBC source contract

@DanielLeens DanielLeens left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @zhangshenghang for another careful docs-accuracy pass! I went through the full diff of head afcc385a2d87 and checked each claim against the connector sources instead of trusting the PR description. Short version: every fix I traced is correct, and I only have three small, non-blocking wording suggestions.

What Problem Does This PR Solve?

  • User pain point: Several connector and transform pages describe behavior that differs from the code (inverted num_partitions condition, an option that does not exist, wrong types/required flags, a wrong example output), so users following them get silent no-ops or wrong expectations.
  • Fix approach: Correct 16 doc pages (en + zh) and two comment-only Javadoc lines against the actual option definitions and logic.
  • One-sentence summary: A docs batch that brings IoTDB, IoTDBv2, Http, Paimon, SelectDB Cloud, Neo4j, Phoenix and JsonPath pages in line with the code.

1. Code Change Review

1.1 Core Logic Analysis

What I verified against the head (static review; I did not run anything):

  • IoTDB / IoTDBv2: end - start < numPartitions -> numPartitions = end - start is at IoTDBSourceSplitEnumerator.java:172 and the same check in the v2 enumerator, so the corrected direction is right. The predicate is time >= start and time < start + size, with the last slice ending at upper_bound + 1, so [lower_bound, upper_bound] inclusive is right. IoTDBv2Source.getBoundedness() returns BOUNDED, so unchecking stream is right (the v1 page was already unchecked).
  • Http: HttpSourceOptions.START_PAGE_NUMBER is Option<Long> and HttpSource reads it with getLong; HttpSourceFactory has .conditional(FORMAT, JSON, SCHEMA).
  • Paimon: there is no auto-create-table anywhere under connector-paimon (the two remaining hits in docs/en/architecture/** are JDBC schema-evolution examples, unrelated). The zh Changelog section now matches the en page.
  • SelectDB Cloud: sink.label-prefix and sink.flush.queue-size exist in SelectDBSinkOptions (defaults: random UUID, 1) and are registered in SelectDBSinkFactory.
  • Neo4j: Neo4jAuthenticationConditions.AUTHENTICATION_METHOD requires at least one method, and DriverBuilder.build() applies username, then bearer token, then Kerberos.
  • JsonPath: the new result cell is exactly what $.data.c_map_array yields from the example input in the same page.
  • Javadoc edits are comment-only; en and zh pages are consistent with each other.

1.2 Compatibility Impact

Fully compatible (documentation plus two comments). No option, default, API or serialization change.

1.3 Performance / Side-Effect Analysis

None.

1.4 Error Handling and Logging

No change.

Issue 1 (Low, non-blocking): the IoTDB fallback sentence describes only the root-level partition path

  • Location: docs/en/connectors/source/IoTDB.md:279-280 and docs/zh/connectors/source/IoTDB.md (the matching fallback sentence in the Chinese page)
  • Description: The per-table (tables_configs) branch uses Math.min(num_partitions, upper_bound - lower_bound + 1) (IoTDBSourceSplitEnumerator.java:176-177) instead of the end - start fallback, and the same page already documents that mode at line 85. A short qualifier such as "for root-level partition options" keeps the two statements from contradicting each other.
  • Raised by another reviewer: No

Issue 2 (Low, non-blocking): "random UUID generated for each job" is slightly stronger than the code

  • Location: docs/en/connectors/sink/SelectDB-Cloud.md:49 and the zh twin
  • Description: SelectDBSinkOptions.java:94-98 uses defaultValue(UUID.randomUUID().toString()), which is evaluated once when the options class is loaded, so it is per JVM / class loader rather than strictly per job. Something like "a random UUID generated when the connector is loaded" would be accurate.
  • Raised by another reviewer: No

Issue 3 (Low, non-blocking): the Phoenix query row points to options the page does not document

  • Location: docs/en/connectors/source/Phoenix.md:46 and the zh twin
  • Description: JdbcSourceFactory.optionRule() indeed requires only url and driver, so "Conditional" is right. But the page never documents table_path / table_list, and Phoenix has no dedicated catalog class, so I could confirm the option rule but not a Phoenix run that reads via table_path. Linking to Jdbc.md for those options (or just saying "required unless a table path or table list is configured, see the Jdbc source options") avoids over-promising.
  • Raised by another reviewer: No

2. Code Quality Assessment

2.1 Coding Standards

Table columns and en/zh pairs are consistent. The Conditional cell widths are slightly off in the raw Markdown, which renders fine.

2.2 Test Coverage and Test Stability

Docs and comments only; no test changes, so no stability rating is needed.

2.3 Documentation Updates

Both docs/en and docs/zh are updated for every fix, and the two languages agree.

3. Architectural Soundness

Precise fix. No historical-version compatibility impact.

4. Issue Summary

# Issue Location Severity
1 IoTDB fallback wording ignores per-table partition path IoTDB.md:279-280 (en/zh) Low
2 SelectDB default label prefix is per class load, not per job SelectDB-Cloud.md:49 (en/zh) Low
3 Phoenix query row references undocumented table_path / table_list Phoenix.md:46 (en/zh) Low

5. Merge Recommendation

Conclusion: Ready to merge

  1. Blockers - must be fixed: none.
  2. Recommended fixes - non-blocking: Issues 1-3, wording only; fine as a follow-up.

CI status: the apache-side Build, labeler and Notify test workflow checks are all SUCCESS on this head. The branch is 2 commits behind dev, which is metadata only here; the remaining gate is a maintainer approval.

Thanks again for keeping the docs honest!

@nzw921rx nzw921rx left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 LGTM

@nzw921rx
nzw921rx added this pull request to the merge queue Oct 19, 2026
@nzw921rx
nzw921rx removed this pull request from the merge queue due to a manual request Oct 19, 2026
@nzw921rx
nzw921rx added this pull request to the merge queue Oct 19, 2026

@nzw921rx nzw921rx left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the above three issues are worth supplementing and fixing in the future🔥

Merged via the queue into apache:dev with commit 1ce2d78 Oct 19, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants