Skip to content

Commit

Permalink
CSHARP-5324: Mark API as obsolete: Transactions + LINQ (#1493)
Browse files Browse the repository at this point in the history
  • Loading branch information
papafe authored Oct 14, 2024
1 parent 59878b7 commit 16ea688
Show file tree
Hide file tree
Showing 12 changed files with 18 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ namespace MongoDB.Driver.Core.Clusters
/// <summary>
/// Represents a creator for CryptClient.
/// </summary>
[Obsolete("This class will be made internal in a later release.")]
public sealed class CryptClientCreator
{
#region static
Expand Down
2 changes: 2 additions & 0 deletions src/MongoDB.Driver.Core/Core/Operations/DeleteRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
* limitations under the License.
*/

using System;
using MongoDB.Bson;
using MongoDB.Driver.Core.Connections;
using MongoDB.Driver.Core.Misc;
Expand All @@ -22,6 +23,7 @@ namespace MongoDB.Driver.Core.Operations
/// <summary>
/// Represents a request to delete one or more documents.
/// </summary>
[Obsolete("This class will be made internal in a later release.")]
public sealed class DeleteRequest : WriteRequest
{
// fields
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,15 @@
* limitations under the License.
*/

using System;
using MongoDB.Bson.IO;

namespace MongoDB.Driver.Core.Operations.ElementNameValidators
{
/// <summary>
/// Represents a factory for element name validators based on the update type.
/// </summary>
[Obsolete("This class will be made internal in a later release.")]
public static class ElementNameValidatorFactory
{
/// <summary>
Expand Down
1 change: 1 addition & 0 deletions src/MongoDB.Driver.Core/Core/Operations/InsertRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ namespace MongoDB.Driver.Core.Operations
/// <summary>
/// Represents a request to insert a document.
/// </summary>
[Obsolete("This class will be made internal in a later release.")]
public sealed class InsertRequest : WriteRequest
{
// fields
Expand Down
1 change: 1 addition & 0 deletions src/MongoDB.Driver.Core/Core/Operations/UpdateRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ namespace MongoDB.Driver.Core.Operations
/// <summary>
/// Represents a request to update one or more documents.
/// </summary>
[Obsolete("This class will be made internal in a later release.")]
public sealed class UpdateRequest : WriteRequest
{
// fields
Expand Down
1 change: 1 addition & 0 deletions src/MongoDB.Driver.Core/Core/Operations/WriteRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ namespace MongoDB.Driver.Core.Operations
/// Represents a request to write something to the database.
/// </summary>
[Serializable]
[Obsolete("This class will be made internal in a later release.")]
public abstract class WriteRequest
{
// fields
Expand Down
3 changes: 3 additions & 0 deletions src/MongoDB.Driver.Core/Core/Operations/WriteRequestType.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,14 @@
* limitations under the License.
*/

using System;

namespace MongoDB.Driver.Core.Operations
{
/// <summary>
/// Represents the type of a write request.
/// </summary>
[Obsolete("This enum will be made internal in a later release.")]
public enum WriteRequestType
{
/// <summary>
Expand Down
3 changes: 3 additions & 0 deletions src/MongoDB.Driver/Linq/IMongoQueryable.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
* limitations under the License.
*/

using System;
using System.Linq;
using MongoDB.Bson;

Expand All @@ -21,6 +22,7 @@ namespace MongoDB.Driver.Linq
/// <summary>
/// Provides functionality to evaluate queries against MongoDB.
/// </summary>
[Obsolete("This interface will be removed in a later release.")]
public interface IMongoQueryable : IQueryable
{
/// <summary>
Expand All @@ -39,6 +41,7 @@ public interface IMongoQueryable : IQueryable
/// <returns>
/// The execution model.
/// </returns>
[Obsolete("This method will be removed in a later release.")]
QueryableExecutionModel GetExecutionModel();
}

Expand Down
1 change: 1 addition & 0 deletions src/MongoDB.Driver/Linq/LinqProvider.cs
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ public enum LinqProvider
/// but you can still select the V2 provider by configuring it in MongoClientSettings. The V2 LINQ provider is no
/// longer being actively maintained and will eventually be removed.
/// </summary>
[Obsolete("This version of the LINQ provider will be removed in a later release.")]
V2 = 2,

/// <summary>
Expand Down
1 change: 1 addition & 0 deletions src/MongoDB.Driver/MongoClientSettings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -434,6 +434,7 @@ public LibraryInfo LibraryInfo
/// <summary>
/// Gets or sets the LINQ provider.
/// </summary>
[Obsolete("This property will be removed in a later release.")]
public LinqProvider LinqProvider
{
get { return _linqProvider; }
Expand Down
1 change: 1 addition & 0 deletions src/MongoDB.Driver/PipelineDefinition.cs
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ public override string ToString()
/// <returns>
/// A <see cref="System.String" /> that represents this instance.
/// </returns>
[Obsolete("This method will be removed in a later release.")]
public string ToString(LinqProvider linqProvider)
{
var serializerRegistry = BsonSerializer.SerializerRegistry;
Expand Down
1 change: 1 addition & 0 deletions src/MongoDB.Driver/PipelineDefinitionBuilder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,7 @@ public static PipelineDefinition<TInput, TOutput> BucketAuto<TInput, TIntermedia
/// <param name="options">The options (optional).</param>
/// <param name="translationOptions">The translation options.</param>
/// <returns>A new pipeline with an additional stage.</returns>
[Obsolete("This method will be removed in a later release.")]
public static PipelineDefinition<TInput, TOutput> BucketAutoForLinq2<TInput, TIntermediate, TValue, TOutput>(
this PipelineDefinition<TInput, TIntermediate> pipeline,
Expression<Func<TIntermediate, TValue>> groupBy,
Expand Down

0 comments on commit 16ea688

Please sign in to comment.