[
https://issues.apache.org/jira/browse/SOLR-16305?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17618812#comment-17618812
]
Andrzej Bialecki commented on SOLR-16305:
-----------------------------------------
{quote}Should this Jira have a linked "converse" issue: "CREATE collection
with property.* doesn't set values in DocCollection (even though
MODIFYCOLLECTION can cahnge them)" ?
{quote}
I think so.
{quote}WTF the {{COLLECTIONPROP}} command's purpose / expected usage is?
{quote}
AFAIK they are currently used only for maintaining routed aliases. We could
extend it to cover a use case of "I want to maintain arbitrary props per
collection" but then we would have to add the reading API and document it. And
probably do some other work too, because this API is isolated from the main
DocCollection model.
(For me one reason for ab-using DocCollection to keep properties was that
there's currently no connection between props that you can set with
COLLECTIONPROP and the replica placement API model, which purposely uses API
disconnected from Solr internals. So if I want to mark some collection as
having this or other replica placement properties, the
SolrCollection.getCustomProperty ONLY returns props set in DocCollection and
not those set with COLLECTIONPROP. Of course, I can always keep these special
props in a config file specific to the placement plugin ... but this
complicates the lifecycle of these properties as you create / delete
collections, so keeping them in DocCollection is convenient).
> MODIFYCOLLECTION with 'property.*' changes can't change values used in config
> file variables (even though they can be set during collection CREATE)
> ---------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: SOLR-16305
> URL: https://issues.apache.org/jira/browse/SOLR-16305
> Project: Solr
> Issue Type: Bug
> Security Level: Public(Default Security Level. Issues are Public)
> Reporter: Chris M. Hostetter
> Priority: Major
> Attachments: SOLR-16305_test.patch
>
>
> Consider a configset with a {{solrconfig.xml}} that includes a snippet like
> this...
> {code:java}
> <str name="param.check">${custom.prop:customDefVal}</str>
> {code}
> ...this {{custom.prop}} can be set when doing a {{CREATE}} command for a
> collection that uses this configset, using the {{property.*}} prefix as noted
> in the reg-guide...
> {quote}{{property.{_}name{_}={_}value{_}}}
> |Optional|Default: none|
> Set core property _name_ to {_}value{_}. See the section [Core
> Discovery|https://solr.apache.org/guide/solr/latest/configuration-guide/core-discovery.html]
> for details on supported properties and values.
> {quote}
> ...BUT....
> These values can *not* be changed by using the {{MODIFYCOLLECTION}} command,
> in spite of the ref-guide indicating that it can be used to modify custom
> {{property.*}} attributes...
> {quote}The attributes that can be modified are:
> * {{replicationFactor}}
> * {{collection.configName}}
> * {{readOnly}}
> * other custom properties that use a {{property.}} prefix
> See the [CREATE
> action|https://solr.apache.org/guide/solr/latest/deployment-guide/collection-management.html#create]
> section above for details on these attributes.
> {quote}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]