goutamadwant opened a new pull request, #11869:
URL: https://github.com/apache/seatunnel/pull/11869
### Purpose of this pull request
Part of #10425.
- Add `tables_configs` support to the Neo4j source, with one Cypher query
and schema per table.
- Register every configured table with the runtime and set the matching
table ID on emitted rows.
- Execute configured queries in declaration order through one Neo4j driver
and session.
- Keep the existing root-level `query` and `schema` configuration unchanged.
- Validate empty, incomplete, mixed, and duplicate table configurations
before the source starts.
### Does this PR introduce _any_ user-facing change?
Yes. The Neo4j source can now read multiple logical tables in one source
configuration using `tables_configs`.
Existing single-table configurations continue to use the root-level `query`
and `schema` options without any behavior change.
The English and Chinese connector documentation includes the new option and
a multi-table example.
### How was this patch tested?
Added unit coverage for:
- legacy single-table validation
- valid multi-table configuration and catalog table registration
- mixed single-table and multi-table options
- missing query or schema configuration
- blank and duplicate table IDs
- table-specific row conversion and table ID assignment
Added an E2E test that reads two Neo4j queries with different table IDs and
validates both tables through the multi-table Assert sink. The test passes with
Flink 1.18, Flink 1.20, Zeta, and Spark 3.3.
Verified with:
```shell
./mvnw -B -T 1 -pl seatunnel-connectors-v2/connector-neo4j test
RUN_ALL_CONTAINER=false RUN_ZETA_CONTAINER=true ./mvnw -B -T 1 \
-pl seatunnel-e2e/seatunnel-connector-v2-e2e/connector-neo4j-e2e \
-Dapi.version=1.40 -DskipUT=true -DskipIT=false \
'-Dit.test=Neo4jIT#testMultiTableSource' verify
```
### Check list
* [x] No new Jar binary package is added.
* [x] Updated the English and Chinese Neo4j source documentation.
* [x] No incompatible change is introduced; the existing single-table
configuration remains supported.
* [x] Existing connector mapping, distribution, CI label, and plugin
configuration files do not need changes because this extends the existing Neo4j
connector.
* [x] Added a focused multi-table E2E test under `seatunnel-e2e`.
--
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]