MCPcopy Index your code
hub / github.com/zappa/Zappa / _send

Method _send

zappa/asynchronous.py:182–195  ·  view source on GitHub ↗

Given a message, directly invoke the lamdba function for this task.

(self, message)

Source from the content-addressed store, hash-verified

180 return self
181
182 def _send(self, message):
183 """
184 Given a message, directly invoke the lamdba function for this task.
185 """
186 message["command"] = "zappa.asynchronous.route_lambda_task"
187 payload = json.dumps(message)
188 if len(payload) > LAMBDA_ASYNC_PAYLOAD_LIMIT: # pragma: no cover
189 raise AsyncException("Payload too large for async Lambda call")
190 self.response = self.client.invoke(
191 FunctionName=self.lambda_function_name,
192 InvocationType="Event", # makes the call async
193 Payload=payload,
194 )
195 self.sent = self.response.get("StatusCode", 0) == 202
196
197
198class SnsAsyncResponse(LambdaAsyncResponse):

Callers 1

sendMethod · 0.95

Calls 2

AsyncExceptionClass · 0.85
invokeMethod · 0.80

Tested by

no test coverage detected