Skip to content

Commit 5e6b21d

Browse files
committed
DOCS-7339: Sharding Reorganization
Stage 1: Moved pages around, nuked old toc files Stage 2: Integrated feedback, major re-writes of content pages Stage 3: Reorg'd the Reorg, added redirects, orphaned stuff
1 parent 81f4a38 commit 5e6b21d

File tree

96 files changed

+3364
-2774
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

96 files changed

+3364
-2774
lines changed

config/htaccess.yaml

Lines changed: 154 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4720,4 +4720,158 @@ type: 'redirect'
47204720
code: 301
47214721
outputs:
47224722
- 'after-v3.0'
4723+
---
4724+
from: '/core/sharding-introduction'
4725+
to: '/sharding'
4726+
type: 'redirect'
4727+
code: 301
4728+
outputs:
4729+
- 'after-v3.0'
4730+
---
4731+
from: '/core/sharding'
4732+
to: '/sharding'
4733+
type: 'redirect'
4734+
code: 301
4735+
outputs:
4736+
- 'after-v3.0'
4737+
---
4738+
from: '/core/sharded-cluster-architectures'
4739+
to: '/core/sharded-cluster-components'
4740+
type: 'redirect'
4741+
code: 301
4742+
outputs:
4743+
- 'after-v3.0'
4744+
---
4745+
from: '/core/sharded-cluster-architectures-production'
4746+
to: '/core/sharded-cluster-components'
4747+
type: 'redirect'
4748+
code: 301
4749+
outputs:
4750+
- 'after-v3.0'
4751+
---
4752+
from: '/core/sharded-cluster-architectures-test'
4753+
to: '/core/sharded-cluster-components'
4754+
type: 'redirect'
4755+
code: 301
4756+
outputs:
4757+
- 'after-v3.0'
4758+
---
4759+
from: '/core/sharded-cluster-operations'
4760+
to: '/sharding'
4761+
type: 'redirect'
4762+
code: 301
4763+
outputs:
4764+
- 'after-v3.0'
4765+
---
4766+
from: '/core/sharded-cluster-mechanics'
4767+
to: '/sharding'
4768+
type: 'redirect'
4769+
code: 301
4770+
outputs:
4771+
- 'after-v3.0'
4772+
---
4773+
from: '/core/sharding-chunk-migration'
4774+
to: '/core/sharding-balancer-administration'
4775+
type: 'redirect'
4776+
code: 301
4777+
outputs:
4778+
- 'after-v3.0'
4779+
---
4780+
from: '/core/sharding-chunk-splitting'
4781+
to: '/core/sharding-data-partitioning'
4782+
type: 'redirect'
4783+
code: 301
4784+
outputs:
4785+
- 'after-v3.0'
4786+
---
4787+
from: '/core/sharding-shard-key-indexes'
4788+
to: '/core/sharding-shard-key'
4789+
type: 'redirect'
4790+
code: 301
4791+
outputs:
4792+
- 'after-v3.0'
4793+
---
4794+
from: '/core/sharded-cluster-metadata'
4795+
to: '/core/sharded-cluster-config-servers'
4796+
type: 'redirect'
4797+
code: 301
4798+
outputs:
4799+
- 'after-v3.0'
4800+
---
4801+
from: '/administration/sharded-clusters'
4802+
to: '/sharding'
4803+
type: 'redirect'
4804+
code: 301
4805+
outputs:
4806+
- 'after-v3.0'
4807+
---
4808+
from: '/administration/sharded-cluster-deployment'
4809+
to: '/tutorial/deploy-shard-cluster'
4810+
type: 'redirect'
4811+
code: 301
4812+
outputs:
4813+
- 'after-v3.0'
4814+
---
4815+
from: '/tutorial/choose-a-shard-key'
4816+
to: '/core/sharding-shard-key'
4817+
type: 'redirect'
4818+
code: 301
4819+
outputs:
4820+
- 'after-v3.0'
4821+
---
4822+
from: '/tutorial/shard-collection-with-a-hashed-shard-key'
4823+
to: '/core/hashed-sharding'
4824+
type: 'redirect'
4825+
code: 301
4826+
outputs:
4827+
- 'after-v3.0'
4828+
---
4829+
from: '/administration/sharded-cluster-maintenance'
4830+
to: '/administration/sharded-cluster-administration'
4831+
type: 'redirect'
4832+
code: 301
4833+
outputs:
4834+
- 'after-v3.0'
4835+
---
4836+
from: '/administration/sharded-cluster-data'
4837+
to: '/administration/sharded-cluster-administration'
4838+
type: 'redirect'
4839+
code: 301
4840+
outputs:
4841+
- 'after-v3.0'
4842+
---
4843+
from: '/administration/sharded-cluster-config-servers'
4844+
to: '/administration/sharded-cluster-maintenance'
4845+
type: 'redirect'
4846+
code: 301
4847+
outputs:
4848+
- 'before-v3.0'
4849+
---
4850+
from: '/core/hashed-sharding'
4851+
to: '/tutorial/shard-collection-with-a-hashed-shard-key'
4852+
type: 'redirect'
4853+
code: 301
4854+
outputs:
4855+
- 'before-v3.0'
4856+
---
4857+
from: '/core/ranged-sharding'
4858+
to: '/sharding'
4859+
type: 'redirect'
4860+
code: 301
4861+
outputs:
4862+
- 'before-v3.0'
4863+
---
4864+
from: '/tutorial/deploy-sharded-cluster-hashed-sharding'
4865+
to: '/tutorial/deploy-shard-cluster'
4866+
type: 'redirect'
4867+
code: 301
4868+
outputs:
4869+
- 'before-v3.0'
4870+
---
4871+
from: '/tutorial/deploy-sharded-cluster-ranged-sharding'
4872+
to: '/tutorial/deploy-shard-cluster'
4873+
type: 'redirect'
4874+
code: 301
4875+
outputs:
4876+
- 'before-v3.0'
47234877
...

