Skip to content

Commit

Permalink
refactor: change log level for warning when collection already exists
Browse files Browse the repository at this point in the history
  • Loading branch information
aneojgurhem committed Oct 18, 2024
1 parent 43f6401 commit a8e1249
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions Adaptors/MongoDB/src/Common/MongoCollectionProvider.cs
Original file line number Diff line number Diff line change
Expand Up @@ -218,9 +218,9 @@ await model.InitializeCollectionAsync(session,
}
catch (MongoBulkWriteException<TData> e) when (e.WriteErrors.All(error => error.Category == ServerErrorCategory.DuplicateKey))
{
logger.LogWarning(e,
"Values were already present within the collection {CollectionName}",
model.CollectionName);
logger.LogDebug(e,
"Values were already present within the collection {CollectionName}",
model.CollectionName);
break;
}
catch (Exception ex)
Expand Down
2 changes: 1 addition & 1 deletion Common/tests/Auth/AuthenticationIntegrationTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -422,7 +422,7 @@ public static Metadata GetHeaders(IdentityIndex index,
{
headers.Add(AuthenticatorOptions.DefaultAuth.ImpersonationIdHeader,
(int)impersonate < 0
? "1000"
? "404"
: Identities[(int)impersonate]
.UserId.ToString());
}
Expand Down

0 comments on commit a8e1249

Please sign in to comment.