li3zhi4 commented on issue #11632:
URL: https://github.com/apache/seatunnel/issues/11632#issuecomment-5186797850

   @SEZ9 — thanks for confirming the bug and for the detailed suggestions. The 
PR is already submitted and linked from this issue (#11633, closes #11632):
   
   1. **Design point ① (should `defaultValue` apply only for missing fields, or 
also for explicit `null`?)**: implemented per this issue's acceptance criteria 
— the configured default is applied for **both** a missing field and an 
explicit JSON `null`, and normalized to the column type by the deserializer. A 
nullable column without a configured default keeps returning `null` for 
explicit `null` (backward compatible). Both paths have unit test coverage 
(`JsonDefaultValueTest#testDefaultValueWhenFieldMissing` covers missing and 
explicit-null; `testNoDefaultValueWhenFieldMissing` covers the no-default case).
   
   2. **Design point ② (text/csv etc. may have the same gap — should the fix 
live in a shared layer?)**: agreed this is a shared gap. This PR deliberately 
scopes to the JSON format (`seatunnel-format-json`) to keep the change 
reviewable; a follow-up for the other formats (text/csv/…) would be better 
tracked in a separate issue so this PR stays single-purpose.
   
   3. Your review findings on the PR (nested-ROW scoping, shared mutable 
defaults for ARRAY/MAP/BYTES, test coverage for unconvertible defaults, e2e 
ordering) have all been addressed on the current head `61d05f5a34` and replied 
to on the PR.
   
   Thanks again for the sharp review.
   


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