xiangfu0 commented on code in PR #18668:
URL: https://github.com/apache/pinot/pull/18668#discussion_r3366413238
##########
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/index/dictionary/DictionaryIndexType.java:
##########
@@ -178,8 +180,22 @@ private static boolean
hasExplicitDictionaryConfig(FieldConfig fieldConfig) {
return indexes != null && indexes.isObject() &&
indexes.has(StandardIndexes.DICTIONARY_ID);
}
+ private static FieldConfig.EncodingType getForwardEncodingType(FieldConfig
fieldConfig) {
Review Comment:
Addressed in the amended head `3e3615f`: `ForwardIndexType` now owns
`ENCODING_TYPE_CONFIG_KEY`, `getForwardEncodingType(FieldConfig)`, and
`withForwardEncoding(...)`; `DictionaryIndexType` uses those instead of
re-parsing/writing `indexes.forward.encodingType` locally. The legacy fallback
remains centralized there for conversion paths that still inspect configs
before validation.
##########
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/utils/TableConfigUtils.java:
##########
@@ -1594,11 +1593,13 @@ private static void
validateIndexingConfigAndFieldConfigList(TableConfig tableCo
String column = fieldConfig.getName();
Preconditions.checkState(seenColumns.add(column), "Duplicate
FieldConfig for column: %s", column);
Preconditions.checkState(schema.hasColumn(column), "Failed to find
column: %s in schema", column);
+ Preconditions.checkState(!fieldConfig.hasFieldLevelEncodingType(),
Review Comment:
Intentional hard break: table create/update should reject field-level
`fieldConfigList[].encodingType` and direct users to
`fieldConfigList[].indexes.forward.encodingType`. I updated the PR description
and README/manual text to state that explicitly, including the validation error
and sample config. The legacy field still deserializes for read/conversion
paths, but submitted table configs are expected to migrate before create/update
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]