refactor(mongodb-credentials): remove TLS requirement from MongoDB client options and update documentation formatting

This commit is contained in:
Victor Santos
2025-12-03 18:26:12 -03:00
parent ede26c98a0
commit dfbc2ed033
2 changed files with 4 additions and 4 deletions
@@ -47,7 +47,7 @@ export const mongodbCredentialsRotationFactory: TRotationFactory<
// Helper function to create MongoDB client with given credentials
const $createMongoClient = async (
authCredentials: { username: string; password: string },
options?: { validateConnection?: boolean; requireTlsForSrv?: boolean }
options?: { validateConnection?: boolean }
): Promise<MongoClient> => {
let normalizedHost = connection.credentials.host.trim();
const srvRegex = new RE2("^mongodb\\+srv:\\/\\/");
@@ -120,7 +120,7 @@ export const mongodbCredentialsRotationFactory: TRotationFactory<
username: credentials.username,
password: credentials.password
},
{ validateConnection: true, requireTlsForSrv: true }
{ validateConnection: true }
);
} catch (error) {
throw new Error(redactPasswords(error, [credentials]));