You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Marius Ghita (JIRA)" <ji...@apache.org> on 2018/02/15 17:45:00 UTC

[jira] [Comment Edited] (SOLR-12002) Allow DocValue type changes without reindex

    [ https://issues.apache.org/jira/browse/SOLR-12002?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16365884#comment-16365884 ] 

Marius Ghita edited comment on SOLR-12002 at 2/15/18 5:44 PM:
--------------------------------------------------------------

The field is just defined as (no multiValued attribute):

{{<field name="companyType" type="string" indexed="true" stored="true" docValues="true"/>}}

The field is used only for queries, no faceting/grouping is done currently on that field.

And the only reason I've added docValues="true" was because that was the answer to my Google search on how to remove those warnings from the Solr log (this, while developing the schema changes locally).

During the deployment of the new schema all I did was:
 # overwrite schema.xml with the new version
 # reload core in admin interface
 # run dataimporter with default parameters (clean, commit, command=full-import, across all entities defined in data-config.xml)
 # saw the warnings that showed up
 # repeat a couple of times step 2-3 to make sure that I'm seeing the same warnings every time dataimport is running

Given that I saw no difference between my local Solr configuration and the one on the server, I restarted the Solr server, and dataimporter happily ran without further warnings.

Edit: in my original schema definition, that field was at first a multiValued field; the original definition before the changes I've made
 {{<field name="companyType" type="string" multiValued="true" indexed="true" stored="true"/>}}


was (Author: marius.ghita):
The field is just defined as (no multiValued attribute):

{{<field name="companyType" type="string" indexed="true" stored="true" docValues="true"/>}}

The field is used only for queries, no faceting/grouping is done currently on that field.

And the only reason I've added docValues="true" was because that was the answer to my Google search on how to remove those warnings from the Solr log (this, while developing the schema changes locally). 

During the deployment of the new schema all I did was:
# overwrite schema.xml with the new version
# reload core in admin interface
# run dataimporter with default parameters (clean, commit, command=full-import, across all entities defined in data-config.xml)  
# saw the warnings that showed up
# repeat a couple of times step 2-3 to make sure that I'm seeing the same warnings every time dataimport is running

Given that I saw no difference between my local Solr configuration and the one on the server, I restarted the Solr server, and dataimporter happily ran without further warnings.

> Allow DocValue type changes without reindex
> -------------------------------------------
>
>                 Key: SOLR-12002
>                 URL: https://issues.apache.org/jira/browse/SOLR-12002
>             Project: Solr
>          Issue Type: Improvement
>      Security Level: Public(Default Security Level. Issues are Public) 
>    Affects Versions: 6.6.2
>            Reporter: Marius Ghita
>            Priority: Major
>
> I've made a change to our Solr schema where an existing field was changed and docValues="true" was added. Only doing a core reload, during reindexing (with the clean flag, in dataimporter) the message "Cannot change DocValues type from SORTED_SET to SORTED for field companyType" showed up in the logs, but not for all documents.
> Issuing a Solr restart and then reindexing fixed the issue. Under the assumption that core reload should handle any schema changes without issue, I think that this behaviour can be considered a bug.
> Note that I'm using the classical schema configuration (disabled managed schema), maybe managed schema exhibits the same behaviour but that's untested on my end.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org