1 year ago

#377705

test-img

Martin Gressler

How to return from a AWS Appsync resolver pipeline without throwing an error

I have a resolver pipeline where I check to see if an item exists. If it does not I want to start a lambda which will create the data. If the queried item exists already I want to return from the pipeline altogether without executing the lambda. It seems AWS provides the following solutions:

#return 

This only returns from the current request mapping template.

$util.error

This prevents subsequent functions from being executed by throwing an error immediately.

I want the functionality of $util.error without throwing an error but instead just returning the result from the current function. Is there a way to do this?

amazon-web-services

aws-appsync

resolver

vtl

0 Answers

Your Answer

Accepted video resources