DanielLeens opened a new issue, #13629: URL: https://github.com/apache/seatunnel/issues/13629
## Improvement The JDBC-to-Elasticsearch pipeline still has a complete-engine performance gap in a matched batch-2000 diagnostic: DataX 68.961s / SeaTunnel 72.200s, both with exact reconciliation of the declared 19-field common JSON model. This is one diagnostic pair, not three-run acceptance, and the whole-job difference is not attributed solely to the response parser. In pinned dev 5cf050be3ffc77c0065d67d4eb8af83f24a2a620, EsRestClient.bulk materializes the complete successful HTTP response as a JsonNode tree. Its consumer reads only the root took/errors values, while BulkResponse already retains the complete original response string. Every per-item result is therefore allocated in a second representation without being used by this status calculation. Sanitized JFR shows ObjectNode/LinkedHashMap allocation and JSON parsing in this path; sampled/TLAB-weighted allocations are not an exact savings estimate. Use an incremental root-status reader while retaining the entire original response body. Preserve existing numeric/boolean coercion and last-key handling, continue validating the complete JSON value, and keep string/number/nesting limits enforced in unneeded item fields. A simple skipChildren shortcut is insufficient: Jackson 2.15.4 can defer string materialization and therefore bypass the string-length check when skipping. Missing status fields and malformed item payloads must not turn into successful writes. HTTP status/error handling, retries and write requests must remain unchanged. Scope: this connector's existing REST client, existing focused tests, existing ElasticsearchIT and matching English/Chinese sink documentation. No engine/core/API, POM, dependency, user option/default, row format, batching, retry or commit changes. Before submission, validate source compatibility, key malformed/partial-error responses, standard module checks and the real self-hosted Elasticsearch 8.9.0 pipeline. Full-engine throughput acceptance remains at least three alternating million-row pairs with 19 values reconciled and ST faster every pair; profiles are diagnostic only. History: the bulk response path dates to #2330, and the current Jackson readTree call arrived in #8412. Searches of open/closed PRs for ElasticsearchRowSerializer, EsRestClient response, bulk response and streaming found no matching response-tree optimization. #13557 documents batch sizing, #11567 shares REST client resources, and #13589 caches JDBC row-conversion metadata; these are distinct changes. Repeat the duplicate check before opening a PR. Primary sources: [current client](https://github.com/apache/seatunnel/blob/5cf050be3ffc77c0065d67d4eb8af83f24a2a620/seatunnel-connectors-v2/connector-elasticsearch/src/main/java/org/apache/seatunnel/connectors/seatunnel/elasticsearch/client/EsRestClient.java), [Jackson 2.15.4 reader](https://github.com/FasterXML/jackson-core/blob/jackson-core-2.15.4/src/main/java/com/fasterxml/jackson/core/json/ReaderBasedJsonParser.java). -- 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]
