Skip to content

Commit 2176354

Browse files
authored
DOCSP-11156: [mongocli] mongocli atlas clusters onlinearchive describe (#161)
1 parent 166ffcd commit 2176354

File tree

2 files changed

+135
-1
lines changed

2 files changed

+135
-1
lines changed

source/reference/atlas/onlinearchive-commands.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,9 @@ Atlas Online Archive Commands
1313
:titlesonly:
1414

1515
List Online Archives </reference/atlas/onlinearchive-list>
16+
Describe an Online Archive </reference/atlas/onlinearchive-describe>
1617
Create an Online Archive </reference/atlas/onlinearchive-create>
1718
Modify an Online Archive </reference/atlas/onlinearchive-update>
1819
Start an Online Archive </reference/atlas/onlinearchive-start>
1920
Pause an Active Online Archive </reference/atlas/onlinearchive-pause>
20-
21+
Lines changed: 133 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,133 @@
1+
.. _mcli-atlas-cluster-onlinearchive-describe-command:
2+
3+
=============================================
4+
mongocli atlas cluster onlinearchive describe
5+
=============================================
6+
7+
.. default-domain:: mongodb
8+
9+
.. contents:: On this page
10+
:local:
11+
:backlinks: none
12+
:depth: 1
13+
:class: singlecol
14+
15+
.. include:: /includes/fact-online-archive-beta.rst
16+
17+
The ``onlinearchive describe`` command retrieves the configuration of one
18+
:atlas:`online archive </online-archive/manage-online-archive/>` for the
19+
specified cluster. You can also view the configuration of an online archive
20+
through the |service| :atlas:`UI </online-archive/view-online-archives/>` or :atlas:`API
21+
</reference/api/online-archive-get-one/>`.
22+
23+
.. _mcli-atlas-cluster-online-archive-describe-syntax:
24+
25+
Syntax
26+
------
27+
28+
.. code-block:: text
29+
30+
mongocli atlas cluster onlinearchive describe <online-archive-id>
31+
--clusterName <cluster-name>
32+
[ --profile|-P <profile-name> ]
33+
[ --projectId <project-ID> ]
34+
35+
.. _mcli-atlas-cluster-onlinearchive-describe-options:
36+
37+
Options
38+
-------
39+
40+
.. list-table::
41+
:header-rows: 1
42+
:widths: 20 10 60 10
43+
44+
* - Option
45+
- Type
46+
- Description
47+
- Required?
48+
49+
* - ``<online-archive-id>``
50+
- string
51+
- Unique identifier of the online archive to describe.
52+
- yes
53+
54+
* - ``--clusterName``
55+
- string
56+
- Name of the cluster.
57+
- yes
58+
59+
* - ``--profile``, ``-P``
60+
- string
61+
- Name of the profile where the public and private
62+
keys for the project are saved. If omitted, uses the
63+
{+default-profile+}. To learn more about creating a
64+
profile, see :ref:`mcli-configure`.
65+
- no
66+
67+
* - ``--projectId``
68+
- string
69+
- Unique identifier of the project that contains the
70+
cluster. If omitted, uses the project ID in the profile or
71+
:ref:`environment variable <mcli-env-var>`.
72+
- no
73+
74+
.. _mcli-atlas-cluster-onlinearchive-describe-output:
75+
76+
Output
77+
------
78+
79+
.. include:: /includes/command-output-intro.rst
80+
81+
.. include:: /includes/atlas-online-archive-output.rst
82+
83+
.. _mcli-atlas-cluster-onlinearchive-describe-egs:
84+
85+
Example
86+
-------
87+
88+
The following example uses the ``mongocli atlas cluster onlinearchive describe``
89+
command to retrieve the online archives configured for the cluster named
90+
``myTestCluster``. The command uses the {+default-profile+} to access the
91+
project.
92+
93+
.. code-block:: sh
94+
95+
mongocli atlas cluster onlinearchive describe 5f189832e26ec075e10c32d3 --clusterName myTestCluster
96+
97+
The previous command prints the following fields in |json| format to
98+
the terminal. To learn more about these fields, see
99+
:ref:`mcli-atlas-cluster-onlinearchive-describe-output`.
100+
101+
.. code-block:: json
102+
:copyable: false
103+
104+
{
105+
"_id": "5f189832e26ec075e10c32d3",
106+
"clusterName": "myTestCluster",
107+
"collName": "movies",
108+
"criteria": {
109+
"dateField": "released",
110+
"expireAfterDays": 2
111+
},
112+
"dbName": "sample_mflix",
113+
"groupId": "5e2211c17a3e5a48f5497de3",
114+
"partitionFields": [
115+
{
116+
"fieldName": "title",
117+
"fieldType": "string",
118+
"order": 0
119+
},
120+
{
121+
"fieldName": "year",
122+
"fieldType": "int",
123+
"order": 1
124+
},
125+
{
126+
"fieldName": "released",
127+
"fieldType": "date",
128+
"order": 2
129+
}
130+
],
131+
"paused": false,
132+
"state": "ACTIVE"
133+
}

0 commit comments

Comments
 (0)