Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.
TypeScript acmeagentsai-agentscertificate-managementdevsecopsenvironment-variableskubernetesopen-sourcepampkipostgresprivate-caprivileged-access-managementsecret-managementsecret-managersecretssecrets-managementsecuritysecurity-toolsvault
feat: added a catch and override error message for ping check
Akhil Mohanfdda247120de
diff --git a/backend/src/ee/services/audit-log-stream/audit-log-stream-service.ts b/backend/src/ee/services/audit-log-stream/audit-log-stream-service.tsindex b82ce04ae9..0e313b59bb 100644--- a/backend/src/ee/services/audit-log-stream/audit-log-stream-service.ts+++ b/backend/src/ee/services/audit-log-stream/audit-log-stream-service.ts@@ -140,17 +140,21 @@ export const auditLogStreamServiceFactory = ({streamHeaders[key] = value;});- await request.post(- url || logStream.url,- { ping: "ok" },- {- headers: streamHeaders,- // request timeout- timeout: AUDIT_LOG_STREAM_TIMEOUT,- // connection timeout- signal: AbortSignal.timeout(AUDIT_LOG_STREAM_TIMEOUT)- }- );+ await request+ .post(+ url || logStream.url,+ { ping: "ok" },+ {+ headers: streamHeaders,+ // request timeout+ timeout: AUDIT_LOG_STREAM_TIMEOUT,+ // connection timeout+ signal: AbortSignal.timeout(AUDIT_LOG_STREAM_TIMEOUT)+ }+ )+ .catch((err) => {+ throw new Error(`Failed to connect with the source ${(err as Error)?.message}`);+ });const encryptedHeaders = headers ? infisicalSymmetricEncypt(JSON.stringify(headers)) : undefined;const updatedLogStream = await auditLogStreamDAL.updateById(id, {