Thank you very much Shawn! Will give it a try.. On Friday, November 11, 2016, Shawn Heisey <apa...@elyograg.org> wrote:
> On 11/9/2016 11:04 PM, Gimantha Bandara wrote: > > I have requirement where multiple solr cores need to be created with > > different schema. Using CoreAdminAPI, I can create a core dynamically > > but, I have to create a folder and copy the schema.xml and > > solrconfig.xml there before invoking the API. Is there a way to create > > solr cores with some kind of default configurations using solrj? I > > tried using configSets, but it seems all the cores are referring to > > the same ConfigSet and changes done to the schema of the cores, > > reflect on the configSet, which will ultimately change the schema of > > all the cores. > > SolrJ does not have the ability to directly upload complete > configuration data to a standalone Solr install, because a standalone > Solr install has no API methods available for that. > > The configsets feature is an attempt to bring configuration management > to standalone Solr. It is similar, but not identical, to the > configuration management that has been available in SolrCloud since it > became available in version 4.0 ... but as far as I know, it still does > not provide a way to upload these configurations like SolrCloud does. I > could be wrong about that part. > > If you run SolrCloud, then all these problems go away. Starting in > version 5.1.0, SolrJ has CloudSolrClient#uploadConfig, which uploads a > configuration to zookeeper that collections can then use. Collections > can either share configs or each can have its own. > > https://lucene.apache.org/solr/5_1_0/solr-solrj/org/ > apache/solr/client/solrj/impl/CloudSolrClient.html# > uploadConfig(java.nio.file.Path,%20java.lang.String) > > Thanks, > Shawn > >