mirror of
https://github.com/GSA/notifications-api.git
synced 2025-12-20 23:41:17 -05:00
Always log when a lambda is invoked
This replaces the previous single-purpose log about a link test with a more informative and generic one for all invocations.
This commit is contained in:
@@ -251,6 +251,4 @@ def send_broadcast_provider_message(self, broadcast_event_id, provider):
|
||||
@notify_celery.task(name='trigger-link-test')
|
||||
def trigger_link_test(provider):
|
||||
identifier = str(uuid.uuid4())
|
||||
message = f"Sending a link test to CBC proxy for provider {provider}. Identifier in payload is {identifier}"
|
||||
current_app.logger.info(message)
|
||||
cbc_proxy_client.get_proxy(provider).send_link_test(identifier)
|
||||
|
||||
@@ -118,6 +118,10 @@ class CBCProxyClientBase(ABC):
|
||||
def _invoke_lambda(self, lambda_name, payload):
|
||||
payload_bytes = bytes(json.dumps(payload), encoding='utf8')
|
||||
try:
|
||||
current_app.logger.info(
|
||||
f"Calling lambda {lambda_name} for link test with payload {payload}"
|
||||
)
|
||||
|
||||
result = self._lambda_client.invoke(
|
||||
FunctionName=lambda_name,
|
||||
InvocationType='RequestResponse',
|
||||
|
||||
Reference in New Issue
Block a user