@@ -8,12 +8,6 @@ Manage Namespace Metadata Catalog for Wildcard Collections
88
99.. include:: /includes/fact-data-lake-beta.rst
1010
11- .. contents:: On this page
12- :local:
13- :backlinks: none
14- :depth: 2
15- :class: singlecol
16-
1711The {+data-lake+} namespace catalog contains namespace metadata
1812(such as databases, collections, and partitions) for each wildcard (``*``)
1913collection in each {+data-lake-store+} in the {+data-lake-short+} storage
@@ -31,179 +25,10 @@ refreshed in the background when you:
3125- :ref:`Update the storage configuration <datalake-setstorageconfig>`.
3226- Run the ``show collections`` command.
3327- Query a collection.
34- - Run the :ref:`adl- updateCatalog-cmd` command.
28+ - Run the :ref:`updateCatalog-cmd` command.
3529
3630You can determine when the catalog was last updated by using the
37- :ref:`adl-catalogInfo-cmd` command and can manually update the catalog
38- by using the :ref:`adl-updateCatalog-cmd` command. You must have the
39- :authrole:`atlasAdmin` role to update the catalog.
40-
41- .. _adl-catalogInfo-cmd:
42-
43- ``catalogInfo``
44- ---------------
45-
46- The ``catalogInfo`` command returns an array of the stores and the
47- :manual:`ISODate </reference/glossary/#term-isodate>` when the
48- namespace metadata in the catalog was last updated.
49-
50- .. _adl-catalogInfo-cmd-syntax:
51-
52- Syntax
53- ~~~~~~
54-
55- .. code-block:: text
56-
57- db.runCommand({ "catalogInfo" : 1, "stores": ["<storeName>"] })
58-
59- .. _adl-catalogInfo-cmd-usage:
60-
61- Usage
62- ~~~~~
63-
64- To retrieve the last updated timestamp for all the stores, run the
65- following command:
66-
67- .. code-block:: text
68-
69- db.runCommand({ "catalogInfo" : 1 })
70-
71- To retrieve the last updated timestamp for a specific store, run
72- the following command:
73-
74- .. code-block:: text
75-
76- db.runCommand({ "catalogInfo" : 1, "stores": ["<storeName>"] })
77-
78- To retrieve the last updated timestamp for a list of stores, run
79- the following command:
80-
81- .. code-block:: text
82-
83- db.runCommand({ "catalogInfo" : 1, "stores": ["<storeName>",...] })
84-
85- .. _adl-catalogInfo-cmd-output:
86-
87- Output
88- ~~~~~~
89-
90- The command returns output similar to the following if the command
91- succeeds:
92-
93- .. code-block:: json
94- :copyable: false
95-
96- {
97- "ok" : 1,
98- "stores" : [
99- {
100- "<storeName>" : ISODate("<date>")
101- }
102- ]
103- }
104-
105- where:
106-
107- - ``storeName`` is the name of the |s3| store
108- - ``date`` is the date and timestamp in :manual:`ISODate
109- </reference/glossary/#term-isodate>` format
110-
111- .. _adl-catalogInfo-cmd-eg:
112-
113- Example
114- ~~~~~~~
115-
116- The following command returns the last updated date and timestamp for
117- all the stores.
118-
119- .. code-block:: json
120-
121- db.runCommand({"catalogInfo":1})
122-
123- The previous command returns the following output:
124-
125- .. code-block:: json
126- :copyable: false
127-
128- {
129- "ok" : 1,
130- "stores" : [
131- {
132- "s3store" : ISODate("2020-03-25T12:35:32.165Z")
133- },
134- {
135- "egS3Store" : ISODate("2020-03-25T12:35:32.165Z")
136- }
137- ]
138- }
139-
140- .. _adl-updateCatalog-cmd:
141-
142- ``updateCatalog``
143- -----------------
144-
145- The ``updateCatalog`` command updates the namespace metadata in the
146- catalog. You can verify by running the :ref:`adl-catalogInfo-cmd` command,
147- which shows the :manual:`ISODate </reference/glossary/#term-isodate>` when the
148- catalog was last updated. If you have a large {+data-lake-store+}, it may take
149- a while to update the catalog.
150-
151- .. _adl-updateCatalog-cmd-syntax:
152-
153- Syntax
154- ~~~~~~
155-
156- .. code-block:: text
157-
158- db.runCommand({ "updateCatalog" : 1, "background" : true })
159-
160- .. _adl-updateCatalog-cmd-usage:
161-
162- Usage
163- ~~~~~
164-
165- To update the catalog, run the following command:
166-
167- .. code-block:: text
168-
169- db.runCommand({ "updateCatalog" : 1 })
170-
171- The previous command runs in the foreground and is similar to running
172- the command with ``background`` set to ``false``.
173-
174- To update the catalog in the background, run the following command:
175-
176- .. code-block:: text
177-
178- db.runCommand({ "updateCatalog" : 1, "background" : true })
179-
180- .. _adl-updateCatalog-cmd-output:
181-
182- Output
183- ~~~~~~
184-
185- The command returns the following output:
186-
187- .. code-block:: json
188- :copyable: false
189-
190- { "ok" : 1 }
191-
192- .. _adl-updateCatalog-cmd-eg:
193-
194- Example
195- ~~~~~~~
196-
197- The following command updates the namespace metadata in the catalog:
198-
199- .. code-block:: json
200-
201- db.runCommand({ "updateCatalog" : 1 })
202-
203- The previous command returns the following output:
204-
205- .. code-block:: json
206- :copyable: false
207-
208- { "ok" : 1 }
209-
31+ :ref:`catalogInfo-cmd` command and can manually update the catalog
32+ by using the :ref:`updateCatalog-cmd` command. You must have the
33+ :atlas:`atlasAdmin <security-add-mongodb-users/#atlasAdmin>` role
34+ to update the catalog.
0 commit comments