DanielLeens commented on PR #13525:
URL: https://github.com/apache/seatunnel/pull/13525#issuecomment-7234552302

   ### Implementation Notes and Trade-offs
   
   Current remote head: `421311c3b4c958c698a4729eed3e594db2571d01`. This 
repairs the original `16ba51350e2b506e28c83ea7dff741764a130904` findings in 
[the complete 
review](https://github.com/apache/seatunnel/pull/13525#pullrequestreview-6095814348).
 The original review was corrected after the native allocation gap was 
confirmed; this correction does not erase the original-head blocker.
   
   Native JSON/DELIMITED previously allocated the complete aggregate before 
checking the record limit. A small shared-reference ARRAY/MAP/ROW could 
therefore expand far beyond that limit. The connector now charges every 
repeated value, entry/key/container and numeric expansion before aggregate 
conversion. This is source-derived safety work, not a locally executed OOM 
claim.
   
   JSON reuses public native scalar conversion while iteratively building a 
bounded native tree and iteratively emitting containers to a capped output. It 
preserves native scalar formatting, insertion/key-overwrite order, plain 
numeric values and compact numeric map keys. It avoids eager composite 
schema-DAG construction and deep container recursion without inventing a fixed 
depth cap. DELIMITED keeps the existing native formatter after complete lazy 
preflight and checks its original separator-depth constraint before recursion. 
Exactly one final LF remains writer-owned.
   
   A necessary documented guard counts conversion work even when rendered 
map-key collisions would shrink final output. Counting each shared identity 
once or checking only final bytes would leave the allocation gap. Shared 
serializers, engine/API, state and POM/dependencies were kept unchanged. RAW 
and JSON_LINES retain their original encoding/validation. Both guides now state 
the direct network requirement; class/state/lifecycle ownership is documented 
and helper-order movement is equivalent.
   
   All original12 IT methods/assertions are preserved; one native-array Zeta 
method and five component methods were added. The distinguishing regression 
uses a legal16-entry TrackingMap/128-byte shared value/512-byte cap through the 
real writer and HTTP transport: reject before all entries are consumed and 
before any request. Small native maps assert exact captured bytes/LF. Deep 
JSON, modest shared schema, numeric keys/collisions and exact escaping 
boundaries are also authored. The added array IT is not claimed to 
independently prove early allocation containment.
   
   Both leaf Spotless apply/check runs and static 
diff/body-preservation/registration checks passed. No local compile, tests, 
E2E, Docker, service/provider or engine jobs ran. [Exact-head 
CI46110970403](https://github.com/DanielLeens/seatunnel/actions/runs/46110970403)
 is pending; no functional or live AWS acceptance is claimed. Independent human 
source review may proceed while CI is the sole remaining blocker; 
merge/approval still require separate review and validation.
   


-- 
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]

Reply via email to