Jackie-Jiang opened a new pull request, #18815:
URL: https://github.com/apache/pinot/pull/18815
## Summary
Renames the enum constants `PinotDataType.INTEGER` → `INT` and
`INTEGER_ARRAY` → `INT_ARRAY` so the spelling matches `FieldSpec.DataType.INT`,
`DataSchema.ColumnDataType.INT`, and the SQL type name. The mismatch (`INTEGER`
vs the `INT` everyone else uses) is a recurring source of confusion.
`PinotDataType` is a transient type-conversion helper — it is never
persisted by name into segment metadata, ZooKeeper, table config, or the wire
protocol (only `FieldSpec.DataType` is, and it is untouched). So the rename
carries no serialization or mixed-version compatibility risk.
### Backward compatibility
The only place that resolves a `PinotDataType` from a user-supplied string
by name is the `cast` scalar function. `CAST(x AS INTEGER)` previously resolved
via the `PinotDataType.valueOf("INTEGER")` default branch. An explicit `case
"INTEGER"` alias is added so that literal keeps working (alongside `INT`), and
a regression test pins it.
The rest of the change is a mechanical reference update
(`PinotDataType.INTEGER` → `INT`, `case INTEGER:` → `case INT:` for
`PinotDataType` switches only — Calcite `SqlTypeName`/`SqlTypeFamily` and
`java.sql.Types` `INTEGER` references are left intact) plus test-data updates.
--
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]