You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by xi...@apache.org on 2025/12/19 01:18:19 UTC

(pinot) branch master updated: Remove text Index from index map when storeInSegmentFile flag is true. (#17396)

This is an automated email from the ASF dual-hosted git repository.

xiangfu pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git


The following commit(s) were added to refs/heads/master by this push:
     new 33d0ec1dd61 Remove text Index from index map when storeInSegmentFile flag is true. (#17396)
33d0ec1dd61 is described below

commit 33d0ec1dd610e4701b0829f8803fd610fdf3dab4
Author: RAGHVENDRA KUMAR YADAV <ra...@gmail.com>
AuthorDate: Thu Dec 18 17:18:13 2025 -0800

    Remove text Index from index map when storeInSegmentFile flag is true. (#17396)
---
 .../local/segment/index/loader/invertedindex/TextIndexHandler.java     | 3 +++
 .../pinot/segment/local/segment/store/SingleFileIndexDirectory.java    | 1 -
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/index/loader/invertedindex/TextIndexHandler.java b/pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/index/loader/invertedindex/TextIndexHandler.java
index 41b275bf894..44a9b879a91 100644
--- a/pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/index/loader/invertedindex/TextIndexHandler.java
+++ b/pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/index/loader/invertedindex/TextIndexHandler.java
@@ -127,6 +127,9 @@ public class TextIndexHandler extends BaseIndexHandler {
     Set<String> existingColumns = segmentWriter.toSegmentDirectory().getColumnsWithIndex(StandardIndexes.text());
     // Handle configuration changes for existing indexes
     for (String column : existingColumns) {
+      if (!columnsToAddIdx.contains(column)) {
+        continue;
+      }
       ColumnMetadata columnMetadata = _segmentDirectory.getSegmentMetadata().getColumnMetadataFor(column);
       if (columnMetadata != null && hasTextIndexConfigurationChanged(column, segmentWriter)) {
         LOGGER.info("Updating text index configuration for segment: {}, column: {}", segmentName, column);
diff --git a/pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/store/SingleFileIndexDirectory.java b/pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/store/SingleFileIndexDirectory.java
index e727a4581af..2e31cdbabc7 100644
--- a/pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/store/SingleFileIndexDirectory.java
+++ b/pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/store/SingleFileIndexDirectory.java
@@ -449,7 +449,6 @@ class SingleFileIndexDirectory extends ColumnIndexDirectory {
     // Text index is kept in its own files, thus can be removed directly.
     if (indexType == StandardIndexes.text()) {
       TextIndexUtils.cleanupTextIndex(_segmentDirectory, columnName);
-      return;
     }
     if (indexType == StandardIndexes.vector()) {
       VectorIndexUtils.cleanupVectorIndex(_segmentDirectory, columnName);


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org