Request a report on whether or not the database configuration includes index configurations that satisfy all installed query options.
URL Parameters | |
---|---|
format? |
The format of the content returned by by the request, either
xml (default), json , or html . The
format parameter overrides any format specified in the Accept header.
|
Response Headers | |
---|---|
Content-Type |
The MIME type of the content returned in the response body, one of
application/xml , application/json , or
text/html .
|
Upon success, MarkLogic Server responds with status 200 and the index report in the response body.
rest-reader
role, or the
following privilege:
http://marklogic.com/xdmp/privileges/rest-reader
The expected response type can be specified using either the
format
parameter or Accept
header. One or
the other must be supplied. If both are supplied and are different,
the format
parameter takes precedence.
For more details, see Checking Index Availability in the REST Application Developer's Guide.
$ curl --anyauth --user user:password -X GET -H "Accept: application/xml" \ http://localhost:8004/v1/config/indexes ==> MarkLogic server responds with a 200 status and the requested report, as XML. For example, this report shows one missing path range index: <rapi:index-summaries xmlns:rapi="http://marklogic.com/rest-api"> <rapi:index-count>2</rapi:index-count> <rapi:complete>false</rapi:complete> <rapi:index-summary> <rapi:name>/v1/config/query/default</rapi:name> <rapi:complete>true</rapi:complete> </rapi:index-summary> <rapi:index-summary> <rapi:name>/v1/config/query/tuples</rapi:name> <rapi:complete>false</rapi:complete> <range type="xs:string" xmlns="http://marklogic.com/appservices/search"> <path-index>/PLAY/ACT/SCENE/TITLE</path-index> </range> </rapi:index-summary> </rapi:index-summaries>
$ curl --anyauth --user user:password -X GET -H "Accept: application/json" \ http://localhost:8004/v1/config/indexes ==> MarkLogic server responds with a 200 status and the requested report, as JSON. For example, this report shows one missing path range index: { "index-summaries": { "index-summary": [ { "name": "/v1/config/query/default", "complete": "true" }, { "name": "/v1/config/query/tuples", "complete": "false", "range": { "type": "xs:string", "path-index": "/PLAY/ACT/SCENE/TITLE" } } ], "index-count": "2", "complete": "false" } }