-
Notifications
You must be signed in to change notification settings - Fork 332
/
Copy pathrest-compact-post.dita
46 lines (34 loc) · 1.88 KB
/
rest-compact-post.dita
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE reference PUBLIC "-//OASIS//DTD DITA Reference//EN" "reference.dtd">
<reference id="reference_ndm_k2d_sp">
<title>Compacting Buckets</title>
<shortdesc>Bucket compaction is initiated with the <codeph>POST
/pools/default/buckets/[bucket-name]/controller/compactBucket</codeph> HTTP method and
URI.</shortdesc>
<refbody>
<section><title>HTTP method and URI</title>
<p>The following URI paths are for compacting buckets data and indexes and for canceling
bucket compaction.</p>
<codeblock>// Compacting
POST /pools/default/buckets/[bucket-name]/controller/compactBucket
// Cancelling compaction
POST /pools/default/buckets/[bucket-name]/controller/cancelBucketCompaction </codeblock>
<note type="note">Administrative credentials must be provided for the node in the cluster.</note>
</section>
<section><title>Syntax for compaction</title>
<p>To compact data files and indexes associated with a specific bucket, use the following curl request syntax:</p>
<codeblock>curl -i -v -X POST -u [admin]:[password]
http://[localhost]:8091/pools/default/buckets/[bucket-name]/controller/compactBucket</codeblock>
</section>
<section><title>Syntax for cancelling compaction</title>
<p>To stop bucket compaction, use the following curl request syntax:</p>
<codeblock>curl -i -v -X POST -u [admin]:[password]
http://[localhost]:8091/pools/default/buckets/[bucket-name]/controller/cancelBucketCompaction</codeblock>
</section>
<section><title>Example</title>
<p>Curl example for compacting the default bucket:</p>
<codeblock>curl -i -v -X POST -u Administrator:password \
http://10.5.2.54:8091/pools/default/buckets/default/controller/compactBucket </codeblock>
</section>
</refbody>
</reference>