You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by Tom Burton-West <tb...@umich.edu> on 2017/08/30 18:45:45 UTC

Error in Solr 6.6 Example schemas re: docValues for StrField type must be single-valued?

Hello,

There appears to be an error in the comments in the Solr 6.6 example
schemas.  No responses except for one offline to this issue in the Solr
users list so I am posting to the dev list with the hope to fix the
comments if they are indeed in error. See below. Should I open a JIRA issue?

The comments in the example schema's for Solr 6.6, state that the StrField
type must be single-valued to support doc values

For example Solr-6.6.0/server/solr/configsets/basic_configs/conf/
managed-schema:

216      <!-- The StrField type is not analyzed, but indexed/stored
verbatim.
   217         It supports doc values but in that case the field needs to be
   218         single-valued and either required or have a default value.
   219        -->

However, on line 221 a StrField is declared with docValues that is
multiValued:
221      <fieldType name="strings" class="solr.StrField"
sortMissingLast="true" multiValued="true" docValues="true" />

Also note that the comments above say that the field must either be
required or have a default value, but line 221 appears to satisfy neither
condition.

The JavaDocs indicate that StrField can be multi-valued https://lucene.
apache.org/core/6_6_0//core/org/apache/lucene/index/DocValuesType.html

Is the comment in the example schema file  completely wrong, or is there
some issue with using a docValues with a multivalued StrField?

Tom Burton-West

https://www.hathitrust.org/blogslarge-scale-search

Re: Error in Solr 6.6 Example schemas re: docValues for StrField type must be single-valued?

Posted by Varun Thacker <va...@vthacker.in>.
Hi Tom,

I am pretty sure that comment is outdated and none of those constraints are
valid anymore. It's there in the default config in 7.x as well.

Can you please create a Jira so that we can fix this.

On Thu, Aug 31, 2017 at 12:15 AM, Tom Burton-West <tb...@umich.edu>
wrote:

> Hello,
>
> There appears to be an error in the comments in the Solr 6.6 example
> schemas.  No responses except for one offline to this issue in the Solr
> users list so I am posting to the dev list with the hope to fix the
> comments if they are indeed in error. See below. Should I open a JIRA issue?
>
> The comments in the example schema's for Solr 6.6, state that the
> StrField type must be single-valued to support doc values
>
> For example Solr-6.6.0/server/solr/configsets/basic_configs/
> conf/managed-schema:
>
> 216      <!-- The StrField type is not analyzed, but indexed/stored
> verbatim.
>    217         It supports doc values but in that case the field needs to
> be
>    218         single-valued and either required or have a default value.
>    219        -->
>
> However, on line 221 a StrField is declared with docValues that is
> multiValued:
> 221      <fieldType name="strings" class="solr.StrField"
> sortMissingLast="true" multiValued="true" docValues="true" />
>
> Also note that the comments above say that the field must either be
> required or have a default value, but line 221 appears to satisfy neither
> condition.
>
> The JavaDocs indicate that StrField can be multi-valued https://lucene.ap
> ache.org/core/6_6_0//core/org/apache/lucene/index/DocValuesType.html
>
> Is the comment in the example schema file  completely wrong, or is there
> some issue with using a docValues with a multivalued StrField?
>
> Tom Burton-West
>
> https://www.hathitrust.org/blogslarge-scale-search
>