increase aws_lambda_function timeout
Since the Lambda CreateFunction call may include an up to 50MB payload, the request can easily take more than a minute. This increases the timeout to 10 minutes.
This commit is contained in:
parent
7fbd880390
commit
ece6f30a21
|
@ -223,7 +223,7 @@ func resourceAwsLambdaFunctionCreate(d *schema.ResourceData, meta interface{}) e
|
||||||
// IAM profiles can take ~10 seconds to propagate in AWS:
|
// IAM profiles can take ~10 seconds to propagate in AWS:
|
||||||
// http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/iam-roles-for-amazon-ec2.html#launch-instance-with-role-console
|
// http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/iam-roles-for-amazon-ec2.html#launch-instance-with-role-console
|
||||||
// Error creating Lambda function: InvalidParameterValueException: The role defined for the task cannot be assumed by Lambda.
|
// Error creating Lambda function: InvalidParameterValueException: The role defined for the task cannot be assumed by Lambda.
|
||||||
err := resource.Retry(1*time.Minute, func() *resource.RetryError {
|
err := resource.Retry(10*time.Minute, func() *resource.RetryError {
|
||||||
_, err := conn.CreateFunction(params)
|
_, err := conn.CreateFunction(params)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Printf("[ERROR] Received %q, retrying CreateFunction", err)
|
log.Printf("[ERROR] Received %q, retrying CreateFunction", err)
|
||||||
|
|
Loading…
Reference in New Issue