Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CDK construct can't change and deploy a resolver if changed from @function to custom appsync JS resolver #3057

Closed
jimjiminyjimjim opened this issue Dec 2, 2024 · 3 comments
Labels
pending-community-response Issue is pending a response from the author or community. pending-triage question Further information is requested

Comments

@jimjiminyjimjim
Copy link

jimjiminyjimjim commented Dec 2, 2024

Amplify CLI Version

12.2.5

Question

Following on from this issue #3003 - I can now deploy multiple GSI changes iteratively with the CDK construct. Thanks to @AnilMaktala and @sundersc

The only issue now that seems to cause problems for multiple devs deploying their changes is if a resolver has been created with the @function and attached a lambda, then a dev changes this in the schema and replaces with a custom appsync JS resolver, we get the following error:

12:57:01 PM | CREATE_FAILED
Resource already exists: arn:aws:appsync:us-west....
HandlerErrorCode: AlreadyExists)

In order to deploy we have to remove the @function code, deploy the Appsync api stack, then add our new appsync resolver to the schema and then deploy again.

This is a problem for the committing to a pipeline that deploys live as we'd need to deploy twice to switch changes live?

@jimjiminyjimjim jimjiminyjimjim added pending-triage question Further information is requested labels Dec 2, 2024
@tejas2008
Copy link
Contributor

Hi @jimjiminyjimjim It sounds like you're encountering issues with conflicting resolver resources when switching from a Lambda function-based resolver (@function) to a custom AppSync JS resolver. Could you share a sample code snippet or more details on how the resolvers are being defined in your schema and the CDK stack?

@tejas2008 tejas2008 added the pending-community-response Issue is pending a response from the author or community. label Dec 3, 2024
@AnilMaktala
Copy link
Member

Hey 👋 , This issue is being closed due to inactivity. If you are still experiencing the same problem and need further assistance, please feel free to leave a comment. This will enable us to reopen the issue and provide you with the necessary support.

Copy link

This issue is now closed. Comments on closed issues are hard for our team to see.
If you need more assistance, please open a new issue that references this one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pending-community-response Issue is pending a response from the author or community. pending-triage question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants