8000 Java 4.9 whats new (#329) · nickldp/docs-kotlin@1db563c · GitHub
[go: up one dir, main page]

Skip to content

Commit 1db563c

Browse files
author
Chris Cho
authored
Java 4.9 whats new (#329)
* DOCSP-27978: added exception for BsonCreator constructor * DOCSP-27417: Command monitoring log format change
1 parent 3825a4c commit 1db563c

File tree

3 files changed

+23
-11
lines changed

3 files changed

+23
-11
lines changed

source/fundamentals/logging.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -133,9 +133,9 @@ tab corresponding to the logging framework you would like to use in your project
133133
:copyable: false
134134

135135
...
136-
16:03:59.468 [main] DEBUG org.mongodb.driver.connection - Opened connection [connectionId{localValue:7, serverValue:<server value>}] to <connection uri>
137-
16:03:59.483 [main] DEBUG org.mongodb.driver.protocol.command - Sending command '{"find": "<my collection>", "filter": {}, "limit": 1, "singleBatch": true, "$db": "<my database>", "lsid": {"id": {"$binary": {"base64": "<_id>", "subType": "04"}}}}' with request id 13 to database <my database> on connection [connectionId{localValue:7, serverValue:<server value>}] to server <connection uri>
138-
16:03:59.502 [main] DEBUG org.mongodb.driver.protocol.command - Execution of command with request id 13 completed successfully in 27.79 ms on connection [connectionId{localValue:7, serverValue:<server value>}] to server <connection uri>
136+
12:14:55.853 [main] DEBUG org.mongodb.driver.connection - Opened connection [connectionId{localValue:3, serverValue:3}] to <MongoDB hostname>
137+
12:14:55.861 [main] DEBUG org.mongodb.driver.protocol.command - Command "find" started on database <database> using a connection with driver-generated ID 3 and server-generated ID 3 to <MongoDB hostname>. The request ID is 5. Command: {"find": "<collection>", "filter": {}, "limit": 1, "singleBatch": true, "$db": "<database>", "lsid": {"id": {"$binary": {"base64": "<_id>", "subType": "04"}}}, "$readPreference": {"mode": "primaryPreferred"}}
138+
12:14:55.864 [main] DEBUG org.mongodb.driver.protocol.command - Command "find" succeeded in 4.34 ms using a connection with driver-generated ID 3 and server-generated ID 3 to <MongoDB hostname. The request ID is 5. Command reply: {"cursor": {"id": 0, "ns": "<database>.<collection>", "firstBatch": []}, "ok": 1.0, "$clusterTime": {"clusterTime": {"$timestamp": {"t": 1673778535, "i": 1}}, "signature": {"hash": {"$binary": {"base64": "<_id>", "subType": "00"}}, "keyId": 0}}, "operationTime": {"$timestamp": {"t": 1673778535, "i": 1}}}
139139

140140
.. note:: Default Log Level
141141

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
.. code-block:: java
22
3-
MongoClient mongoClient = MongoClients.create(<my uri>);
4-
MongoDatabase database = mongoClient.getDatabase(<my database>);
5-
MongoCollection<Document> collection = database.getCollection(<my collection>);
3+
MongoClient mongoClient = MongoClients.create(<connection uri>);
4+
MongoDatabase database = mongoClient.getDatabase(<database>);
5+
MongoCollection<Document> collection = database.getCollection(<collection>);
66
collection.find().first();

source/whats-new.txt

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ What's New
1313
Learn what's new in:
1414

1515

16+
* :ref:`Version 4.9 <version-4.9>`
1617
* :ref:`Version 4.8 <version-4.8>`
1718
* :ref:`Version 4.7.1 <version-4.7.1>`
1819
* :ref:`Version 4.7.0 <version-4.7.0>`
@@ -26,10 +27,21 @@ Learn what's new in:
2627

2728
.. _upcoming-breaking-changes:
2829

30+
.. _version-4.9:
31+
32+
What's New in 4.9
33+
-----------------
34+
35+
- Added a new exception to identify when a constructor annotated by
36+
``BsonCreator`` contains parameters with annotations other than
37+
``BsonProperty`` or ``BsonId``.
38+
- Changed the log message format for command monitoring messages reported
39+
by the ``org.mongodb.driver.protocol.command`` package.
40+
2941
.. _version-4.8:
3042

3143
What's New in 4.8
32-
-------------------
44+
-----------------
3345

3446
- The 4.8 driver ends support for MongoDB v3.4 and earlier. To learn
3547
more about breaking changes in this driver version and how to address
@@ -43,10 +55,10 @@ What's New in 4.8
4355

4456
.. important:: Deprecation Notice
4557

46-
The ``IterableCodec`` and ``MapCodec`` classes are deprecated. Instead,
47-
use ``CollectionCodec`` and ``MapCodecV2``.
48-
These support any class that implements ``Collection`` or
49-
``Map``.
58+
The ``IterableCodec`` and ``MapCodec`` classes are deprecated. Instead,
59+
use ``CollectionCodec`` and ``MapCodecV2``.
60+
These support any class that implements ``Collection`` or
61+
``Map``.
5062

5163
Behavioral changes with the 4.8 driver release include:
5264

0 commit comments

Comments
 (0)
0