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

@function for pipeline (execute) before without removing actual resolver #489

Open
2 tasks
UXDart opened this issue May 20, 2021 · 7 comments
Open
2 tasks
Labels
feature-request New feature or request GraphQL

Comments

@UXDart
Copy link

UXDart commented May 20, 2021

Is this related to a new or existing framework?

React

Is this related to a new or existing API?

GraphQL API

Is this related to another service?

No response

Describe the feature you'd like to request

use of function but for pipeline "before" the resolver that automatically is used. I dont want to replace the resolver but add a function, this can work as a way to give or not permission to execute

Describe the solution you'd like

an argument to @function(before: true) it would be good also a (after: true) so we can add a function without removing the actual resolver that is used automatically

Describe alternatives you've considered

manually on console, but if something goes wrong I lose all the configuration and also it could be the same function, so adding a line in the schema would be way faster I think

Additional context

No response

Is this something that you'd be interested in working on?

  • 👋 I may be able to implement this feature request
  • ⚠️ This feature might incur a breaking change
@UXDart UXDart added the feature-request New feature or request label May 20, 2021
@UXDart
Copy link
Author

UXDart commented May 20, 2021

I looked everywhere I couldn't find a way to do this, but maybe there is already a way? TIA

@UXDart
Copy link
Author

UXDart commented May 20, 2021

btw I could try to implement this and create a PR

@UXDart
Copy link
Author

UXDart commented May 20, 2021

I just found this aws-amplify/amplify-cli#3321 is there any doc explaining more about this? thanks

@UXDart
Copy link
Author

UXDart commented May 20, 2021

sorry but question, if I attach manually in appsync the resolvers as pipelines, amplify could possibly destroy them and recreate them right? which means I lose the resolvers manually configured

@UXDart
Copy link
Author

UXDart commented May 20, 2021

the way to work with this is using VTL resolvers? not sure why I can't find good docs about this... tia

@UXDart
Copy link
Author

UXDart commented May 21, 2021

anyone? what is the best way to solve this? I would prefer to write the logic inside a function tbh, don't like the vtl too much, also in some cases the logic can become very complex, in a function I can write anything I want. also I can re use same function. so that would be a pipeline function "before" the actual auto resolver. is that possible using amplify? Thanks!

@UXDart
Copy link
Author

UXDart commented May 27, 2021

I read in another post that something is WIP about this? to have JS as a pipeline resolver? is there any (not eta) but some idea when this can be start to be used? thanks

@stocaaro stocaaro transferred this issue from aws-amplify/amplify-js Jan 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request New feature or request GraphQL
Projects
None yet
Development

No branches or pull requests

2 participants