navina opened a new pull request, #18984:
URL: https://github.com/apache/pinot/pull/18984
## Summary
Adds an optional, additive `Map<String, String> extraMetadata` to
`FieldSpec` for free-form
per-column metadata, mirroring the existing optional `fieldId` / `aliases`.
## Details
- `@JsonInclude(NON_EMPTY)` — omitted from serialization when unset/empty.
- Excluded from `isBackwardCompatibleWith` (purely additive, never affects
compatibility).
- Round-tripped through the shared `appendFieldIdAliasesAndMetadata` helper,
so `TimeFieldSpec`
preserves it as well.
- Empty maps are normalized to `null` in the setter, keeping
equality/serialization stable.
- The keys and their interpretation are defined by whoever populates the
map; the core schema
attaches no semantics to it.
## Compatibility
Rolling-upgrade safe: old readers ignore the unknown property (concrete
subclasses are
`@JsonIgnoreProperties(ignoreUnknown = true)`), and new writers omit it when
empty, so JSON
produced with this change is unchanged for any schema that does not set it.
## Testing
Adds `FieldSpecTest` coverage: serde round-trip, omitted-when-unset,
empty-map-omitted,
`TimeFieldSpec`-through-`Schema`, deserialization of older JSON without the
field, `equals`/
`hashCode`, and exclusion from the backward-compatibility check.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]