Search Manager Options REST API
- reference
Overview
The Search Manager Options REST API is provided by the Search service. This API enables you to set Search manager options; in particular, to configure rebalance based on file transfer.
Version information
Version : 7.6
Host information
{scheme}://{host}:{port}
The URL scheme, host, and port are as follows.
Component | Description |
---|---|
scheme |
The URL scheme. Use Values: |
host |
The host name or IP address of a node running the Search Service. Example: |
port |
The Search Service REST port. Use Values: |
Examples on this page
In the HTTP request examples:
-
$HOST
is the host name or IP address of a node running the Search Service. -
$USER
is the user name of an authorized user — see Security. -
$PASSWORD
is the password to connect to Couchbase Server.
Resources
This section describes the operations available with this REST API.
Modify Search Manager Options
PUT /api/managerOptions
Description
Sets Search manager options.
Note that only one setting is available: disableFileTransferRebalance
.
The Search Service automatically partitions its indexes across all Search nodes in the cluster, ensuring optimal distribution, following rebalance.
To achieve this, in versions of Couchbase Server prior to 7.1, by default, partitions needing to be newly created were entirely built, on their newly assigned nodes. In 7.1+, by default, new partitions are created by the transfer of partition files from old nodes to new nodes: this significantly enhances performance. This is an Enterprise-only feature, which requires all Search Service nodes either to be running 7.1 or later; or to be running 7.0.2, with the feature explicitly switched on by means of this endpoint. Note that users of 7.1+ can explicitly switch the feature off by means of this endpoint; in which case partition build is used to establish new partitions, rather than file transfer.
During file transfer, should an unresolvable error occur, file transfer is automatically abandoned, and partition build is used instead.
-
application/json
-
application/json
Parameters
Name | Description | Schema |
---|---|---|
Body |
An object specifying Search manager options. |
Responses
HTTP Code | Description | Schema |
---|---|---|
200 |
The operation was successful. |
|
401 |
Failure to authenticate. The user name or password may be incorrect. |
|
404 |
Object not found. The URL may be incorrectly specified. |
|
405 |
Method not allowed. The method may be incorrectly specified. |
Example HTTP Request
The following example disables the creation of new partitions by means of file transfer.
curl -X PUT http://$HOST:8094/api/managerOptions \
-u $USER:$PASSWORD \
-H "Content-type:application/json" \
-d '{"disableFileTransferRebalance": "true" }'
From this point, Search Service index partitions are built on the new nodes assigned to them during rebalance.
The following example re-enables the creation of new partitions by means of file transfer:
curl -X PUT http://$HOST:8094/api/managerOptions \
-u $USER:$PASSWORD \
-H "Content-type:application/json" \
-d '{"disableFileTransferRebalance": "false" }'
From this point, Search Service index partitions are again created by file transfer, on the new nodes assigned to them during rebalance.
Definitions
This section describes the properties consumed and returned by this REST API.
Options
Property | Schema | |
---|---|---|
disableFileTransferRebalance |
If the value is If the value is Default: |
Boolean |
Security
The Search REST APIs support HTTP basic authentication. Pass your credentials through HTTP headers.
See Also
-
An overview of rebalance for all services is provided at Rebalance.
-
An overview of the REST API for the Search Service is provided at Search API.
-
An architectural summary of the Search Service is provided at Search Service Architecture.