Amplify can detect and integrate with Appsync-backing Dynamo table streams when adding Function
See original GitHub issueIs your feature request related to a problem? Please describe.
When creating a lambda with amplify function add
, Amplify should provide the option to integrate with a Dynamo Stream from tables associated with Appsync apis. Currently, Amplify does not appear to detect these tables.
Describe the solution you’d like The integration described above.
Describe alternatives you’ve considered
Used amplify function add
to create a Hello World lambda, then (1) manually updated lambda permissions in generated CloudFormation and (2) added connection to Dynamo Stream in the Dynamo console.
Additional context
Using version 1.1.30
, here is CLI experience where Amplify did not find the Appsync-integrated DynamoDB tables:
> amplify function add
Using service: Lambda, provided by: awscloudformation
? Provide a friendly name for your resource to be used as a label for this category in the project: myNewLambdaFunction
? Provide the AWS Lambda function name: myNewLambdaFunction
? Choose the function template that you want to use: CRUD function for Amazon DynamoDB table (Integration with Amazon API Gateway and Amazon Dy
namoDB)
? Choose a DynamoDB data source option Use DynamoDB table configured in the current Amplify project
There are no DynamoDB resources configured in your project currently
? Choose a DynamoDB data source option
❯ Use DynamoDB table configured in the current Amplify project
Create a new DynamoDB table
Issue Analytics
- State:
- Created 4 years ago
- Reactions:3
- Comments:6 (1 by maintainers)
Top Results From Across the Web
Amplify can detect and integrate with Appsync-backing ...
When creating a lambda with amplify function add , Amplify should provide the option to integrate with a Dynamo Stream from tables ......
Read more >Enhancing Amazon DynamoDB single-table design with AWS ...
Developers utilize AppSync to connect applications to data sources such as Amazon DynamoDB tables.
Read more >AWS Amplify with Amazon DynamoDB Single Table and ...
Your browser can 't play this video. ... AWS Amplify with Amazon DynamoDB Single Table and Direct AWS Lambda Resolvers with Rick Houlihan....
Read more >GraphQL APIs with AppSync, Amplify and Angular - YouTube
AWS AppSync automatically updates the data in web and mobile applications in real time, and updates data for offline users as soon as...
Read more >Timeline feature: @function
In $ amplify add function , several templates are available. For example, if you select Lambda Trigger , you can set up DynamoDB...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
You can modify the function’s cloudformation template to add the event source mapping since every table’s stream arn is exported. An example:
The import value is a direct copy from the Outputs -> Export property in your table’s autogenerated cloudformation stack.
You probably also need to update your function properties in backend-config.json to add a dependsOn for the AppSyncApiId property if it isn’t already.
This issue has been automatically locked since there hasn’t been any recent activity after it was closed. Please open a new issue for related bugs.
Looking for a help forum? We recommend joining the Amplify Community Discord server
*-help
channels for those types of questions.