From bb6c1af341aa7fd16e582150820ab5bc2c0fda7e Mon Sep 17 00:00:00 2001 From: Nick LDP Date: Tue, 18 Jul 2023 15:07:08 -0400 Subject: [PATCH 1/3] DOCSP-27679:Make placeholder text consistent --- source/faq.txt | 2 +- source/fundamentals/logging.txt | 5 +++-- .../fundamentals/code-examples/connection/AtlasConnection.cs | 2 +- source/quick-start.txt | 2 +- source/usage-examples.txt | 2 +- 5 files changed, 7 insertions(+), 6 deletions(-) diff --git a/source/faq.txt b/source/faq.txt index bbe0b236..a69e3186 100644 --- a/source/faq.txt +++ b/source/faq.txt @@ -97,7 +97,7 @@ applications: .. code-block:: csharp - var client = new MongoClient(""); + var client = new MongoClient(""); Create a client once for each process, and reuse it for all operations. It is a common mistake to create a new client for each diff --git a/source/fundamentals/logging.txt b/source/fundamentals/logging.txt index 951f3a5c..8ab55da5 100644 --- a/source/fundamentals/logging.txt +++ b/source/fundamentals/logging.txt @@ -62,7 +62,8 @@ logs all debug messages to the console: b.SetMinimumLevel(LogLevel.Debug); }); - var settings = MongoClientSettings.FromConnectionString(""); + var settings = MongoClientSettings.FromConnectionString(""); settings.LoggingSettings = new LoggingSettings(loggerFactory); var client = new MongoClient(settings); @@ -141,7 +142,7 @@ to a ``LoggerFactory``. b.AddSimpleConsole(); }); - var settings = MongoClientSettings.FromConnectionString(""); + var settings = MongoClientSettings.FromConnectionString(""); settings.LoggingSettings = new LoggingSettings(loggerFactory); var client = new MongoClient(settings); diff --git a/source/includes/fundamentals/code-examples/connection/AtlasConnection.cs b/source/includes/fundamentals/code-examples/connection/AtlasConnection.cs index d2de62a0..89e37fc0 100644 --- a/source/includes/fundamentals/code-examples/connection/AtlasConnection.cs +++ b/source/includes/fundamentals/code-examples/connection/AtlasConnection.cs @@ -2,7 +2,7 @@ using MongoDB.Bson; // Replace the placeholder with your Atlas connection string -const string connectionUri = ""; +const string connectionUri = ""; var settings = MongoClientSettings.FromConnectionString(connectionUri); diff --git a/source/quick-start.txt b/source/quick-start.txt index bc746b20..ab725a94 100644 --- a/source/quick-start.txt +++ b/source/quick-start.txt @@ -41,7 +41,7 @@ code. .. code-block:: bash - export MONGODB_URI='' + export MONGODB_URI='' .. important:: diff --git a/source/usage-examples.txt b/source/usage-examples.txt index a3ab4b9d..ca19bf44 100644 --- a/source/usage-examples.txt +++ b/source/usage-examples.txt @@ -56,7 +56,7 @@ your MongoDB instance: .. code-block:: csharp // Replace the following with your MongoDB deployment's connection string. - private static string _mongoConnectionString = ""; + private static string _mongoConnectionString = ""; For more information about connecting to your MongoDB instance, see the :ref:`Connection Guide `. From b16301e328c8912e467bfaf2f598809b133956f6 Mon Sep 17 00:00:00 2001 From: Nick LDP Date: Tue, 18 Jul 2023 15:21:00 -0400 Subject: [PATCH 2/3] changing placeholder --- source/faq.txt | 2 +- source/fundamentals/logging.txt | 2 +- source/includes/code-examples/delete-many/DeleteMany.cs | 2 +- source/includes/code-examples/delete-many/DeleteManyAsync.cs | 2 +- source/includes/code-examples/delete-one/DeleteOne.cs | 2 +- source/includes/code-examples/delete-one/DeleteOneAsync.cs | 2 +- source/includes/code-examples/find-many/FindMany.cs | 2 +- source/includes/code-examples/find-many/FindManyAsync.cs | 2 +- source/includes/code-examples/find-one/FindOne.cs | 2 +- source/includes/code-examples/find-one/FindOneAsync.cs | 2 +- source/includes/code-examples/insert-many/InsertMany.cs | 2 +- source/includes/code-examples/insert-many/InsertManyAsync.cs | 2 +- source/includes/code-examples/insert-one/InsertOne.cs | 2 +- source/includes/code-examples/insert-one/InsertOneAsync.cs | 2 +- source/includes/code-examples/replace-one/ReplaceOne.cs | 2 +- source/includes/code-examples/replace-one/ReplaceOneAsync.cs | 2 +- source/includes/code-examples/update-many/UpdateMany.cs | 2 +- source/includes/code-examples/update-many/UpdateManyAsync.cs | 2 +- source/includes/code-examples/update-one/UpdateOne.cs | 2 +- source/includes/code-examples/update-one/UpdateOneAsync.cs | 2 +- source/includes/fundamentals/code-examples/CountDocuments.cs | 2 +- .../code-examples/atlas-search/AtlasSearchExamples.cs | 2 +- source/includes/fundamentals/code-examples/builders.cs | 2 +- .../fundamentals/code-examples/connection/AtlasConnection.cs | 2 +- .../includes/fundamentals/code-examples/crud/change/Replace.cs | 2 +- .../includes/fundamentals/code-examples/crud/change/Update.cs | 2 +- source/includes/fundamentals/code-examples/crud/delete.cs | 2 +- source/includes/fundamentals/code-examples/crud/insert.cs | 2 +- source/includes/fundamentals/code-examples/poco.cs | 2 +- source/usage-examples.txt | 2 +- 30 files changed, 30 insertions(+), 30 deletions(-) diff --git a/source/faq.txt b/source/faq.txt index a69e3186..bbe0b236 100644 --- a/source/faq.txt +++ b/source/faq.txt @@ -97,7 +97,7 @@ applications: .. code-block:: csharp - var client = new MongoClient(""); + var client = new MongoClient(""); Create a client once for each process, and reuse it for all operations. It is a common mistake to create a new client for each diff --git a/source/fundamentals/logging.txt b/source/fundamentals/logging.txt index 8ab55da5..d308634e 100644 --- a/source/fundamentals/logging.txt +++ b/source/fundamentals/logging.txt @@ -142,7 +142,7 @@ to a ``LoggerFactory``. b.AddSimpleConsole(); }); - var settings = MongoClientSettings.FromConnectionString(""); + var settings = MongoClientSettings.FromConnectionString(""); settings.LoggingSettings = new LoggingSettings(loggerFactory); var client = new MongoClient(settings); diff --git a/source/includes/code-examples/delete-many/DeleteMany.cs b/source/includes/code-examples/delete-many/DeleteMany.cs index 676ea207..e26ec8da 100644 --- a/source/includes/code-examples/delete-many/DeleteMany.cs +++ b/source/includes/code-examples/delete-many/DeleteMany.cs @@ -6,7 +6,7 @@ namespace CSharpExamples.UsageExamples.DeleteMany; public class DeleteMany { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static void Main(string[] args) { diff --git a/source/includes/code-examples/delete-many/DeleteManyAsync.cs b/source/includes/code-examples/delete-many/DeleteManyAsync.cs index 94eb4700..da88a883 100644 --- a/source/includes/code-examples/delete-many/DeleteManyAsync.cs +++ b/source/includes/code-examples/delete-many/DeleteManyAsync.cs @@ -6,7 +6,7 @@ namespace CSharpExamples.UsageExamples.DeleteMany; public class DeleteManyAsync { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static async Task Main(string[] args) { diff --git a/source/includes/code-examples/delete-one/DeleteOne.cs b/source/includes/code-examples/delete-one/DeleteOne.cs index 908147b7..85c7bf0a 100644 --- a/source/includes/code-examples/delete-one/DeleteOne.cs +++ b/source/includes/code-examples/delete-one/DeleteOne.cs @@ -6,7 +6,7 @@ namespace CSharpExamples.UsageExamples.DeleteOne; public class DeleteOne { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static void Main(string[] args) { diff --git a/source/includes/code-examples/delete-one/DeleteOneAsync.cs b/source/includes/code-examples/delete-one/DeleteOneAsync.cs index abfc0911..6f5b2734 100644 --- a/source/includes/code-examples/delete-one/DeleteOneAsync.cs +++ b/source/includes/code-examples/delete-one/DeleteOneAsync.cs @@ -6,7 +6,7 @@ namespace CSharpExamples.UsageExamples.DeleteOne; public class DeleteOneAsync { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static async Task Main(string[] args) { diff --git a/source/includes/code-examples/find-many/FindMany.cs b/source/includes/code-examples/find-many/FindMany.cs index 25ca6843..c7ff8926 100644 --- a/source/includes/code-examples/find-many/FindMany.cs +++ b/source/includes/code-examples/find-many/FindMany.cs @@ -6,7 +6,7 @@ namespace CSharpExamples.UsageExamples.FindMany; public class FindMany { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static void Main(string[] args) { diff --git a/source/includes/code-examples/find-many/FindManyAsync.cs b/source/includes/code-examples/find-many/FindManyAsync.cs index 6450acc6..96150761 100644 --- a/source/includes/code-examples/find-many/FindManyAsync.cs +++ b/source/includes/code-examples/find-many/FindManyAsync.cs @@ -7,7 +7,7 @@ namespace CSharpExamples.UsageExamples.FindMany; public class FindManyAsync { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static async Task Main(string[] args) { diff --git a/source/includes/code-examples/find-one/FindOne.cs b/source/includes/code-examples/find-one/FindOne.cs index bc073e5e..dfed8220 100644 --- a/source/includes/code-examples/find-one/FindOne.cs +++ b/source/includes/code-examples/find-one/FindOne.cs @@ -7,7 +7,7 @@ namespace CSharpExamples.UsageExamples.FindOne; public class FindOne { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static void Main(string[] args) { diff --git a/source/includes/code-examples/find-one/FindOneAsync.cs b/source/includes/code-examples/find-one/FindOneAsync.cs index da35eb6a..88d1b51b 100644 --- a/source/includes/code-examples/find-one/FindOneAsync.cs +++ b/source/includes/code-examples/find-one/FindOneAsync.cs @@ -8,7 +8,7 @@ namespace CSharpExamples.UsageExamples.FindOne; public class FindOneAsync { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static async Task Main(string[] args) { diff --git a/source/includes/code-examples/insert-many/InsertMany.cs b/source/includes/code-examples/insert-many/InsertMany.cs index 255ed9eb..427cbffe 100644 --- a/source/includes/code-examples/insert-many/InsertMany.cs +++ b/source/includes/code-examples/insert-many/InsertMany.cs @@ -7,7 +7,7 @@ namespace CSharpExamples.UsageExamples.InsertMany; public class InsertMany { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static void Main(string[] args) { diff --git a/source/includes/code-examples/insert-many/InsertManyAsync.cs b/source/includes/code-examples/insert-many/InsertManyAsync.cs index 376eaa92..cc36e39f 100644 --- a/source/includes/code-examples/insert-many/InsertManyAsync.cs +++ b/source/includes/code-examples/insert-many/InsertManyAsync.cs @@ -7,7 +7,7 @@ namespace CSharpExamples.UsageExamples.InsertMany; public class InsertManyAsync { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static async Task Main(string[] args) { diff --git a/source/includes/code-examples/insert-one/InsertOne.cs b/source/includes/code-examples/insert-one/InsertOne.cs index 7f2108c5..d0e9b37b 100644 --- a/source/includes/code-examples/insert-one/InsertOne.cs +++ b/source/includes/code-examples/insert-one/InsertOne.cs @@ -7,7 +7,7 @@ namespace CsharpExamples.UsageExamples.InsertOne; public class InsertOne { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static void Main(string[] args) { diff --git a/source/includes/code-examples/insert-one/InsertOneAsync.cs b/source/includes/code-examples/insert-one/InsertOneAsync.cs index a7cd3b83..c6a93ba0 100644 --- a/source/includes/code-examples/insert-one/InsertOneAsync.cs +++ b/source/includes/code-examples/insert-one/InsertOneAsync.cs @@ -7,7 +7,7 @@ namespace CsharpExamples.UsageExamples.InsertOne; public class InsertOneAsync { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static async Task Main(string[] args) { diff --git a/source/includes/code-examples/replace-one/ReplaceOne.cs b/source/includes/code-examples/replace-one/ReplaceOne.cs index 51d263cd..ca616c76 100644 --- a/source/includes/code-examples/replace-one/ReplaceOne.cs +++ b/source/includes/code-examples/replace-one/ReplaceOne.cs @@ -7,7 +7,7 @@ namespace CSharpExamples.UsageExamples.ReplaceOne; public class ReplaceOne { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static void Main(string[] args) { diff --git a/source/includes/code-examples/replace-one/ReplaceOneAsync.cs b/source/includes/code-examples/replace-one/ReplaceOneAsync.cs index 37727a0c..3c187b93 100644 --- a/source/includes/code-examples/replace-one/ReplaceOneAsync.cs +++ b/source/includes/code-examples/replace-one/ReplaceOneAsync.cs @@ -7,7 +7,7 @@ namespace CSharpExamples.UsageExamples.ReplaceOne; public class ReplaceOneAsync { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static async Task Main(string[] args) { diff --git a/source/includes/code-examples/update-many/UpdateMany.cs b/source/includes/code-examples/update-many/UpdateMany.cs index 7a48ace6..554a5298 100644 --- a/source/includes/code-examples/update-many/UpdateMany.cs +++ b/source/includes/code-examples/update-many/UpdateMany.cs @@ -6,7 +6,7 @@ namespace CSharpExamples.UsageExamples.UpdateMany; public class UpdateMany { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; private const string OldCuisine = "Pizza"; private const string NewCuisine = "Pasta and breadsticks"; diff --git a/source/includes/code-examples/update-many/UpdateManyAsync.cs b/source/includes/code-examples/update-many/UpdateManyAsync.cs index cd1fc928..8f178b74 100644 --- a/source/includes/code-examples/update-many/UpdateManyAsync.cs +++ b/source/includes/code-examples/update-many/UpdateManyAsync.cs @@ -6,7 +6,7 @@ namespace CSharpExamples.UsageExamples.UpdateMany; public class UpdateManyAsync { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; private const string OldCuisine = "Pizza"; private const string NewCuisine = "Pasta and breadsticks"; diff --git a/source/includes/code-examples/update-one/UpdateOne.cs b/source/includes/code-examples/update-one/UpdateOne.cs index 8b180855..a0f769d5 100644 --- a/source/includes/code-examples/update-one/UpdateOne.cs +++ b/source/includes/code-examples/update-one/UpdateOne.cs @@ -6,7 +6,7 @@ namespace CSharpExamples.UsageExamples.UpdateOne; public class UpdateOne { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static void Main(string[] args) { diff --git a/source/includes/code-examples/update-one/UpdateOneAsync.cs b/source/includes/code-examples/update-one/UpdateOneAsync.cs index 843812e0..c0157367 100644 --- a/source/includes/code-examples/update-one/UpdateOneAsync.cs +++ b/source/includes/code-examples/update-one/UpdateOneAsync.cs @@ -6,7 +6,7 @@ namespace CSharpExamples.UsageExamples.UpdateOne; public class UpdateOneAsync { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static async Task Main(string[] args) { diff --git a/source/includes/fundamentals/code-examples/CountDocuments.cs b/source/includes/fundamentals/code-examples/CountDocuments.cs index 2195f963..29aa39c9 100644 --- a/source/includes/fundamentals/code-examples/CountDocuments.cs +++ b/source/includes/fundamentals/code-examples/CountDocuments.cs @@ -4,7 +4,7 @@ namespace TestRun.Fundamentals; public class CountDocuments { private static IMongoCollection _myColl; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static void Main(string[] args) { Setup(); diff --git a/source/includes/fundamentals/code-examples/atlas-search/AtlasSearchExamples.cs b/source/includes/fundamentals/code-examples/atlas-search/AtlasSearchExamples.cs index 8fef4cc3..18768fa8 100644 --- a/source/includes/fundamentals/code-examples/atlas-search/AtlasSearchExamples.cs +++ b/source/includes/fundamentals/code-examples/atlas-search/AtlasSearchExamples.cs @@ -8,7 +8,7 @@ public class AtlasSearchExamples { private static IMongoCollection guitarsCollection; - private static string _mongoConnectionString = ""; + private static string _mongoConnectionString = ""; public static void Main(string[] args) { diff --git a/source/includes/fundamentals/code-examples/builders.cs b/source/includes/fundamentals/code-examples/builders.cs index 3bb4a79f..cd6ba920 100644 --- a/source/includes/fundamentals/code-examples/builders.cs +++ b/source/includes/fundamentals/code-examples/builders.cs @@ -6,7 +6,7 @@ namespace TestRun.Fundamentals; public class Builders { private static IMongoCollection _flowerCollection; - private static string _mongoConnectionString = ""; + private static string _mongoConnectionString = ""; public static void Main(string[] args) { diff --git a/source/includes/fundamentals/code-examples/connection/AtlasConnection.cs b/source/includes/fundamentals/code-examples/connection/AtlasConnection.cs index 89e37fc0..d2de62a0 100644 --- a/source/includes/fundamentals/code-examples/connection/AtlasConnection.cs +++ b/source/includes/fundamentals/code-examples/connection/AtlasConnection.cs @@ -2,7 +2,7 @@ using MongoDB.Bson; // Replace the placeholder with your Atlas connection string -const string connectionUri = ""; +const string connectionUri = ""; var settings = MongoClientSettings.FromConnectionString(connectionUri); diff --git a/source/includes/fundamentals/code-examples/crud/change/Replace.cs b/source/includes/fundamentals/code-examples/crud/change/Replace.cs index cae8bc63..5ab0303f 100644 --- a/source/includes/fundamentals/code-examples/crud/change/Replace.cs +++ b/source/includes/fundamentals/code-examples/crud/change/Replace.cs @@ -7,7 +7,7 @@ namespace CSharpExamples.Fundamentals.ReplaceOne; public class ReplaceOne { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; public static void Main(string[] args) { diff --git a/source/includes/fundamentals/code-examples/crud/change/Update.cs b/source/includes/fundamentals/code-examples/crud/change/Update.cs index 14370d72..f661013b 100644 --- a/source/includes/fundamentals/code-examples/crud/change/Update.cs +++ b/source/includes/fundamentals/code-examples/crud/change/Update.cs @@ -7,7 +7,7 @@ namespace Fundamentals public class Update { private static IMongoCollection _restaurantsCollection; - private const string MongoConnectionString = ""; + private const string MongoConnectionString = ""; private const string OldValue = "Manhattan"; private const string NewValue = "Manhattan (north)"; diff --git a/source/includes/fundamentals/code-examples/crud/delete.cs b/source/includes/fundamentals/code-examples/crud/delete.cs index b7ce50e2..a0cb0664 100644 --- a/source/includes/fundamentals/code-examples/crud/delete.cs +++ b/source/includes/fundamentals/code-examples/crud/delete.cs @@ -6,7 +6,7 @@ namespace TestRun.Fundamentals; public class Delete { private static IMongoCollection _restaurantsCollection; - private static string _mongoConnectionString = ""; + private static string _mongoConnectionString = ""; public static void Main(string[] args) { diff --git a/source/includes/fundamentals/code-examples/crud/insert.cs b/source/includes/fundamentals/code-examples/crud/insert.cs index 824c337a..797dae5a 100644 --- a/source/includes/fundamentals/code-examples/crud/insert.cs +++ b/source/includes/fundamentals/code-examples/crud/insert.cs @@ -6,7 +6,7 @@ namespace TestRun.Fundamentals; public class Insert { private static IMongoCollection _restaurantsCollection; - private static string _mongoConnectionString = ""; + private static string _mongoConnectionString = ""; public static void Main(string[] args) { diff --git a/source/includes/fundamentals/code-examples/poco.cs b/source/includes/fundamentals/code-examples/poco.cs index 4e18f7be..dbfab990 100644 --- a/source/includes/fundamentals/code-examples/poco.cs +++ b/source/includes/fundamentals/code-examples/poco.cs @@ -6,7 +6,7 @@ namespace DataFormats.Poco; public class Poco { private static IMongoCollection _myColl; - private static string _mongoConnectionString = ""; + private static string _mongoConnectionString = ""; public static void Main(string[] args) { diff --git a/source/usage-examples.txt b/source/usage-examples.txt index ca19bf44..6c3c8097 100644 --- a/source/usage-examples.txt +++ b/source/usage-examples.txt @@ -56,7 +56,7 @@ your MongoDB instance: .. code-block:: csharp // Replace the following with your MongoDB deployment's connection string. - private static string _mongoConnectionString = ""; + private static string _mongoConnectionString = ""; For more information about connecting to your MongoDB instance, see the :ref:`Connection Guide `. From a5af7b623a76487aa5c5fd6accd4d5dee0989d9e Mon Sep 17 00:00:00 2001 From: Nick LDP Date: Tue, 18 Jul 2023 15:26:10 -0400 Subject: [PATCH 3/3] fixed line wraps --- source/fundamentals/logging.txt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/source/fundamentals/logging.txt b/source/fundamentals/logging.txt index d308634e..788cc962 100644 --- a/source/fundamentals/logging.txt +++ b/source/fundamentals/logging.txt @@ -62,8 +62,7 @@ logs all debug messages to the console: b.SetMinimumLevel(LogLevel.Debug); }); - var settings = MongoClientSettings.FromConnectionString(""); + var settings = MongoClientSettings.FromConnectionString(""); settings.LoggingSettings = new LoggingSettings(loggerFactory); var client = new MongoClient(settings);