How to change config set for some collection

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

How to change config set for some collection

pratik@semandex
Hello Everyone,

Let's say I have a collection called "collection1" which uses config set
"config_set_1".
Now, using "upconfig" command, I upload a new configuration called
"config_set_2". How can I make "collection1" use "config_set_2" instead of
"config_set_1"?

I know that if I upload new configuration with the same name "config_set_1"
and reload the collection then it will have new configuration but I want to
keep the old config set, add a new one and make changes so that collection1
starts using new config set.

Is it possible?


Thanks and Regards
Pratik
Reply | Threaded
Open this post in threaded view
|

Re: How to change config set for some collection

Shawn Heisey-2
On 11/20/2019 1:34 PM, Pratik Patel wrote:

> Let's say I have a collection called "collection1" which uses config set
> "config_set_1".
> Now, using "upconfig" command, I upload a new configuration called
> "config_set_2". How can I make "collection1" use "config_set_2" instead of
> "config_set_1"?
>
> I know that if I upload new configuration with the same name "config_set_1"
> and reload the collection then it will have new configuration but I want to
> keep the old config set, add a new one and make changes so that collection1
> starts using new config set.
>
> Is it possible?

There is an action, available in the zkcli script and possibly
elsewhere, called "linkconfig".

It looks like the config can also be changed with the collections API,
using the MODIFYCOLLECTION action.

https://lucene.apache.org/solr/guide/8_2/collection-management.html#modifycollection

To make the change effective after linking to a new config, you'll need
to reload the collection.

Thanks,
Shawn
Reply | Threaded
Open this post in threaded view
|

Re: How to change config set for some collection

pratik@semandex
Thanks Shawn! This is what I needed.

On Wed, Nov 20, 2019 at 3:59 PM Shawn Heisey <[hidden email]> wrote:

> On 11/20/2019 1:34 PM, Pratik Patel wrote:
> > Let's say I have a collection called "collection1" which uses config set
> > "config_set_1".
> > Now, using "upconfig" command, I upload a new configuration called
> > "config_set_2". How can I make "collection1" use "config_set_2" instead
> of
> > "config_set_1"?
> >
> > I know that if I upload new configuration with the same name
> "config_set_1"
> > and reload the collection then it will have new configuration but I want
> to
> > keep the old config set, add a new one and make changes so that
> collection1
> > starts using new config set.
> >
> > Is it possible?
>
> There is an action, available in the zkcli script and possibly
> elsewhere, called "linkconfig".
>
> It looks like the config can also be changed with the collections API,
> using the MODIFYCOLLECTION action.
>
>
> https://lucene.apache.org/solr/guide/8_2/collection-management.html#modifycollection
>
> To make the change effective after linking to a new config, you'll need
> to reload the collection.
>
> Thanks,
> Shawn
>