You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This makes impossible to fix the issue when the resources were once successfully pushed but at a later time changes in the functions makes the nested stack go over the 100000 bytes limit.
As a workaround once can completely remove the resolver function, execute amplify push, add the resolver function back and map it to a new nested stack and execute amplify push again
Code method that is reverting the StackMapping content can be found here:
I've tried to reproduce this using the latest 10.7.3 version of CLI and did not run into this issue. Using amplify api gql-compile successfully generates the newly added UpdateTestStack stack and removes the Get and List resolvers from the CustomTestStack stack. However, I ran into another issue that we're tracking where if we move the resolvers between 2 CFN stacks, it causes a race condition during deploy causing the stack updates to fail. Refer to this comment
Before opening, please confirm:
How did you install the Amplify CLI?
npm
If applicable, what version of Node.js are you using?
v14.19.1
Amplify CLI Version
8.5.0
What operating system are you using?
macOS
Did you make any manual changes to the cloud resources managed by Amplify? Please describe the changes made.
no
Amplify Categories
api
Amplify Commands
push
Describe the bug
transform.conf.json
StackMapping entries gets reverted for already pushed resources.doc link: https://docs.amplify.aws/cli/graphql/override/#place-appsync-resolvers-in-custom-named-stacks
This makes impossible to fix the issue when the resources were once successfully pushed but at a later time changes in the functions makes the nested stack go over the 100000 bytes limit.
As a workaround once can completely remove the resolver function, execute
amplify push
, add the resolver function back and map it to a new nested stack and executeamplify push
againCode method that is reverting the
StackMapping
content can be found here:amplify-category-api/packages/graphql-transformer-core/src/util/amplifyUtils.ts
Lines 160 to 220 in 6c2880f
Expected behavior
StackMapping definitions needs to be reflected in generated nested stack template even after the resources were once pushed.
Reproduction steps
StackMapping
totransform.cont.json
amplify push
transform.conf.json
StackMapping
toamplify api gql-compile
oramplify push
will revert theStackMapping
contentGraphQL schema(s)
# Put schemas below this line
Log output
Additional information
No response
The text was updated successfully, but these errors were encountered: