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

Vincent Primault commented on SOLR-15782:
-----------------------------------------

Here is an example of what it would look like to configure a 
PlacementPluginFactory in solr.xml: https://github.com/apache/solr/pull/2071 
It's not fully tested yet, it's to discuss the approach.

It allows to configure the plugin in the following manner:
{code:xml}
<replicaPlacementFactory 
class="org.apache.solr.cluster.placement.plugins.AffinityPlacementFactory">
    <int name="minimalFreeDiskGB">10</int>
</replicaPlacementFactory>
{code}

I realised that my previous approach had one major drawback: it was configuring 
the initial plugins to be used, but then if a cluster plugin was installed and 
uninstalled, we would lose the plugin configured in solr.xml. I'm afraid that, 
unless we attempt a major refactoring, we have to go with ad-hoc code for every 
type of plugin, since they are instantiated in slightly different ways every 
time.

> Configure custom node/container handlers in solr.xml
> ----------------------------------------------------
>
>                 Key: SOLR-15782
>                 URL: https://issues.apache.org/jira/browse/SOLR-15782
>             Project: Solr
>          Issue Type: Improvement
>            Reporter: David Smiley
>            Priority: Major
>          Time Spent: 2h 40m
>  Remaining Estimate: 0h
>
> Since Solr 8.6 via SOLR-14404, it's been possible to define custom 
> node/CoreContainer request handlers.  However, the current mechanism requires 
> the use of cluster properties (in ZooKeeper).  That allows for dynamic 
> registration (cool) but it's awkward to pre-define them – it doesn't comply 
> with an [immutable 
> infrastructure|https://www.bmc.com/blogs/immutable-infrastructure/] philosphy 
> where node handlers can be defined by configuration local to the Solr node.  
> That's solr.xml.  So here, I propose that node handlers be defined there, 
> perhaps the same as is done in solrconfig.xml.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to