@@ -1405,6 +1405,35 @@ opcounters
1405
1405
1406
1406
.. include:: /includes/extracts/4.2-changes-opcounters-type.rst
1407
1407
1408
+ .. serverstatus:: opcounters.deprecated
1409
+
1410
+ This section only appears in the :method:`db.serverStatus()` output
1411
+ when one of the following, deprecated opcodes has been used:
1412
+
1413
+ .. code-block:: javascript
1414
+
1415
+ "deprecated": {
1416
+ "opQuery": NumberLong(<num>),
1417
+ "opGetMore": NumberLong(<num>),
1418
+ "opKillCursors": NumberLong(<num>),
1419
+ "opDelete": NumberLong(<num>),
1420
+ "opUpdate": NumberLong(<num>),
1421
+ "opInsert": NumberLong(<num>),
1422
+ "total": NumberLong(<num>),
1423
+ }
1424
+
1425
+ These opcodes were deprecated in MongoDB 4.2.15 and support for
1426
+ these opcodes is removed in MongoDB 5.1. Starting in MongoDB 5.1,
1427
+ :binary:`~bin.mongod` refuses requests that use a deprecated
1428
+ opcode and increments the corresponding counter.
1429
+
1430
+ ``OP_QUERY`` is an exception to the general rule.
1431
+ :binary:`~bin.mongod` continues to support ``hello`` and
1432
+ ``isMaster`` requests that use ``OP_QUERY``. :binary:`~bin.mongod`
1433
+ refuses any other ``OP_QUERY`` requests.
1434
+
1435
+ The counters are reset when :binary:`~bin.mongod` starts.
1436
+
1408
1437
.. _server-status-opcountersrepl:
1409
1438
.. _server-status-opcounters-repl:
1410
1439
0 commit comments