@@ -92,7 +92,7 @@ mechanism:
9292
9393 .. code-block:: java
9494
95- MongoClient mongoClient = MongoClients.create("<username >@<hostname>:<port>/?authSource=$external&authMechanism=GSSAPI");
95+ MongoClient mongoClient = MongoClients.create("<db_username >@<hostname>:<port>/?authSource=$external&authMechanism=GSSAPI");
9696
9797 .. tab::
9898 :tabid: MongoCredential
@@ -151,7 +151,7 @@ You might need to specify one or more of the following additional
151151
152152 .. code-block:: java
153153
154- MongoClient mongoClient = MongoClients.create("<username >@<hostname>:<port>/?authSource=$external&authMechanism=GSSAPI&authMechanismProperties=SERVICE_NAME:myService");
154+ MongoClient mongoClient = MongoClients.create("<db_username >@<hostname>:<port>/?authSource=$external&authMechanism=GSSAPI&authMechanismProperties=SERVICE_NAME:myService");
155155
156156 .. tab::
157157 :tabid: MongoCredential
@@ -277,7 +277,7 @@ mechanism:
277277
278278 .. code-block:: java
279279
280- MongoClient mongoClient = MongoClients.create("<username >:<password >@<hostname>:<port>/?authSource=$external&authMechanism=PLAIN");
280+ MongoClient mongoClient = MongoClients.create("<db_username >:<db_password >@<hostname>:<port>/?authSource=$external&authMechanism=PLAIN");
281281
282282 .. tab::
283283 :tabid: MongoCredential
@@ -340,21 +340,21 @@ see the corresponding syntax.
340340 .. code-block:: java
341341
342342 MongoClient mongoClient = MongoClients.create(
343- "mongodb://<username >@<hostname>:<port>/?" +
343+ "mongodb://<db_username >@<hostname>:<port>/?" +
344344 "?authMechanism=MONGODB-OIDC" +
345345 "&authMechanismProperties=ENVIRONMENT:azure,TOKEN_RESOURCE:<percent-encoded audience>");
346346
347347 .. tab:: MongoCredential
348348 :tabid: mongodb-azure-mongo-credential
349349
350- Replace the ``<username >`` placeholder with the client ID or application ID of the
350+ Replace the ``<db_username >`` placeholder with the client ID or application ID of the
351351 Azure managed identity or enterprise application. Replace the ``<audience>``
352352 placeholder with the value of the
353353 ``audience`` server parameter configured on your MongoDB deployment.
354354
355355 .. code-block:: java
356356
357- MongoCredential credential = MongoCredential.createOidcCredential("<username >")
357+ MongoCredential credential = MongoCredential.createOidcCredential("<db_username >")
358358 .withMechanismProperty("ENVIRONMENT", "azure")
359359 .withMechanismProperty("TOKEN_RESOURCE", "<audience>");
360360
0 commit comments