This message was deleted.
# general
s
This message was deleted.
h
no_stage.png
s
I suspect some of the wait logic in the underlying Terraform provider may be at fault here.
h
There’s been no indication of failure to create or that any resources haven’t been created — any thoughts here? @gentle-diamond-70147
g
Can you share your code or at least a minimum amount that reproduces this? Unfortunately, I'm not that familiar with API Gateway so it will take me awhile to put together an app to test this.
h
@gentle-diamond-70147 sure — I believe this could demo
you will have to remove the lambda function and integration or include a lambda
g
Thanks. Give me a bit to look into this.
h
now I am having an issue with deleting the stack —
Copy code
Usage Plan: NotFoundException: Invalid API Stage...
ah @gentle-diamond-70147 looks like when I created the deployment the stage was already created - not sure how that got the last stack in a state where both were successfully created but not associated, but removing the stage creation works 😕
Lambda invocation remains an issue though 😕 This is something on AWS’s side because it’s consistently bad. To fix lambda invocation, the easiest work around is to go into the API gateway UI, edit the integration by: (API/<api_name>/Resources then click on the method, click on the
integration request
, and then click the pencil next to
lambda function
and just save — creates a popup to allow invocation
g
just so I'm following, that's an issue with
aws.apigateway.Integration
in your code, right? That gets saved, but not "enabled" - is that the issue?
h
the lambda invocation issue?
g
yes
h
yes!
exactly
g
after clicking Save in the AWS console, if you do a
pulumi refresh
does it show any updated resources/attributes?
h
yes
g
which resources/attributes show changes during the refresh after a save?
h
Copy code
pulumi:pulumi:Stack               pulumi_demo-pulumi_demo              
     ├─ aws:iam:Policy                 DemoLogCreationPolicy                
 ~   ├─ aws:iam:Role                   DemoIamApiRole            update     [diff: ~assumeRolePolicy]
     ├─ aws:apigateway:ApiKey          DemoApiKey                           
     ├─ aws:apigateway:RestApi         DemoApi                              
     ├─ aws:apigateway:Account         DemoApiAccount                       
     ├─ aws:s3:Bucket                  DemoBucket                           
     ├─ aws:dynamodb:Table             DemoTable                            
     ├─ aws:iam:RolePolicyAttachment   DemoApiRolePolicy                    
     ├─ aws:iam:RolePolicyAttachment   DemoRolePolicyAttachment             
 ~   ├─ aws:s3:BucketPolicy            DemoBucketPolicy          update     [diff: ~policy]
     ├─ aws:apigateway:Resource        DemoResource                         
 ~   ├─ aws:apigateway:Method          DemoMethodPost            update     [diff: +authorizationScopes,authorizerId,requestModels,requestParameters,requestValidatorId]
     ├─ aws:s3:BucketObject            DemoBucketObject                     
 ~   ├─ aws:iam:Role                   DemoIamRole               update     [diff: ~assumeRolePolicy]
     ├─ aws:iam:RolePolicy             DemoInvocationPolicy                 
     ├─ aws:apigateway:Integration     DemoGetIntegration                   
 ~   ├─ aws:apigateway:Method          DemoMethodGet             update     [diff: +authorizationScopes,authorizerId,requestModels,requestParameters,requestValidatorId]
     ├─ aws:apigateway:UsagePlanKey    DemoUsagePlanKey                     
     ├─ aws:apigateway:Deployment      DemoDeployment                       
 ~   ├─ aws:apigateway:Integration     DemoPostIntegration       update     [diff: ~contentHandling]
     ├─ aws:apigateway:MethodSettings  DemoGetMethodSettings                
     ├─ aws:apigateway:UsagePlan       DemoUsagePlan                        
     ├─ aws:apigateway:MethodSettings  DemoPostMethodSettings               
 ~   └─ aws:lambda:Function            PythonFunction
if I do the same UI click with the
get
method (I initially had just done so for
post
)
Copy code
Type                              Name                      Plan       Info
     pulumi:pulumi:Stack               pulumi_demo-pulumi_demo              
     ├─ aws:apigateway:ApiKey          DemoApiKey                           
     ├─ aws:iam:Policy                 DemoLogCreationPolicy                
     ├─ aws:apigateway:RestApi         DemoApi                              
 ~   ├─ aws:iam:Role                   DemoIamApiRole            update     [diff: ~assumeRolePolicy]
     ├─ aws:iam:Role                   DemoIamRole                          
     ├─ aws:iam:RolePolicyAttachment   DemoApiRolePolicy                    
     ├─ aws:apigateway:Resource        DemoResource                         
     ├─ aws:apigateway:Account         DemoApiAccount                       
     ├─ aws:dynamodb:Table             DemoTable                            
 ~   ├─ aws:s3:BucketPolicy            DemoBucketPolicy          update     [diff: ~policy]
 ~   ├─ aws:apigateway:Method          DemoMethodPost            update     [diff: +authorizationScopes,authorizerId,requestModels,requestParameters,requestValidatorId]
     ├─ aws:iam:RolePolicyAttachment   DemoRolePolicyAttachment             
     ├─ aws:s3:Bucket                  DemoBucket                           
 ~   ├─ aws:apigateway:Method          DemoMethodGet             update     [diff: +authorizationScopes,authorizerId,requestModels,requestParameters,requestValidatorId]
     ├─ aws:s3:BucketObject            DemoBucketObject                     
     ├─ aws:iam:RolePolicy             DemoInvocationPolicy                 
     ├─ aws:apigateway:Deployment      DemoDeployment                       
     ├─ aws:apigateway:UsagePlanKey    DemoUsagePlanKey                     
 ~   ├─ aws:apigateway:Integration     DemoGetIntegration        update     [diff: ~contentHandling,integrationHttpMethod]
 ~   ├─ aws:apigateway:Integration     DemoPostIntegration       update     [diff: ~contentHandling]
     ├─ aws:apigateway:MethodSettings  DemoGetMethodSettings                
     ├─ aws:apigateway:UsagePlan       DemoUsagePlan                        
 ~   ├─ aws:lambda:Function            PythonFunction            
     └─ aws:apigateway:MethodSettings  DemoPostMethodSettings
g
I think this will take more digging into than I'm able to do right this moment. Could you open an issue at https://github.com/pulumi/pulumi-aws/issues ?
h
Yeah 🙂 thanks for checkin it out
g
Thank you for your patience!