config/sphinx_local.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,10 @@ theme:
7070
- /release-notes/3.0
7171
- /release-notes/3.2
7272
- /security
73+
- /sharding
74+
- /core/tag-aware-sharding
75+
- /core/hashed-sharding
76+
- /core/ranged-sharding
7377
- /storage
7478
- /tutorial/change-sharded-cluster-wiredtiger
7579
- /tutorial/query-documents
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
==============================
2+
Sharded Cluster Administration
3+
==============================
4+
5+
.. default-domain:: mongodb
6+
7+
.. contents:: On this page
8+
:local:
9+
:backlinks: none
10+
:depth: 1
11+
:class: singlecol
12+
13+
14+
.. include:: /includes/toc/sharded-cluster-administration.rst
15+
16+
.. include:: /includes/toc/dfn-list-sharded-cluster-administration.rst
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
============================================
2+
Sharded Cluster Config Server Administration
3+
============================================
4+
5+
.. default-domain:: mongodb
6+
7+
.. contents:: On this page
8+
:local:
9+
:backlinks: none
10+
:depth: 1
11+
:class: singlecol
12+
13+
.. include:: /includes/toc/sharded-cluster-config-server-admin.rst
14+
15+
.. include:: /includes/toc/dfn-list-sharded-cluster-config-server-admin.rst
16+
17+
.. seealso:: :doc:`/administration/backup-sharded-clusters`

source/administration/sharded-cluster-data.txt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
:orphan:
2+
13
===============================
24
Sharded Cluster Data Management
35
===============================
@@ -12,6 +14,6 @@ Sharded Cluster Data Management
1214

1315
The following documents provide information in managing data in sharded clusters.
1416

15-
.. include:: /includes/toc/dfn-list-sharded-cluster-data.rst
17+
.. include /includes/toc/dfn-list-sharded-cluster-data.rst
1618

17-
.. include:: /includes/toc/sharded-cluster-data.rst
19+
.. include /includes/toc/sharded-cluster-data.rst

source/administration/sharded-cluster-deployment.txt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
:orphan:
2+
13
====================================
24
Sharded Cluster Deployment Tutorials
35
====================================
@@ -12,6 +14,6 @@ Sharded Cluster Deployment Tutorials
1214

1315
The following tutorials provide information on deploying sharded clusters.
1416

15-
.. include:: /includes/toc/dfn-list-sharded-cluster-deployment.rst
17+
.. include /includes/toc/dfn-list-sharded-cluster-deployment.rst
1618

17-
.. include:: /includes/toc/sharded-cluster-deployment.rst
19+
.. include /includes/toc/sharded-cluster-deployment.rst

source/administration/sharded-cluster-maintenance.txt

Lines changed: 0 additions & 19 deletions
This file was deleted.

source/administration/sharded-clusters.txt

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
.. index:: sharded clusters
2-
.. _sharding-sharded-cluster:
1+
:orphan:
32

43
=========================
54
Sharded Cluster Tutorials
@@ -17,6 +16,9 @@ The following tutorials provide instructions for administering
1716
:term:`sharded clusters <sharded cluster>`. For a higher-level
1817
overview, see :doc:`/sharding`.
1918

20-
.. include:: /includes/toc/dfn-list-spec-sharded-cluster-tutorials-landing.rst
19+
.. TODO -> Remove this page entirely
2120

22-
.. include:: /includes/toc/sharded-cluster-tutorials-landing.rst
21+
22+
.. include /includes/toc/dfn-list-spec-sharded-cluster-tutorials-landing.rst
23+
24+
.. include /includes/toc/sharded-cluster-tutorials-landing.rst

source/core/data-model-operations.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ Sharding
8888

8989
MongoDB uses :term:`sharding` to provide horizontal scaling. These
9090
clusters support deployments with large data sets and high-throughput
91-
operations. Sharding allows users to :term:`partition` a
91+
operations. Sharding allows users to :term:`partition <data partition>` a
9292
:term:`collection` within a database to distribute the collection's
9393
documents across a number of :program:`mongod` instances or
9494
:term:`shards <shard>`.

source/core/gridfs.txt

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -302,3 +302,27 @@ create it using the :program:`mongo` shell:
302302
the context of sharding.
303303

304304
.. _`GridFS specification`: https://github.com/mongodb/specifications/blob/master/source/gridfs/gridfs-spec.rst
305+
306+
Sharding GridFS
307+
---------------
308+
309+
There are two collections to consider with :term:`gridfs` - ``files`` and
310+
``chunks``.
311+
312+
If you need to shard a GridFS data store, use the ``chunks`` collection
313+
setting ``{ files_id : 1, n : 1 }`` or ``{ files_id : 1 }`` as the shard key
314+
index.
315+
316+
``files_id`` is an :term:`objectid` and changes
317+
:ref:`monotonically<shard-key-monotonic>`.
318+
319+
You cannot use :doc:`/core/hashed-sharding` when sharding the ``chunks``
320+
collection.
321+
322+
The ``files`` collection is small and only contains metadata. None of the
323+
required keys for GridfS lend themselves to an even distribution in a
324+
sharded environment. If you *must* shard the ``files`` collection, use the
325+
``_id`` field, possibly in combination with an application field.
326+
327+
Leaving ``files`` unsharded allows all the file metadata documents to live
328+
on the :term:`primary shard`.

0 commit comments

Comments
 (0)