Skip to content

Commit

Permalink
chore(deps): update dependency mongodb.driver to 2.30.0 (#117)
Browse files Browse the repository at this point in the history
* chore(deps): update dependency mongodb.driver to 2.30.0

* Silence obsolete for now

---------

Co-authored-by: Renovate Bot <[email protected]>
Co-authored-by: guillaume.caya <[email protected]>
  • Loading branch information
3 people authored Feb 3, 2025
1 parent ace7546 commit b49c20f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="MongoDB.Driver" Version="2.29.0" />
<PackageReference Include="MongoDB.Driver" Version="2.30.0" />
</ItemGroup>

<ItemGroup Condition=" '$(TargetFramework)' == 'net472' Or '$(TargetFramework)' == 'netstandard2.0' ">
Expand Down
8 changes: 6 additions & 2 deletions src/Workleap.Extensions.Mongo/MongoStaticOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,16 @@ public MongoStaticOptions()
this.BsonSerializers = new Dictionary<Type, IBsonSerializer>();
this.ConventionPacks = new List<NamedConventionPack>();

// Guid representation V3 will be the default in Mongo C# driver 3.x so we use it already (V2 is deprecated)
// https://mongodb.github.io/mongo-csharp-driver/2.18/reference/bson/guidserialization/guidrepresentationmode/guidrepresentationmode/
// This enum will disappear in Mongo C# driver 3.x and V3 will be the default
// https://www.mongodb.com/docs/drivers/csharp/current/upgrade/v3/#version-3.0-breaking-changes
#pragma warning disable CS0618 // Type or member is obsolete
this.GuidRepresentationMode = GuidRepresentationMode.V3;
#pragma warning restore CS0618 // Type or member is obsolete
}

#pragma warning disable CS0618 // Type or member is obsolete
public GuidRepresentationMode GuidRepresentationMode { get; set; }
#pragma warning restore CS0618 // Type or member is obsolete

public IDictionary<Type, IBsonSerializer> BsonSerializers { get; }

Expand Down

0 comments on commit b49c20f

Please sign in to comment.