-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Allow File S3Adapter recieve an async function to retrieve config object #2960
Conversation
…ltionship many See packages/fields/src/types/Relationship/README.md BREAKING CHANGE: Not working styles
…clude styled components
…ve classes to styled components
Use this branch as updater and be able to have multiple requests
…3Adapter with an async function This allows the user to generate a dynamic options object which may require some async operation to get data/secrets
…-2 | Fix typo in README.md
🦋 Changeset is good to goLatest commit: 1cbe0c7 We got this. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
This feels a bit extraneous. What prevents you from just running the async code in a helper to fetch the value before constructing the S3 adapter? |
I have my lists that use the S3Adapter in different files, meaning they need the S3Adapter to be constructed by the time it's exported. There's no way to have the export to wait for the async code to be run before exporting the list |
I think I agree with @Vultraz on this one. You can always make your files export list-generator functions which can accept the adapter at the appropriate time, rather than relying on the In a more general sense, I'd like to avoid ending up in a place where all of our classes which take config work with |
The idea behind this is that the
secretAccessKey
is not directly accessible, but through a vault which is a async operation.This way the S3 adapter can be used keeping the secrets, or being created with any kind of async operation in mind.