gortiz opened a new pull request, #10584:
URL: https://github.com/apache/pinot/pull/10584
This is a bugfix.
As introduced in #10183, each `IndexConfig` subclass had to manually check
for `enabled` nullability in its own way. It is correct that some indexes may
request to explicitly ask for `enabled: true` in order to be enabled, but all
default indexes should be enabled if their config object is present.
For example:
```js
{
bloom: {
fpp: 0.02,
}
}
```
Should be considered as a enabled config. Even the empty object should be
considered enabled
```js
{
bloom: {
}
}
```
In order to explicitly disable an index one must write
```js
{
bloom: {
enabled: "false"
}
}
```
If the index key is not present or set to null, then the default value will
be used. In that case, whether the index is enable or not depends on the index
type. For example forward index is enabled by default.
Previous code was erroneously initializing some index configs as disabled,
as detected in #10554 for bloom filter. Affected indexes were:
- Bloom
- Dictionary
- H3
- FST
- Range
- Text
- Inverted
This PR adds a constructor in `IndexConfig` that contains the default logic,
which is the one all default indexes should use. The PR also add unit tests
that verify the correct deserialization of indexes for all index types.
--
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]