You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "ferruzzi (via GitHub)" <gi...@apache.org> on 2023/09/27 20:42:28 UTC

[GitHub] [airflow] ferruzzi commented on a diff in pull request #34653: Clarify Amazon Lambda invocation and sensing

ferruzzi commented on code in PR #34653:
URL: https://github.com/apache/airflow/pull/34653#discussion_r1339187733


##########
docs/apache-airflow-providers-amazon/operators/lambda.rst:
##########
@@ -57,6 +57,38 @@ Invoke an AWS Lambda function
 To invoke an AWS lambda function you can use
 :class:`~airflow.providers.amazon.aws.operators.lambda_function.LambdaInvokeFunctionOperator`.
 
+.. note::
+    According to `Lambda.Client.invoke <https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/lambda/client/invoke.html>`_ documentation
+    for synchronous invocation (``invocation_type="RequestResponse"``) with a long timeout, your client might
+    disconnect during synchronous invocation while it waits for a response.
+
+    If you encounter ``ReadTimeoutError`` exceptions, like that
+
+    .. code-block:: text
+
+      urllib3.exceptions.ReadTimeoutError: AWSHTTPSConnectionPool(host='lambda.us-east-1.amazonaws.com', port=443): Read timed out. (read timeout=60)
+
+    Then you need to configure :ref:`howto/connection:aws` to allow ``botocore`` / ``boto3`` to use long connections with
+    timeout or keep-alive settings, in order to do this you need to add in Connection Extra
+

Review Comment:
   Non-blocking nitpick:
   
   ```suggestion
       If this happens you will see a ``ReadTimeoutError`` exception similar to this:
   
       .. code-block:: text
   
         urllib3.exceptions.ReadTimeoutError: AWSHTTPSConnectionPool(host='lambda.us-east-1.amazonaws.com', port=443): Read timed out. (read timeout=60)
   
       If you encounter this issue, configure :ref:`howto/connection:aws` to allow ``botocore`` / ``boto3`` to use long connections with
       timeout or keep-alive settings in the Connection Extras field
   
   ```



##########
docs/apache-airflow-providers-amazon/operators/lambda.rst:
##########
@@ -68,10 +100,10 @@ Sensors
 
 .. _howto/sensor:LambdaFunctionStateSensor:
 
-Wait on an Amazon Lambda function state
-=======================================
+Wait on an AWS Lambda function deployment state

Review Comment:
   Thanks for fixing this.   Amazon/AWS Service names are so confusing :+1: 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org