forked from docs/doc-exports
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>
229 lines
17 KiB
HTML
229 lines
17 KiB
HTML
<a name="nosql_api_0030"></a><a name="nosql_api_0030"></a>
|
|
|
|
<h1 class="topictitle1">Querying an Automated Backup Policy</h1>
|
|
<div id="body8110931164412"><div class="section" id="nosql_api_0030__section1110131104419"><h4 class="sectiontitle">Function</h4><p id="nosql_api_0030__p1511093112448">This API is used to query an automated backup policy.</p>
|
|
</div>
|
|
<div class="section" id="nosql_api_0030__section1239972118494"><h4 class="sectiontitle">Constraints</h4><p id="nosql_api_0030__en-us_topic_0198711248_p3567737111013">This API supports GeminiDB Cassandra instances.</p>
|
|
</div>
|
|
<div class="section" id="nosql_api_0030__section1011883104410"><h4 class="sectiontitle">URI</h4><p id="nosql_api_0030__p13118133110445">GET https://{Endpoint}/v3/{project_id}/instances/{instance_id}/backups/policy</p>
|
|
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="nosql_api_0030__table1712015315449" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Path parameters</caption><thead align="left"><tr id="nosql_api_0030__row151191131174413"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.3.2.5.1.1"><p id="nosql_api_0030__p912023144413">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.3.2.5.1.2"><p id="nosql_api_0030__p31211931124410">Mandatory</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.3.2.5.1.3"><p id="nosql_api_0030__p151211531104415">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.3.3.2.5.1.4"><p id="nosql_api_0030__p412223184413">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="nosql_api_0030__row1111911315442"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.1 "><p id="nosql_api_0030__p111226315442">project_id</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.2 "><p id="nosql_api_0030__p412313194418">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.3 "><p id="nosql_api_0030__p19123123114414">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.3.2.5.1.4 "><p id="nosql_api_0030__p412413154420">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_api_0030__row5119531134419"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.1 "><p id="nosql_api_0030__p41241231154414">instance_id</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.2 "><p id="nosql_api_0030__p16124831194415">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.3 "><p id="nosql_api_0030__p9125931164416">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.3.2.5.1.4 "><p id="nosql_api_0030__p16125163110441">Instance ID.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="nosql_api_0030__table871655832913" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Query parameters</caption><thead align="left"><tr id="nosql_api_0030__row47811583292"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.4.2.5.1.1"><p id="nosql_api_0030__p1178125812291">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.4.2.5.1.2"><p id="nosql_api_0030__p10781205816294">Mandatory</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.4.2.5.1.3"><p id="nosql_api_0030__p378115818296">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.3.4.2.5.1.4"><p id="nosql_api_0030__p147811558182918">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="nosql_api_0030__row1278118587296"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.4.2.5.1.1 "><p id="nosql_api_0030__p878175820299">type</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.4.2.5.1.2 "><p id="nosql_api_0030__p187811158132917">No</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.4.2.5.1.3 "><p id="nosql_api_0030__p4781155832911">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.4.2.5.1.4 "><p id="nosql_api_0030__p207811158102913">Backup policy type. This parameter is available only to <span id="nosql_api_0030__text5778936484">GeminiDB Cassandra</span>. The value can be:</p>
|
|
<ul id="nosql_api_0030__ul14781858152911"><li id="nosql_api_0030__li1578110589296"><strong id="nosql_api_0030__b2079511385346">Instance</strong>, indicating that an instance backup is queried.</li><li id="nosql_api_0030__li1782195812292"><strong id="nosql_api_0030__b12470125514344">DatabaseTable</strong>, indicating that a database or table backup is queried.</li></ul>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<div class="section" id="nosql_api_0030__section191261931184410"><h4 class="sectiontitle">Request Parameters</h4>
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="nosql_api_0030__HeaderParameter" frame="border" border="1" rules="all"><caption><b>Table 3 </b>Request header parameters</caption><thead align="left"><tr id="nosql_api_0030__row131291431134417"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.4.2.2.5.1.1"><p id="nosql_api_0030__p1130331144420">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.4.2.2.5.1.2"><p id="nosql_api_0030__p5130531114415">Mandatory</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.4.2.2.5.1.3"><p id="nosql_api_0030__p513143184411">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.4.2.2.5.1.4"><p id="nosql_api_0030__p113123110442">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="nosql_api_0030__row111291231124413"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.2.2.5.1.1 "><p id="nosql_api_0030__p181329315442">X-Auth-Token</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.2.2.5.1.2 "><p id="nosql_api_0030__p12132183114442">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.2.2.5.1.3 "><p id="nosql_api_0030__p20133531144412">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.4.2.2.5.1.4 "><p id="nosql_api_0030__p11133133104414">User token.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<div class="section" id="nosql_api_0030__section6134031194418"><h4 class="sectiontitle">Response Parameters</h4><p id="nosql_api_0030__p1113413154414"><strong id="nosql_api_0030__b316571597">Status code: 202</strong></p>
|
|
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="nosql_api_0030__response_ShowBackupPolicyResponseBody" frame="border" border="1" rules="all"><caption><b>Table 4 </b>Response body parameters</caption><thead align="left"><tr id="nosql_api_0030__row21351931164410"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.5.3.2.4.1.1"><p id="nosql_api_0030__p10136113116443">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="30%" id="mcps1.3.5.3.2.4.1.2"><p id="nosql_api_0030__p11137203112443">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="50%" id="mcps1.3.5.3.2.4.1.3"><p id="nosql_api_0030__p15137731144413">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="nosql_api_0030__row191354310442"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.3.2.4.1.1 "><p id="nosql_api_0030__p81381231104415">backup_policy</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="30%" headers="mcps1.3.5.3.2.4.1.2 "><p id="nosql_api_0030__p2138103118441">object</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.5.3.2.4.1.3 "><p id="nosql_api_0030__p131397319443">Backup policy objects, including backup retention period (days) and start time For details, see <a href="#nosql_api_0030__response_ShowBackupPolicyResult">Table 5</a>.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="nosql_api_0030__row2124183015313"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.3.2.4.1.1 "><p id="nosql_api_0030__p311203753116">database_tables</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="30%" headers="mcps1.3.5.3.2.4.1.2 "><p id="nosql_api_0030__p13112137153114">Array of objects</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.5.3.2.4.1.3 "><p id="nosql_api_0030__p201121137193111">Database and table information in the backup. This parameter is available only to GeminiDB Cassandra. For details, see <a href="#nosql_api_0030__table52261594347">Table 6</a>.</p>
|
|
<ul id="nosql_api_0030__ul71123379316"><li id="nosql_api_0030__li6112143710319">Keep this parameter empty or ignore it when you query an instance backup.</li><li id="nosql_api_0030__li411213718318">Remember to specify this parameter when you query a database or table backup (if any).</li></ul>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<div class="tablenoborder"><a name="nosql_api_0030__response_ShowBackupPolicyResult"></a><a name="response_ShowBackupPolicyResult"></a><table cellpadding="4" cellspacing="0" summary="" id="nosql_api_0030__response_ShowBackupPolicyResult" frame="border" border="1" rules="all"><caption><b>Table 5 </b>ShowBackupPolicyResult</caption><thead align="left"><tr id="nosql_api_0030__row16139183118446"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.5.4.2.4.1.1"><p id="nosql_api_0030__p1714153124417">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="30%" id="mcps1.3.5.4.2.4.1.2"><p id="nosql_api_0030__p9141031134415">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="50%" id="mcps1.3.5.4.2.4.1.3"><p id="nosql_api_0030__p214283124418">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="nosql_api_0030__row91408310443"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.4.2.4.1.1 "><p id="nosql_api_0030__p1142731134410">keep_days</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="30%" headers="mcps1.3.5.4.2.4.1.2 "><p id="nosql_api_0030__p14143153114448">Integer</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.5.4.2.4.1.3 "><p id="nosql_api_0030__p614303144420">Backup retention days.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="nosql_api_0030__row162441559103016"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.4.2.4.1.1 "><p id="nosql_api_0030__p96399211617">differential_period</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="30%" headers="mcps1.3.5.4.2.4.1.2 "><p id="nosql_api_0030__p1463922151613">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.5.4.2.4.1.3 "><p id="nosql_api_0030__p1863916211163">Differential backup interval. Interval for automatic differential backup. Its value can be <strong id="nosql_api_0030__b11395121074719">30</strong>, <strong id="nosql_api_0030__b18395910164714">60</strong>, <strong id="nosql_api_0030__b18395310114716">180</strong>, <strong id="nosql_api_0030__b3396141074712">360</strong>, <strong id="nosql_api_0030__b14396141024718">720</strong>, or <strong id="nosql_api_0030__b93961310204716">1440</strong>. The unit is minute. If the value is <strong id="nosql_api_0030__b73191713133416">0</strong>, differential backup is disabled. Differential backup works based on incremental backup, and differential backup interval must be longer than incremental backup interval.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="nosql_api_0030__row34971727314"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.4.2.4.1.1 "><p id="nosql_api_0030__p106391721163">incremental_period</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="30%" headers="mcps1.3.5.4.2.4.1.2 "><p id="nosql_api_0030__p166395281610">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.5.4.2.4.1.3 "><p id="nosql_api_0030__p2063916251611">Incremental backup interval, in minutes. If the value is <strong id="nosql_api_0030__b1719518390405">0</strong>, incremental backup is disabled.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="nosql_api_0030__row9140133112449"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.4.2.4.1.1 "><p id="nosql_api_0030__p131459311442">start_time</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="30%" headers="mcps1.3.5.4.2.4.1.2 "><p id="nosql_api_0030__p13145123194411">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.5.4.2.4.1.3 "><p id="nosql_api_0030__p1114653174416">Backup time window. Automated backup will be triggered during the backup time window.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="nosql_api_0030__row14140183114416"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.4.2.4.1.1 "><p id="nosql_api_0030__p71471431144415">period</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="30%" headers="mcps1.3.5.4.2.4.1.2 "><p id="nosql_api_0030__p7147193119447">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50%" headers="mcps1.3.5.4.2.4.1.3 "><p id="nosql_api_0030__p131478311444">Backup period. After a backup period is specified, data will be automatically backed up on the selected days every week.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<div class="tablenoborder"><a name="nosql_api_0030__table52261594347"></a><a name="table52261594347"></a><table cellpadding="4" cellspacing="0" summary="" id="nosql_api_0030__table52261594347" frame="border" border="1" rules="all"><caption><b>Table 6 </b>QueryDatabaseTableInfo</caption><thead align="left"><tr id="nosql_api_0030__row16295105910349"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.5.5.2.4.1.1"><p id="nosql_api_0030__p10295159153415">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="29.81%" id="mcps1.3.5.5.2.4.1.2"><p id="nosql_api_0030__p529505914340">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="50.19%" id="mcps1.3.5.5.2.4.1.3"><p id="nosql_api_0030__p8295165912342">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="nosql_api_0030__row6295859173416"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.5.2.4.1.1 "><p id="nosql_api_0030__p4295115916345">database_name</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="29.81%" headers="mcps1.3.5.5.2.4.1.2 "><p id="nosql_api_0030__p22951959163414">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50.19%" headers="mcps1.3.5.5.2.4.1.3 "><p id="nosql_api_0030__p4295195923417">Database name.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="nosql_api_0030__row152952591340"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.5.2.4.1.1 "><p id="nosql_api_0030__p1429565916345">table_names</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="29.81%" headers="mcps1.3.5.5.2.4.1.2 "><p id="nosql_api_0030__p1329555953414">Array of strings</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50.19%" headers="mcps1.3.5.5.2.4.1.3 "><p id="nosql_api_0030__p3296359153411">Table names.</p>
|
|
<ul id="nosql_api_0030__ul8296135923417"><li id="nosql_api_0030__li22961759123417">If this parameter is empty, database names are queried.</li><li id="nosql_api_0030__li4296115913416">If this parameter is not empty, table names are queried.</li></ul>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<div class="section" id="nosql_api_0030__section514819315445"><h4 class="sectiontitle">Example Requests</h4><div class="p" id="nosql_api_0030__p10888115813255">URI example<pre class="screen" id="nosql_api_0030__screen18653184385112">GET https://{Endpoint}/v3/375d8d8fad1f43039e23d3b6c0f60a19/instances/9136fd2a9fcd405ea4674276ce36dae8in02/backups/policy?type=Instance</pre>
|
|
</div>
|
|
</div>
|
|
<div class="section" id="nosql_api_0030__section1115173118442"><h4 class="sectiontitle">Example Responses</h4><p id="nosql_api_0030__p015123112449"><strong id="nosql_api_0030__b81892091">Status code: 202</strong></p>
|
|
<p id="nosql_api_0030__p10151123120442">Success</p>
|
|
<p id="nosql_api_0030__p1577413414449">Response when an automated backup policy is enabled</p>
|
|
<pre class="screen" id="nosql_api_0030__screen13152163174419">{
|
|
"backup_policy" : {
|
|
"keep_days" : 7,
|
|
"start_time" : "19:00-20:00",
|
|
"period" : "1,2,4,5,6",
|
|
"incremental_period": "0",
|
|
"differential_period": "0"
|
|
},
|
|
"database_tables" : [ {
|
|
"database_name" : "databaseNameA",
|
|
"table_names" : [ "table_A", "table_B" ]
|
|
}, {
|
|
"database_name" : "databaseNameB",
|
|
"table_names" : null
|
|
} ]
|
|
}</pre>
|
|
<p id="nosql_api_0030__p2317417134618">Response when an automated backup policy is disabled</p>
|
|
<pre class="screen" id="nosql_api_0030__screen61551431174414"></pre>
|
|
</div>
|
|
<div class="section" id="nosql_api_0030__section19107202213585"><h4 class="sectiontitle">Status Codes</h4><p id="nosql_api_0030__listapiversion_p201216122353">For details, see <a href="nosql_status_code.html">Status Codes</a>.</p>
|
|
</div>
|
|
<div class="section" id="nosql_api_0030__section21121922155813"><h4 class="sectiontitle">Error Codes</h4><p id="nosql_api_0030__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_300000003.html">Backups and Restorations</a></div>
|
|
</div>
|
|
</div>
|
|
|