You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@lucene.apache.org by "Noble Paul (Jira)" <ji...@apache.org> on 2020/04/10 09:04:00 UTC

[jira] [Created] (SOLR-14404) CoreContainer level custom requesthandlers

Noble Paul created SOLR-14404:
---------------------------------

             Summary: CoreContainer level custom requesthandlers
                 Key: SOLR-14404
                 URL: https://issues.apache.org/jira/browse/SOLR-14404
             Project: Solr
          Issue Type: New Feature
      Security Level: Public (Default Security Level. Issues are Public)
            Reporter: Noble Paul
            Assignee: Noble Paul




caveats:
* The class should implement {{org.apache.solr.api.Api}}. Which means only V2 APIs are supported
* The path should have prefix {{/api/cluster}} or {{/api/node}}. It should not conflict with any of the exiting handlers


add a handler
{code}
curl -X POST -H 'Content-type:application/json' --data-binary '
{
  "add-requesthandler": {
  "name":"myhandler", "class": "full.ClassName"    
  }
}' http://localhost:8983/api/cluster
{code}

remove a handler
{code}
curl -X POST -H 'Content-type:application/json' --data-binary '
{
  "remove-requesthandler": "myhandler"
}' http://localhost:8983/api/cluster
{code}
The configuration will be stored in the {{clusterprops.json}}
as
{code}
{
"requestHandler" : {
"myhandler" : {"class": "full.ClassName" }
}
}
{code}





--
This message was sent by Atlassian Jira
(v8.3.4#803005)

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