diff --git a/src/adapters/deployer/index.ts b/src/adapters/deployer/index.ts index 426e6ff..3655e0f 100644 --- a/src/adapters/deployer/index.ts +++ b/src/adapters/deployer/index.ts @@ -11,7 +11,7 @@ export function createDeployerComponent( const logger = components.logs.getLogger('downloader') const client = new SNSClient({ - endpoint: components.sns.optionalSnsEndpoint + endpoint: components.sns.optionalSnsEndpoint ? components.sns.optionalSnsEndpoint : undefined }) return { @@ -26,6 +26,15 @@ export function createDeployerComponent( const isSnsEventToSend = !!components.sns.eventArn + + logger.debug('Handling entity', { + entityId: entity.entityId, + entityType: entity.entityType, + exists: exists ? 'true' : 'false', + isSnsEntityToSend: isSnsEntityToSend ? 'true' : 'false', + isSnsEventToSend: isSnsEventToSend ? 'true' : 'false' + }) + if (exists || !(isSnsEntityToSend && isSnsEventToSend)) { return await markAsDeployed() }