doc-exports/docs/geminidb/api-ref/nosql_05_0100.html
Ru, Li Yi 37b97ffc06 geminidb_api
Reviewed-by: Boka, Ladislav <ladislav.boka@t-systems.com>
Co-authored-by: Ru, Li Yi <liyiru7@huawei.com>
Co-committed-by: Ru, Li Yi <liyiru7@huawei.com>
2024-07-04 11:26:33 +00:00

165 lines
12 KiB
HTML

<a name="nosql_05_0100"></a><a name="nosql_05_0100"></a>
<h1 class="topictitle1">Changing Specifications of an Instance</h1>
<div id="body1624423611115"><div class="section" id="nosql_05_0100__section8244163610118"><h4 class="sectiontitle">Function</h4><p id="nosql_05_0100__p52471436101114">This API is used to change specifications of an instance.</p>
<div class="note" id="nosql_05_0100__note4251636141110"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="nosql_05_0100__p14254153651112">Services will be interrupted for 5 to 10 minutes when you change specifications of an instance. Exercise caution when performing this operation.</p>
</div></div>
</div>
<div class="section" id="nosql_05_0100__section325783601116"><h4 class="sectiontitle">Constraints</h4><p id="nosql_05_0100__p1226813671119">This API supports GeminiDB Cassandra instances.</p>
<p id="nosql_05_0100__p10273336151112">This API can be used to scale up or down specifications of an instance.</p>
<p id="nosql_05_0100__p7275103691115">The new specifications cannot be the same as the original specifications.</p>
<p id="nosql_05_0100__p15277536101111">Specifications can be modified only when the instance status is <strong id="nosql_05_0100__b92928503498">normal</strong>.</p>
<p id="nosql_05_0100__p1327917362116">If specifications cannot meet the requirements for running the instance, the specifications cannot be changed.</p>
</div>
<div class="section" id="nosql_05_0100__section10286143614116"><h4 class="sectiontitle">URI</h4><p id="nosql_05_0100__p12288143601114">PUT https://{Endpoint}/v3/{project_id}/instances/{instance_id}/resize</p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="nosql_05_0100__table16293123616115" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Path parameters</caption><thead align="left"><tr id="nosql_05_0100__row629093618115"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.3.2.5.1.1"><p id="nosql_05_0100__p529419362116">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.3.2.5.1.2"><p id="nosql_05_0100__p1129711363118">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.3.2.5.1.3"><p id="nosql_05_0100__p122991636101116">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.3.3.2.5.1.4"><p id="nosql_05_0100__p630103621111">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="nosql_05_0100__row14290203691116"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.1 "><p id="nosql_05_0100__p530312362110">project_id</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.2 "><p id="nosql_05_0100__p7305123614116">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.3 "><p id="nosql_05_0100__p12307836151116">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.3.2.5.1.4 "><p id="nosql_05_0100__p9310133691114">Project ID of a tenant in a region. To obtain this value, see <a href="nosql_projectid.html">Obtaining a Project ID</a>.</p>
</td>
</tr>
<tr id="nosql_05_0100__row14291036161110"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.1 "><p id="nosql_05_0100__p1312736121117">instance_id</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.2 "><p id="nosql_05_0100__p4314203618118">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.3 "><p id="nosql_05_0100__p13316203621110">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.3.2.5.1.4 "><p id="nosql_05_0100__p18318163611119">Instance ID.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="nosql_05_0100__section7321153631116"><h4 class="sectiontitle">Request Parameters</h4>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="nosql_05_0100__HeaderParameter" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Request header parameters</caption><thead align="left"><tr id="nosql_05_0100__row1232343651113"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.4.2.2.5.1.1"><p id="nosql_05_0100__p4327163620110">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.4.2.2.5.1.2"><p id="nosql_05_0100__p632913631110">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.4.2.2.5.1.3"><p id="nosql_05_0100__p143311036111112">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.4.2.2.5.1.4"><p id="nosql_05_0100__p3334036101111">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="nosql_05_0100__row193233369114"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.2.2.5.1.1 "><p id="nosql_05_0100__p934545617613">X-Auth-Token</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.2.2.5.1.2 "><p id="nosql_05_0100__p233893610119">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.2.2.5.1.3 "><p id="nosql_05_0100__p2340113601120">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.4.2.2.5.1.4 "><p id="nosql_05_0100__p434223615114">User token.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="nosql_05_0100__request_ResizeInstanceRequestBody" frame="border" border="1" rules="all"><caption><b>Table 3 </b>Request body parameters</caption><thead align="left"><tr id="nosql_05_0100__row634483616114"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.4.3.2.5.1.1"><p id="nosql_05_0100__p53481536151110">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.4.3.2.5.1.2"><p id="nosql_05_0100__p123501836151111">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.4.3.2.5.1.3"><p id="nosql_05_0100__p17352173610114">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.4.3.2.5.1.4"><p id="nosql_05_0100__p15354163617111">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="nosql_05_0100__row5344153671120"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.3.2.5.1.1 "><p id="nosql_05_0100__p435613612117">resize</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.3.2.5.1.2 "><p id="nosql_05_0100__p33591336141115">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.3.2.5.1.3 "><p id="nosql_05_0100__p14362103618117"><a href="#nosql_05_0100__request_ResizeInstanceOption">ResizeInstanceOption</a> object</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.4.3.2.5.1.4 "><p id="nosql_05_0100__p9364173601118">Target specification information.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><a name="nosql_05_0100__request_ResizeInstanceOption"></a><a name="request_ResizeInstanceOption"></a><table cellpadding="4" cellspacing="0" summary="" id="nosql_05_0100__request_ResizeInstanceOption" frame="border" border="1" rules="all"><caption><b>Table 4 </b>ResizeInstanceOption</caption><thead align="left"><tr id="nosql_05_0100__row739010363119"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.4.4.2.5.1.1"><p id="nosql_05_0100__p639314367110">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.4.4.2.5.1.2"><p id="nosql_05_0100__p153951736141116">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.4.4.2.5.1.3"><p id="nosql_05_0100__p20398113621114">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.4.4.2.5.1.4"><p id="nosql_05_0100__p54001361110">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="nosql_05_0100__row8390123681115"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.4.2.5.1.1 "><p id="nosql_05_0100__p54021136181116">target_spec_code</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.4.2.5.1.2 "><p id="nosql_05_0100__p1540463671119">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.4.2.5.1.3 "><p id="nosql_05_0100__p124061536171110">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.4.4.2.5.1.4 "><p id="nosql_05_0100__p9408133681116">Target resource specification code.</p>
<p id="nosql_05_0100__p13410836121114">For the code, see the value of response parameter <strong id="nosql_05_0100__b1215994912452">flavors.spec_code</strong> in <a href="nosql_instance_specification.html">Querying Instance Specifications</a>.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="nosql_05_0100__section5413153611119"><h4 class="sectiontitle">Response Parameters</h4><p id="nosql_05_0100__p164151536101110"><strong id="nosql_05_0100__b1432125922120">Status code: 202</strong></p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="nosql_05_0100__response_ResizeInstanceResponseBody" frame="border" border="1" rules="all"><caption><b>Table 5 </b>Response body parameters</caption><thead align="left"><tr id="nosql_05_0100__row1641712362119"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.5.3.2.4.1.1"><p id="nosql_05_0100__p942220365111">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.5.3.2.4.1.2"><p id="nosql_05_0100__p174258368119">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="60%" id="mcps1.3.5.3.2.4.1.3"><p id="nosql_05_0100__p16427133641110">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="nosql_05_0100__row741773661111"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.3.2.4.1.1 "><p id="nosql_05_0100__p842911365111">job_id</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.3.2.4.1.2 "><p id="nosql_05_0100__p1843183611115">String</p>
</td>
<td class="cellrowborder" valign="top" width="60%" headers="mcps1.3.5.3.2.4.1.3 "><p id="nosql_05_0100__p343513363118">Task ID.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="nosql_05_0100__section644416365115"><h4 class="sectiontitle">Example Requests</h4><ul id="nosql_05_0100__ul134475367114"><li id="nosql_05_0100__li1099262253219">URI example<pre class="screen" id="nosql_05_0100__screen19922022103217">PUT https://{Endpoint}/v3/375d8d8fad1f43039e23d3b6c0f60a19/instances/9136fd2a9fcd405ea4674276ce36dae8in06/resize</pre>
</li><li id="nosql_05_0100__li74581936171116">Changing instance specifications to 16 vCPUs | 64 GB<pre class="screen" id="nosql_05_0100__screen3461536141114">{
"resize" : {
"target_spec_code" : "geminidb.cassandra.4xlarge.4"
}
}</pre>
</li></ul>
</div>
<div class="section" id="nosql_05_0100__section14472173641114"><h4 class="sectiontitle">Example Responses</h4><p id="nosql_05_0100__p11474136151119"><strong id="nosql_05_0100__b62175577411">Status code: 202</strong></p>
<p id="nosql_05_0100__p647612364111">Accepted</p>
<pre class="screen" id="nosql_05_0100__screen1047913368112">{
"job_id" : "3711e2ad-5787-49bc-a47f-3f0b066af9f5"
}</pre>
</div>
<div class="section" id="nosql_05_0100__section19107202213585"><h4 class="sectiontitle">Status Codes</h4><p id="nosql_05_0100__listapiversion_p201216122353">For details, see <a href="nosql_status_code.html">Status Codes</a>.</p>
</div>
<div class="section" id="nosql_05_0100__section21121922155813"><h4 class="sectiontitle">Error Codes</h4><p id="nosql_05_0100__listapiversion_p1265915205719">For details, see <a href="nosql_error_code.html">Error Codes</a>.</p>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="topic_300000002.html">Instances</a></div>
</div>
</div>