You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@solr.apache.org by "VadimKirilchuk (via GitHub)" <gi...@apache.org> on 2026/06/07 22:36:18 UTC

[PR] SOLR-18251: Introduced docValuesSkipList='true' field property [solr]

VadimKirilchuk opened a new pull request, #4509:
URL: https://github.com/apache/solr/pull/4509

   https://issues.apache.org/jira/browse/SOLR-18251
   
   # Description
   
   Introduced docValuesSkipList='true' field property to allow creating DocValues Field instances with optional skip list index support, improving query performance.
   
   # Solution
   
   Added a new boolean field property docValuesSkipList that can be set to true in schema field definitions (only fields supporting Numeric, Sorted Numeric, Sorted and Sorted Set doc value types). When enabled, Solr creates DocValues fields with an additional skip index, which enables more efficient range queries on DocValues. When not set (default false), standard DocValues fields are created without the skip index.
   
   Changes include:
   
   - New utility class DocValuesFieldUtil with methods to create DocValues fields with or without skip indexes (createSortedDocValuesField, createSortedSetDocValuesField, createNumericDocValuesField, createSortedNumericDocValuesField)
   - Updated all DocValues-enabled field types (BoolField, CollationField, EnumFieldType, PointField, StrField, TrieField, SortableTextField, ICUCollationField) to respect the new property when creating DocValues fields
   - Extended SchemaField and FieldProperties to expose the property in schema configuration
   
   # Tests
   
   - Added REST API validation via TestFieldResource
   - Comprehensive test suite DocValuesSkipListTest covering all DocValues field types (single and multi-valued)
   - Test schema schema-docValuesSkipList.xml with full coverage of all DocValues types
   
   # Checklist
   
   Please review the following and check all that apply:
   
   - [X] I have reviewed the guidelines for [How to Contribute](https://github.com/apache/solr/blob/main/CONTRIBUTING.md) and my code conforms to the standards described there to the best of my ability.
   - [ ] I have created a Jira issue and added the issue ID to my pull request title.
   - [X] I have given Solr maintainers [access](https://help.github.com/en/articles/allowing-changes-to-a-pull-request-branch-created-from-a-fork) to contribute to my PR branch. (optional but recommended, not available for branches on forks living under an organisation)
   - [X] I have developed this patch against the `main` branch.
   - [X] I have run `./gradlew check`.
   - [X] I have added tests for my changes.
   - [ ] I have added documentation for the [Reference Guide](https://github.com/apache/solr/tree/main/solr/solr-ref-guide)
   - [ ] I have added a [changelog entry](https://github.com/apache/solr/blob/main/dev-docs/changelog.adoc) for my change
   


-- 
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: issues-unsubscribe@solr.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org


Re: [PR] SOLR-18251: Introduced docValuesSkipList='true' field property [solr]

Posted by "dsmiley (via GitHub)" <gi...@apache.org>.
dsmiley commented on code in PR #4509:
URL: https://github.com/apache/solr/pull/4509#discussion_r3591691244


##########
solr/core/src/java/org/apache/solr/schema/DocValuesFieldUtil.java:
##########
@@ -0,0 +1,99 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.solr.schema;
+
+import org.apache.lucene.document.NumericDocValuesField;
+import org.apache.lucene.document.SortedDocValuesField;
+import org.apache.lucene.document.SortedNumericDocValuesField;
+import org.apache.lucene.document.SortedSetDocValuesField;
+import org.apache.lucene.index.IndexableField;
+import org.apache.lucene.util.BytesRef;
+
+/**
+ * Utility class for creating DocValues {@link IndexableField} instances with optional skip index
+ * support.
+ *
+ * <p>When {@code hasDocValuesSkipList} is true, this utility creates indexed DocValues fields that
+ * include a range skip index for more efficient range queries. Otherwise, it creates standard
+ * DocValues fields.
+ */
+public final class DocValuesFieldUtil {

Review Comment:
   This is debatable to exist at all... I wonder if relevant methods can't by on FieldType.  
   My preference is to remove this class altogether.



-- 
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: issues-unsubscribe@solr.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org


Re: [PR] SOLR-18251: Introduced docValuesSkipList='true' field property [solr]

Posted by "iamsanjay (via GitHub)" <gi...@apache.org>.
iamsanjay commented on PR #4509:
URL: https://github.com/apache/solr/pull/4509#issuecomment-4780168694

   I have already created PR #4458 for this, but I forgot to link it to the JIRA issue. The initial implementation enables it only for PointField. I’m currently working on benchmarks to determine whether it provides any meaningful improvement for range queries.


-- 
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: issues-unsubscribe@solr.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org


Re: [PR] SOLR-18251: Introduced docValuesSkipList='true' field property [solr]

Posted by "VadimKirilchuk (via GitHub)" <gi...@apache.org>.
VadimKirilchuk commented on PR #4509:
URL: https://github.com/apache/solr/pull/4509#issuecomment-4986942114

   > Not sure how to reconcile the fact that we have 2 competing PRs...
   
   Well, need to merge the best of both worlds/PRs I guess. 
   
   I'll resolve your comment for DocValuesUtil and see what I can pull from the other PR, overall I think they are pretty similar.


-- 
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: issues-unsubscribe@solr.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org


Re: [PR] SOLR-18251: Introduced docValuesSkipList='true' field property [solr]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #4509:
URL: https://github.com/apache/solr/pull/4509#issuecomment-5723041826

   This PR has had no activity for 60 days and is now labeled as stale.  Any new activity will remove the stale label.  To attract more reviewers, please tag people who might be familiar with the code area and/or notify the dev@solr.apache.org mailing list. To exempt this PR from being marked as stale, make it a draft PR or add the label "exempt-stale". If left unattended, this PR will be closed after another 60 days of inactivity. Thank you for your contribution!


-- 
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: issues-unsubscribe@solr.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org