1
0
forked from docs/doc-exports
doc-exports/docs/css/api-ref/css_03_0102.html
Zheng, Xiu bf0cbd66f9 CSS API 22.4.1 Version
Reviewed-by: Kacur, Michal <michal.kacur@t-systems.com>
Co-authored-by: Zheng, Xiu <zhengxiu@huawei.com>
Co-committed-by: Zheng, Xiu <zhengxiu@huawei.com>
2023-04-12 00:11:02 +00:00

193 lines
13 KiB
HTML

<a name="css_03_0102"></a><a name="css_03_0102"></a>
<h1 class="topictitle1">Searching for Logs</h1>
<div id="body0000001475869470"><div class="section" id="css_03_0102__section356534075515"><h4 class="sectiontitle">Function</h4><p id="css_03_0102__p9565164014559">This API is used to query log information.</p>
</div>
<p id="css_03_0102__p4566144005517"></p>
<div class="section" id="css_03_0102__section6567174010558"><h4 class="sectiontitle">URI</h4><p id="css_03_0102__p145677404552">POST /v1.0/{project_id}/clusters/{cluster_id}/logs/search</p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="css_03_0102__table9568134045511" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Path Parameters</caption><thead align="left"><tr id="css_03_0102__row7568940135515"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.3.2.5.1.1"><p id="css_03_0102__p156964035512">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.3.2.5.1.2"><p id="css_03_0102__p1556910407554">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.3.3.2.5.1.3"><p id="css_03_0102__p14569184045517">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.3.3.2.5.1.4"><p id="css_03_0102__p957374015510">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="css_03_0102__row65681440125520"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.1 "><p id="css_03_0102__p957394012557">project_id</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.2 "><p id="css_03_0102__p25741340145511">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.3 "><p id="css_03_0102__p1757444005514">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.3.2.5.1.4 "><p id="css_03_0102__p65756405553">Project ID. For details, see <a href="css_03_0071.html">Obtaining a Project ID and Name</a>.</p>
</td>
</tr>
<tr id="css_03_0102__row125682405552"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.1 "><p id="css_03_0102__p17576184085519">cluster_id</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.2 "><p id="css_03_0102__p17576440145514">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.3.3.2.5.1.3 "><p id="css_03_0102__p105772409553">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.3.3.2.5.1.4 "><p id="css_03_0102__p55781140155520">ID of the cluster you want to query.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="css_03_0102__section14579140145516"><h4 class="sectiontitle">Request Parameters</h4>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="css_03_0102__request_GetLogBackupReq" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Request body parameters</caption><thead align="left"><tr id="css_03_0102__row05802409551"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.4.2.2.5.1.1"><p id="css_03_0102__p7582184019550">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.4.2.2.5.1.2"><p id="css_03_0102__p4582104018552">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.4.2.2.5.1.3"><p id="css_03_0102__p1258315407553">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="40%" id="mcps1.3.4.2.2.5.1.4"><p id="css_03_0102__p758314408559">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="css_03_0102__row7580240195510"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.2.2.5.1.1 "><p id="css_03_0102__p165841040165511">instanceName</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.2.2.5.1.2 "><p id="css_03_0102__p7584204017556">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.2.2.5.1.3 "><p id="css_03_0102__p258516405553">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.4.2.2.5.1.4 "><p id="css_03_0102__p4585104020556">Node name.</p>
</td>
</tr>
<tr id="css_03_0102__row2580240155511"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.2.2.5.1.1 "><p id="css_03_0102__p135863409550">level</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.2.2.5.1.2 "><p id="css_03_0102__p13586114075512">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.2.2.5.1.3 "><p id="css_03_0102__p558712408553">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.4.2.2.5.1.4 "><p id="css_03_0102__p165871740175519">Log level. The levels of logs that can be queried are <strong id="css_03_0102__b858854095519">INFO</strong>, <strong id="css_03_0102__b7588124025511">ERROR</strong>, <strong id="css_03_0102__b1858834095510">DEBUG</strong>, and <strong id="css_03_0102__b158834013554">WARN</strong>.</p>
</td>
</tr>
<tr id="css_03_0102__row2581154015514"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.2.2.5.1.1 "><p id="css_03_0102__p1858894016555">logType</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.2.2.5.1.2 "><p id="css_03_0102__p1958874019553">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.4.2.2.5.1.3 "><p id="css_03_0102__p12589144075511">String</p>
</td>
<td class="cellrowborder" valign="top" width="40%" headers="mcps1.3.4.2.2.5.1.4 "><p id="css_03_0102__p11589134085515">Log type. The types of logs that can be queried are <strong id="css_03_0102__b85893407558">deprecation</strong>, <strong id="css_03_0102__b35891540195518">indexingSlow</strong>, <strong id="css_03_0102__b75891040135512">searchSlow</strong>, and <strong id="css_03_0102__b155891740105512">instance</strong>.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="css_03_0102__section17590184013555"><h4 class="sectiontitle">Response Parameters</h4><p id="css_03_0102__p559018408557"><strong id="css_03_0102__b1659016407554">Status code: 200</strong></p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="css_03_0102__response_GetLogBackupResponseBody" frame="border" border="1" rules="all"><caption><b>Table 3 </b>Response body parameters</caption><thead align="left"><tr id="css_03_0102__row9591184015552"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.5.3.2.4.1.1"><p id="css_03_0102__p75932404558">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.5.3.2.4.1.2"><p id="css_03_0102__p3593184011558">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="60%" id="mcps1.3.5.3.2.4.1.3"><p id="css_03_0102__p95941640205515">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="css_03_0102__row135911340195519"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.3.2.4.1.1 "><p id="css_03_0102__p19597174012556">logList</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.3.2.4.1.2 "><p id="css_03_0102__p1259819407558">Array of <a href="#css_03_0102__response_logList">logList</a> objects</p>
</td>
<td class="cellrowborder" valign="top" width="60%" headers="mcps1.3.5.3.2.4.1.3 "><p id="css_03_0102__p05981640115510">Log list.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><a name="css_03_0102__response_logList"></a><a name="response_logList"></a><table cellpadding="4" cellspacing="0" summary="" id="css_03_0102__response_logList" frame="border" border="1" rules="all"><caption><b>Table 4 </b>logList</caption><thead align="left"><tr id="css_03_0102__row165991440165514"><th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.5.4.2.4.1.1"><p id="css_03_0102__p116019404555">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="20%" id="mcps1.3.5.4.2.4.1.2"><p id="css_03_0102__p860212405550">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="60%" id="mcps1.3.5.4.2.4.1.3"><p id="css_03_0102__p186021340205517">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="css_03_0102__row1259934015512"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.4.2.4.1.1 "><p id="css_03_0102__p8602104035517">content</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.4.2.4.1.2 "><p id="css_03_0102__p960316402556">String</p>
</td>
<td class="cellrowborder" valign="top" width="60%" headers="mcps1.3.5.4.2.4.1.3 "><p id="css_03_0102__p1460414401558">Log content.</p>
</td>
</tr>
<tr id="css_03_0102__row4599154018550"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.4.2.4.1.1 "><p id="css_03_0102__p660410409551">date</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.4.2.4.1.2 "><p id="css_03_0102__p36051440125514">String</p>
</td>
<td class="cellrowborder" valign="top" width="60%" headers="mcps1.3.5.4.2.4.1.3 "><p id="css_03_0102__p14605184015517">Date.</p>
</td>
</tr>
<tr id="css_03_0102__row10599740145514"><td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.4.2.4.1.1 "><p id="css_03_0102__p9606104013551">level</p>
</td>
<td class="cellrowborder" valign="top" width="20%" headers="mcps1.3.5.4.2.4.1.2 "><p id="css_03_0102__p56061440175511">String</p>
</td>
<td class="cellrowborder" valign="top" width="60%" headers="mcps1.3.5.4.2.4.1.3 "><p id="css_03_0102__p186061540165514">Log level.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="css_03_0102__section560616407554"><h4 class="sectiontitle">Example Requests</h4><pre class="screen" id="css_03_0102__screen1160713407559">{
"instanceName" : "css-4312-ess-esn-1-1",
"level" : "INFO",
"logType" : "instance"
}</pre>
</div>
<div class="section" id="css_03_0102__section960818404559"><h4 class="sectiontitle">Example Responses</h4><p id="css_03_0102__p86087400552"><strong id="css_03_0102__b136081040135511">Status code: 200</strong></p>
<p id="css_03_0102__p860915409554">Request succeeded.</p>
<pre class="screen" id="css_03_0102__screen14609440165516">{
"logList" : [ {
"content" : "xxxxxx",
"date" : "2021-10-08T03:55:54,718",
"level" : "INFO"
} ]
}</pre>
</div>
<div class="section" id="css_03_0102__section56101240125517"><h4 class="sectiontitle">Status Codes</h4>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="css_03_0102__status_code" frame="border" border="1" rules="all"><thead align="left"><tr id="css_03_0102__row1561174045516"><th align="left" class="cellrowborder" valign="top" width="15%" id="mcps1.3.8.2.1.3.1.1"><p id="css_03_0102__p6612154019559">Status Code</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="85%" id="mcps1.3.8.2.1.3.1.2"><p id="css_03_0102__p56130404557">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="css_03_0102__row16611194065510"><td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.8.2.1.3.1.1 "><p id="css_03_0102__p1613144016554">200</p>
</td>
<td class="cellrowborder" valign="top" width="85%" headers="mcps1.3.8.2.1.3.1.2 "><p id="css_03_0102__p1761312402555">Request succeeded.</p>
</td>
</tr>
<tr id="css_03_0102__row146121340185516"><td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.8.2.1.3.1.1 "><p id="css_03_0102__p761334020558">400</p>
</td>
<td class="cellrowborder" valign="top" width="85%" headers="mcps1.3.8.2.1.3.1.2 "><p id="css_03_0102__p17614104016551">Invalid request.</p>
<p id="css_03_0102__p17614174055513">Modify the request before retry.</p>
</td>
</tr>
<tr id="css_03_0102__row561244045515"><td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.8.2.1.3.1.1 "><p id="css_03_0102__p196141640185513">409</p>
</td>
<td class="cellrowborder" valign="top" width="85%" headers="mcps1.3.8.2.1.3.1.2 "><p id="css_03_0102__p4615164016550">The request could not be completed due to a conflict with the current state of the resource.</p>
<p id="css_03_0102__p8615134095514">The resource that the client attempts to create already exists, or the update request fails to be processed because of a conflict.</p>
</td>
</tr>
<tr id="css_03_0102__row961254025518"><td class="cellrowborder" valign="top" width="15%" headers="mcps1.3.8.2.1.3.1.1 "><p id="css_03_0102__p11615940195517">412</p>
</td>
<td class="cellrowborder" valign="top" width="85%" headers="mcps1.3.8.2.1.3.1.2 "><p id="css_03_0102__p13616174085517">The server did not meet one of the preconditions contained in the request.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="css_03_0093.html">Log Management</a></div>
</div>
</div>