diff --git a/source/administration/change-streams-production-recommendations.txt b/source/administration/change-streams-production-recommendations.txt index 161533444e7..f670997f713 100644 --- a/source/administration/change-streams-production-recommendations.txt +++ b/source/administration/change-streams-production-recommendations.txt @@ -83,3 +83,19 @@ From the moment an unsharded collection is sharded until the time the change stream catches up to the first chunk migration, the ``documentKey`` in the change stream notification document only includes the ``_id`` of the document, not the full shard key. + +Indexes and Performance +----------------------- + +Change streams cannot use indexes. MongoDB does not support creating +indexes on the :term:`oplog` collection. Therefore, avoid opening a high +number of :ref:`specifically-targeted ` +change streams as these can impact server performance. + +Change Stream Optimization +~~~~~~~~~~~~~~~~~~~~~~~~~~ + +.. |change-streams| replace:: change streams + +.. include:: /includes/change-streams-optimization.rst + diff --git a/source/changeStreams.txt b/source/changeStreams.txt index a89c048c9cd..ff069505a86 100644 --- a/source/changeStreams.txt +++ b/source/changeStreams.txt @@ -53,8 +53,10 @@ Change streams are available for :doc:`replica sets ` and .. include:: /includes/extracts/changestream-rc-majority-4.2.rst -Watch Collection/Database/Deployment ------------------------------------- +.. _changeStreams-watch-deployment: + +Watch a Collection, Database, or Deployment +------------------------------------------- You can open change streams against: