[JAVA-5036] Mark bson-kotlin(x) libraries as optional in the pom Created: 22/Jun/23  Updated: 28/Oct/23  Resolved: 23/Jun/23

Status: Closed
Project: Java Driver
Component/s: Build
Affects Version/s: None
Fix Version/s: 4.10.1

Type: Improvement Priority: Unknown
Reporter: Ross Lawley Assignee: Ross Lawley
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Documented
Documentation Changes: Needed
Documentation Changes Summary:

bson-kotlinx is an explicit dependency and required for when using kotlinx-serialization:

Add: implementation("org.mongodb:bson-kotlinx:4.10.0")

To: https://www.mongodb.com/docs/drivers/kotlin/coroutine/current/fundamentals/data-formats/serialization/#add-kotlin-serialization-to-your-project


 Description   

Currently, their scope is runtime but they should also be marked as optional



 Comments   
Comment by Githook User [ 23/Jun/23 ]

Author:

{'name': 'Ross Lawley', 'email': 'ross@mongodb.com', 'username': 'rozza'}

Message: Build: Make bson-kotlin and bson-kotlinx optional (#1148)

Reduce the dependency tree for driver-core by making the
kotlin dependencies optional.

Kotlin-coroutine and Kotlin-sync now take a hard dependency
on bson-kotlin. So they will work out the box. Users will now
have to opt into bson-kotlinx support.

JAVA-5036
Branch: master
https://github.com/mongodb/mongo-java-driver/commit/252e441635675ed73bd49eecd44fee539de46d08

Comment by Ross Lawley [ 22/Jun/23 ]

Potentially will require documentation to be updated for kotlinx serialization.

Generated at Thu Feb 08 09:03:35 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.