You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by no...@apache.org on 2016/11/10 13:46:51 UTC

lucene-solr:apiv2: SOLR-8029: filling in some missing specs

Repository: lucene-solr
Updated Branches:
  refs/heads/apiv2 5eff7ce52 -> 776eae244


SOLR-8029: filling in some missing specs


Project: http://git-wip-us.apache.org/repos/asf/lucene-solr/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucene-solr/commit/776eae24
Tree: http://git-wip-us.apache.org/repos/asf/lucene-solr/tree/776eae24
Diff: http://git-wip-us.apache.org/repos/asf/lucene-solr/diff/776eae24

Branch: refs/heads/apiv2
Commit: 776eae2449450d21b25cef0717d996cdd9b0cce3
Parents: 5eff7ce
Author: Noble Paul <no...@apache.org>
Authored: Thu Nov 10 19:16:40 2016 +0530
Committer: Noble Paul <no...@apache.org>
Committed: Thu Nov 10 19:16:40 2016 +0530

----------------------------------------------------------------------
 .../solr/handler/admin/CoreAdminHandlerApi.java      |  8 ++++----
 .../cluster.security.RuleBasedAuthorization.json     | 14 ++++++++++++++
 .../cluster.security.authentication.Commands.json    |  3 ++-
 .../cluster.security.authorization.Commands.json     |  3 ++-
 .../src/resources/apispec/core.config.Commands.json  |  3 +--
 solr/core/src/resources/apispec/cores.Commands.json  |  2 +-
 .../src/resources/apispec/cores.core.Commands.json   | 15 ++++++++++++---
 7 files changed, 36 insertions(+), 12 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/776eae24/solr/core/src/java/org/apache/solr/handler/admin/CoreAdminHandlerApi.java
----------------------------------------------------------------------
diff --git a/solr/core/src/java/org/apache/solr/handler/admin/CoreAdminHandlerApi.java b/solr/core/src/java/org/apache/solr/handler/admin/CoreAdminHandlerApi.java
index ebc1bbd..306bf1e 100644
--- a/solr/core/src/java/org/apache/solr/handler/admin/CoreAdminHandlerApi.java
+++ b/solr/core/src/java/org/apache/solr/handler/admin/CoreAdminHandlerApi.java
@@ -53,11 +53,11 @@ public class CoreAdminHandlerApi extends BaseHandlerApiSupport {
     RENAME(PER_CORE_COMMANDS, POST, RENAME_OP, null, null),
     MERGEINDEXES(PER_CORE_COMMANDS, POST, MERGEINDEXES_OP, "merge-indexes", null),
     SPLIT(PER_CORE_COMMANDS, POST, SPLIT_OP, null, ImmutableMap.of("split.key", "splitKey")),
-    PREPRECOVERY(PER_CORE_COMMANDS, POST, PREPRECOVERY_OP, null, null),
+    PREPRECOVERY(PER_CORE_COMMANDS, POST, PREPRECOVERY_OP, "prep-recovery", null),
     REQUESTRECOVERY(PER_CORE_COMMANDS, POST, REQUESTRECOVERY_OP, null, null),
-    REQUESTSYNCSHARD(PER_CORE_COMMANDS, POST, REQUESTRECOVERY_OP, null, null),
-    REQUESTBUFFERUPDATES(PER_CORE_COMMANDS, POST, REQUESTBUFFERUPDATES_OP, null, null),
-    REQUESTAPPLYUPDATES(PER_CORE_COMMANDS, POST, REQUESTAPPLYUPDATES_OP, null, null),
+    REQUESTSYNCSHARD(PER_CORE_COMMANDS, POST, REQUESTRECOVERY_OP, "request-sync-shard", null),
+    REQUESTBUFFERUPDATES(PER_CORE_COMMANDS, POST, REQUESTBUFFERUPDATES_OP, "request-buffer-updates", null),
+    REQUESTAPPLYUPDATES(PER_CORE_COMMANDS, POST, REQUESTAPPLYUPDATES_OP, "request-apply-updates", null),
     REQUESTSTATUS(PER_CORE_COMMANDS, POST, REQUESTSTATUS_OP, null, null),
     OVERSEEROP(NODEAPIS, POST, OVERSEEROP_OP, "overseer-op", null),
     REJOINLEADERELECTION(NODEAPIS, POST, REJOINLEADERELECTION_OP, "rejoin-leader-election", null),

http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/776eae24/solr/core/src/resources/apispec/cluster.security.RuleBasedAuthorization.json
----------------------------------------------------------------------
diff --git a/solr/core/src/resources/apispec/cluster.security.RuleBasedAuthorization.json b/solr/core/src/resources/apispec/cluster.security.RuleBasedAuthorization.json
index abd9d5c..060b2ad 100644
--- a/solr/core/src/resources/apispec/cluster.security.RuleBasedAuthorization.json
+++ b/solr/core/src/resources/apispec/cluster.security.RuleBasedAuthorization.json
@@ -50,6 +50,13 @@
           "type":"object",
           "additionalProperties":true,
           "description":"The names and values of request parameters. This property can be omitted if all request parameters are allowed, but will restrict access only to the values provided if defined."
+        },
+        "role": {
+          "type": "array",
+          "items": {
+            "type": "string",
+            "description": "The name of the role(s) to give this permission. This name will be used to map user IDs to the role to grant these permissions. The value can be wildcard such as (*), which means that any user is OK, but no user is NOT OK."
+          }
         }
       },
       "required": [
@@ -89,6 +96,13 @@
           "type": "integer",
           "description": "This property allows ordering of permissions. The value for this property is the index of the permission that this new permission should be placed before in security.json."
         },
