forked from docs/doc-exports
Reviewed-by: Ziuzko, Alevtina <alevtina.ziuzko@t-systems.com> Co-authored-by: qiujiandong1 <qiujiandong1@huawei.com> Co-committed-by: qiujiandong1 <qiujiandong1@huawei.com>
238 lines
17 KiB
HTML
238 lines
17 KiB
HTML
<a name="ces_03_0071"></a><a name="ces_03_0071"></a>
|
|
|
|
<h1 class="topictitle1">Updating a Resource Group</h1>
|
|
<div id="body1606895824428"><div class="section" id="ces_03_0071__section66578044"><h4 class="sectiontitle">Function</h4><p id="ces_03_0071__p7134161517543">This API is used to update a resource group. You can use resource groups to manage resources by service, and view monitoring and alarm information by group to ease O&M.</p>
|
|
</div>
|
|
<div class="section" id="ces_03_0071__section62331491"><h4 class="sectiontitle">URI</h4><p id="ces_03_0071__p12899174762418">PUT /V1.0/{project_id}/resource-groups/{group_id}</p>
|
|
<ul id="ces_03_0071__ul17767104113451"><li id="ces_03_0071__li137671541194520">Parameter description
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="ces_03_0071__table14767174164512" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="ces_03_0071__row127676417456"><th align="left" class="cellrowborder" valign="top" width="18.488151184881513%" id="mcps1.3.2.3.1.1.2.5.1.1"><p id="ces_03_0071__p676711419453">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="14.308569143085691%" id="mcps1.3.2.3.1.1.2.5.1.2"><p id="ces_03_0071__p1376813412455">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="12.568743125687432%" id="mcps1.3.2.3.1.1.2.5.1.3"><p id="ces_03_0071__p1076844113459">Mandatory</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="54.634536546345366%" id="mcps1.3.2.3.1.1.2.5.1.4"><p id="ces_03_0071__p1376834114454">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="ces_03_0071__row47681941134516"><td class="cellrowborder" valign="top" width="18.488151184881513%" headers="mcps1.3.2.3.1.1.2.5.1.1 "><p id="ces_03_0071__p11768124114515">project_id</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="14.308569143085691%" headers="mcps1.3.2.3.1.1.2.5.1.2 "><p id="ces_03_0071__p576844134515">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="12.568743125687432%" headers="mcps1.3.2.3.1.1.2.5.1.3 "><p id="ces_03_0071__p1376810419457">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="54.634536546345366%" headers="mcps1.3.2.3.1.1.2.5.1.4 "><p id="ces_03_0071__p42316702175455">Specifies the project ID.</p>
|
|
<p id="ces_03_0071__p191415137612">For details about how to obtain the project ID, see <a href="ces_03_0057.html">Obtaining a Project ID</a>.</p>
|
|
<p id="ces_03_0071__en-us_topic_0000001646899046_p18100524114814">Minimum: <strong id="ces_03_0071__b184090594243833">1</strong></p>
|
|
<p id="ces_03_0071__en-us_topic_0000001646899046_p81001524104817">Maximum: <strong id="ces_03_0071__b58968685283241">64</strong></p>
|
|
<p id="ces_03_0071__p4697184133915"><strong id="ces_03_0071__b199574130725038">Regular expression matching</strong>: ^[a-zA-Z0-9-]{1,64}$</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="ces_03_0071__row86091844185519"><td class="cellrowborder" valign="top" width="18.488151184881513%" headers="mcps1.3.2.3.1.1.2.5.1.1 "><p id="ces_03_0071__p661004411554">group_id</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="14.308569143085691%" headers="mcps1.3.2.3.1.1.2.5.1.2 "><p id="ces_03_0071__p6835718554">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="12.568743125687432%" headers="mcps1.3.2.3.1.1.2.5.1.3 "><p id="ces_03_0071__p411001433617">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="54.634536546345366%" headers="mcps1.3.2.3.1.1.2.5.1.4 "><p id="ces_03_0071__p1561017442552">Specifies the resource group ID.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</li><li id="ces_03_0071__li114998310465">Request example<pre class="screen" id="ces_03_0071__screen17642956164510">PUT https://{Cloud Eye endpoint}/V1.0/{project_id}/resource-groups/{group_id}</pre>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="ces_03_0071__section14198712184410"><h4 class="sectiontitle">Request</h4><ul id="ces_03_0071__ul8883693"><li id="ces_03_0071__li4138653192418">Request parameters
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="ces_03_0071__table31681753175455" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Request parameters</caption><thead align="left"><tr id="ces_03_0071__row39882175175455"><th align="left" class="cellrowborder" valign="top" width="18.488151184881513%" id="mcps1.3.3.2.1.1.2.5.1.1"><p id="ces_03_0071__p9230722175455">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="14.308569143085691%" id="mcps1.3.3.2.1.1.2.5.1.2"><p id="ces_03_0071__p13675618230">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="12.568743125687432%" id="mcps1.3.3.2.1.1.2.5.1.3"><p id="ces_03_0071__p9490989175455">Mandatory</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="54.634536546345366%" id="mcps1.3.3.2.1.1.2.5.1.4"><p id="ces_03_0071__p30572649175455">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="ces_03_0071__row1124612531976"><td class="cellrowborder" valign="top" width="18.488151184881513%" headers="mcps1.3.3.2.1.1.2.5.1.1 "><p id="ces_03_0071__p206515579219">group_name</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="14.308569143085691%" headers="mcps1.3.3.2.1.1.2.5.1.2 "><p id="ces_03_0071__p5671562232">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="12.568743125687432%" headers="mcps1.3.3.2.1.1.2.5.1.3 "><p id="ces_03_0071__p106515713215">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="54.634536546345366%" headers="mcps1.3.3.2.1.1.2.5.1.4 "><p id="ces_03_0071__p4651571217">Specifies the resource group name. Enter 1 to 128 characters. Only letters, digits, underscores (_), and hyphens (-) are allowed. Example: <strong id="ces_03_0071__b103321013153617">ResourceGroup-Test01</strong></p>
|
|
</td>
|
|
</tr>
|
|
<tr id="ces_03_0071__row186581855073"><td class="cellrowborder" valign="top" width="18.488151184881513%" headers="mcps1.3.3.2.1.1.2.5.1.1 "><p id="ces_03_0071__p116517574212">resources</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="14.308569143085691%" headers="mcps1.3.3.2.1.1.2.5.1.2 "><p id="ces_03_0071__p66713682311">Array of objects</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="12.568743125687432%" headers="mcps1.3.3.2.1.1.2.5.1.3 "><p id="ces_03_0071__p165896147227">No</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="54.634536546345366%" headers="mcps1.3.3.2.1.1.2.5.1.4 "><p id="ces_03_0071__p1965185716210">Specifies resources in the resource group.</p>
|
|
<p id="ces_03_0071__p172217163400">For details, see <a href="#ces_03_0071__table39152528252">Table 3</a>.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<div class="tablenoborder"><a name="ces_03_0071__table39152528252"></a><a name="table39152528252"></a><table cellpadding="4" cellspacing="0" summary="" id="ces_03_0071__table39152528252" frame="border" border="1" rules="all"><caption><b>Table 3 </b><strong id="ces_03_0071__b378852243616">resources</strong> data structure description</caption><thead align="left"><tr id="ces_03_0071__row12915452182518"><th align="left" class="cellrowborder" valign="top" width="21.14%" id="mcps1.3.3.2.1.2.2.5.1.1"><p id="ces_03_0071__p191575220251">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="12.24%" id="mcps1.3.3.2.1.2.2.5.1.2"><p id="ces_03_0071__p59152524257">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="10.61%" id="mcps1.3.3.2.1.2.2.5.1.3"><p id="ces_03_0071__p552275152618">Mandatory</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="56.010000000000005%" id="mcps1.3.3.2.1.2.2.5.1.4"><p id="ces_03_0071__p1691555282518">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="ces_03_0071__row19158528251"><td class="cellrowborder" valign="top" width="21.14%" headers="mcps1.3.3.2.1.2.2.5.1.1 "><p id="ces_03_0071__p091585242518">namespace</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="12.24%" headers="mcps1.3.3.2.1.2.2.5.1.2 "><p id="ces_03_0071__p2915165219251">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="10.61%" headers="mcps1.3.3.2.1.2.2.5.1.3 "><p id="ces_03_0071__p9522175122612">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="56.010000000000005%" headers="mcps1.3.3.2.1.2.2.5.1.4 "><p id="ces_03_0071__p8915135219253">Specifies the resource namespace. For example, the ECS namespace is <strong id="ces_03_0071__b66811215283">SYS.ECS</strong>. To view the namespace of each service, see <a href="ces_03_0059.html">Services Interconnected with Cloud Eye</a>.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="ces_03_0071__row14915155272515"><td class="cellrowborder" valign="top" width="21.14%" headers="mcps1.3.3.2.1.2.2.5.1.1 "><p id="ces_03_0071__p591515292515">dimensions</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="12.24%" headers="mcps1.3.3.2.1.2.2.5.1.2 "><p id="ces_03_0071__p119159527255">Array of objects</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="10.61%" headers="mcps1.3.3.2.1.2.2.5.1.3 "><p id="ces_03_0071__p8522451122619">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="56.010000000000005%" headers="mcps1.3.3.2.1.2.2.5.1.4 "><p id="ces_03_0071__p5915155216259">Specifies one or more resource dimensions.</p>
|
|
<p id="ces_03_0071__p179532333403">For details, see <a href="#ces_03_0071__table9206172582612">Table 4</a>.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<div class="tablenoborder"><a name="ces_03_0071__table9206172582612"></a><a name="table9206172582612"></a><table cellpadding="4" cellspacing="0" summary="" id="ces_03_0071__table9206172582612" frame="border" border="1" rules="all"><caption><b>Table 4 </b><strong id="ces_03_0071__b6134435143611">dimensions</strong> data structure description</caption><thead align="left"><tr id="ces_03_0071__row42061225192614"><th align="left" class="cellrowborder" valign="top" width="18.990000000000002%" id="mcps1.3.3.2.1.3.2.5.1.1"><p id="ces_03_0071__p19207102512612">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="12.15%" id="mcps1.3.3.2.1.3.2.5.1.2"><p id="ces_03_0071__p15207925122611">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="9.950000000000001%" id="mcps1.3.3.2.1.3.2.5.1.3"><p id="ces_03_0071__p734513133275">Mandatory</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="58.91%" id="mcps1.3.3.2.1.3.2.5.1.4"><p id="ces_03_0071__p62071225102614">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="ces_03_0071__row320782552614"><td class="cellrowborder" valign="top" width="18.990000000000002%" headers="mcps1.3.3.2.1.3.2.5.1.1 "><p id="ces_03_0071__p16207122552613">name</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="12.15%" headers="mcps1.3.3.2.1.3.2.5.1.2 "><p id="ces_03_0071__p6207725112619">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="9.950000000000001%" headers="mcps1.3.3.2.1.3.2.5.1.3 "><p id="ces_03_0071__p234512132274">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="58.91%" headers="mcps1.3.3.2.1.3.2.5.1.4 "><p id="ces_03_0071__p1207102522620">Specifies the resource dimension. For example, the ECS dimension is <strong id="ces_03_0071__b210219316211656">instance_id</strong>. To view the dimension of each resource, see <a href="ces_03_0059.html">Services Interconnected with Cloud Eye</a>.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="ces_03_0071__row52072259269"><td class="cellrowborder" valign="top" width="18.990000000000002%" headers="mcps1.3.3.2.1.3.2.5.1.1 "><p id="ces_03_0071__p8207192512616">value</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="12.15%" headers="mcps1.3.3.2.1.3.2.5.1.2 "><p id="ces_03_0071__p420732512618">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="9.950000000000001%" headers="mcps1.3.3.2.1.3.2.5.1.3 "><p id="ces_03_0071__p63455137277">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="58.91%" headers="mcps1.3.3.2.1.3.2.5.1.4 "><p id="ces_03_0071__p18207132519266">Specifies the resource dimension value, which is the instance ID. Example: <strong id="ces_03_0071__b1867024714361">4270ff17-aba3-4138-89fa-820594c39755</strong></p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</li></ul>
|
|
<ul id="ces_03_0071__ul52541973175457"><li id="ces_03_0071__li41462866">Example request<pre class="screen" id="ces_03_0071__screen19889056194625">{
|
|
"group_name": "Resource-Group-Test01",
|
|
"resources": [
|
|
{
|
|
"namespace": "SYS.ECS",
|
|
"dimensions": [
|
|
{
|
|
"name": "instance_id",
|
|
"value": "063a83da-a2b5-4630-ab6b-9b4fcfc261ea"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"namespace": "SYS.ECS",
|
|
"dimensions": [
|
|
{
|
|
"name": "instance_id",
|
|
"value": "518ace88-abde-46bf-829b-0d1f0f2fb2e9"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"namespace": "SYS.ECS",
|
|
"dimensions": [
|
|
{
|
|
"name": "instance_id",
|
|
"value": "675006b5-477a-4aab-948c-0aa467de9c68"
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}</pre>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="ces_03_0071__section15686020"><h4 class="sectiontitle">Response</h4><p id="ces_03_0071__p1273818545916">None</p>
|
|
</div>
|
|
<div class="section" id="ces_03_0071__section6956456"><h4 class="sectiontitle">Returned Values</h4><ul id="ces_03_0071__ul20226985"><li id="ces_03_0071__li47825138">Normal<p id="ces_03_0071__p27773061"><a name="ces_03_0071__li47825138"></a><a name="li47825138"></a>204</p>
|
|
</li><li id="ces_03_0071__li48630964">Abnormal
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="ces_03_0071__table9852173623812" frame="border" border="1" rules="all"><thead align="left"><tr id="ces_03_0071__row985213612382"><th align="left" class="cellrowborder" valign="top" width="32.1%" id="mcps1.3.5.2.2.1.1.3.1.1"><p id="ces_03_0071__p1849030182924">Returned Value</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="67.9%" id="mcps1.3.5.2.2.1.1.3.1.2"><p id="ces_03_0071__p15553712182924">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="ces_03_0071__row4852193611387"><td class="cellrowborder" valign="top" width="32.1%" headers="mcps1.3.5.2.2.1.1.3.1.1 "><p id="ces_03_0071__p581987519168">400 Bad Request</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="67.9%" headers="mcps1.3.5.2.2.1.1.3.1.2 "><p id="ces_03_0071__p164784039168">Request error.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="ces_03_0071__row188531636193819"><td class="cellrowborder" valign="top" width="32.1%" headers="mcps1.3.5.2.2.1.1.3.1.1 "><p id="ces_03_0071__p2691669168">401 Unauthorized</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="67.9%" headers="mcps1.3.5.2.2.1.1.3.1.2 "><p id="ces_03_0071__p218024949168">The authentication information is not provided or is incorrect.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="ces_03_0071__row118531636123816"><td class="cellrowborder" valign="top" width="32.1%" headers="mcps1.3.5.2.2.1.1.3.1.1 "><p id="ces_03_0071__p563264059168">403 Forbidden</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="67.9%" headers="mcps1.3.5.2.2.1.1.3.1.2 "><p id="ces_03_0071__p661449719168">Access to the requested page is forbidden.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="ces_03_0071__row4853436123812"><td class="cellrowborder" valign="top" width="32.1%" headers="mcps1.3.5.2.2.1.1.3.1.1 "><p id="ces_03_0071__p355199299168">408 Request Timeout</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="67.9%" headers="mcps1.3.5.2.2.1.1.3.1.2 "><p id="ces_03_0071__p585420329168">The request timed out.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="ces_03_0071__row1285303673812"><td class="cellrowborder" valign="top" width="32.1%" headers="mcps1.3.5.2.2.1.1.3.1.1 "><p id="ces_03_0071__p630127129168">429 Too Many Requests</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="67.9%" headers="mcps1.3.5.2.2.1.1.3.1.2 "><p id="ces_03_0071__p37560249168">Concurrent requests are excessive.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="ces_03_0071__row1853336203811"><td class="cellrowborder" valign="top" width="32.1%" headers="mcps1.3.5.2.2.1.1.3.1.1 "><p id="ces_03_0071__p537873819168">500 Internal Server Error</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="67.9%" headers="mcps1.3.5.2.2.1.1.3.1.2 "><p id="ces_03_0071__p618106189168">Failed to complete the request because of an internal service error.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="ces_03_0071__row38537365385"><td class="cellrowborder" valign="top" width="32.1%" headers="mcps1.3.5.2.2.1.1.3.1.1 "><p id="ces_03_0071__p298930079168">503 Service Unavailable</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="67.9%" headers="mcps1.3.5.2.2.1.1.3.1.2 "><p id="ces_03_0071__p54144829168">The service is currently unavailable.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="ces_03_0071__section121612204463"><h4 class="sectiontitle">Error Codes</h4><p id="ces_03_0071__en-us_topic_0171212585_p91851023153416">See <a href="ErrorCode.html">Error Codes</a>.</p>
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<div class="familylinks">
|
|
<div class="parentlink"><strong>Parent topic:</strong> <a href="ces_03_0067.html">Resource Groups</a></div>
|
|
</div>
|
|
</div>
|
|
|