+        "role": {
+          "type": "array",
+          "items": {
+            "type": "string",
+            "description": "The name of the role(s) to give this permission. This name will be used to map user IDs to the role to grant these permissions. The value can be wildcard such as (*), which means that any user is OK, but no user is NOT OK."
+          }
+        },
         "params": {
           "type": "object",
           "additionalProperties": true,

http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/776eae24/solr/core/src/resources/apispec/cluster.security.authentication.Commands.json
----------------------------------------------------------------------
diff --git a/solr/core/src/resources/apispec/cluster.security.authentication.Commands.json b/solr/core/src/resources/apispec/cluster.security.authentication.Commands.json
index 707ef30..e1f9030 100644
--- a/solr/core/src/resources/apispec/cluster.security.authentication.Commands.json
+++ b/solr/core/src/resources/apispec/cluster.security.authentication.Commands.json
@@ -1,5 +1,6 @@
 {
-  "documentation": "https://cwiki.apache.org",
+  "documentation": "https://cwiki.apache.org/confluence/display/solr/Securing+Solr",
+  "description":"This is a placeholder output when no authentication is configured",
   "methods": [
     "POST"
   ],

http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/776eae24/solr/core/src/resources/apispec/cluster.security.authorization.Commands.json
----------------------------------------------------------------------
diff --git a/solr/core/src/resources/apispec/cluster.security.authorization.Commands.json b/solr/core/src/resources/apispec/cluster.security.authorization.Commands.json
index 40709b0..fe74065 100644
--- a/solr/core/src/resources/apispec/cluster.security.authorization.Commands.json
+++ b/solr/core/src/resources/apispec/cluster.security.authorization.Commands.json
@@ -1,5 +1,6 @@
 {
-  "documentation": "https://cwiki.apache.org",
+  "documentation": "https://cwiki.apache.org/confluence/display/solr/Securing+Solr",
+  "description":"This is a placeholder output when no authorization is configured",
   "methods": [
     "POST"
   ],

http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/776eae24/solr/core/src/resources/apispec/core.config.Commands.json
----------------------------------------------------------------------
diff --git a/solr/core/src/resources/apispec/core.config.Commands.json b/solr/core/src/resources/apispec/core.config.Commands.json
index 0be10d0..6dc8d4a 100644
--- a/solr/core/src/resources/apispec/core.config.Commands.json
+++ b/solr/core/src/resources/apispec/core.config.Commands.json
@@ -65,8 +65,7 @@
         }
       },
       "required": [
-        "name",
-        "class"
+        "name"
       ],
       "additionalProperties": true
     },

http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/776eae24/solr/core/src/resources/apispec/cores.Commands.json
----------------------------------------------------------------------
diff --git a/solr/core/src/resources/apispec/cores.Commands.json b/solr/core/src/resources/apispec/cores.Commands.json
index 1bda490..7b2bcd9 100644
--- a/solr/core/src/resources/apispec/cores.Commands.json
+++ b/solr/core/src/resources/apispec/cores.Commands.json
@@ -62,7 +62,7 @@
         },
         "numShards": {
           "type":"number",
-          "description":"NO:of shards"
+          "description":"number of shards"
         },
         "async": {
           "type": "string",

http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/776eae24/solr/core/src/resources/apispec/cores.core.Commands.json
----------------------------------------------------------------------
diff --git a/solr/core/src/resources/apispec/cores.core.Commands.json b/solr/core/src/resources/apispec/cores.core.Commands.json
index 682a706..ca1fc2e 100644
--- a/solr/core/src/resources/apispec/cores.core.Commands.json
+++ b/solr/core/src/resources/apispec/cores.core.Commands.json
@@ -35,6 +35,10 @@
         "to": {
           "type": "string",
           "description": "The new name"
+        },
+        "async": {
+          "type": "string",
+          "description": "Request ID to track this action which will be processed asynchronously"
         }
       },
       "required": [
@@ -98,17 +102,22 @@
       "description": "Internal API"
     },
     "split": "cores.core.Commands.split",
-    "preprecovery": {
+    "prep-recovery": {
+      "type": "object",
+      "additionalProperties": true,
+      "description": "Internal API"
+    },
+    "request-apply-updates": {
       "type": "object",
       "additionalProperties": true,
       "description": "Internal API"
     },
-    "requestapplyupdates": {
+    "request-sync-shard": {
       "type": "object",
       "additionalProperties": true,
       "description": "Internal API"
     },
-    "requestbufferupdates": {
+    "request-buffer-updates": {
       "type": "object",
       "additionalProperties": true,
       "description": "Internal API"