-
Notifications
You must be signed in to change notification settings - Fork 119
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
Developers would like to reconfigure Amplify at runtime #560
Comments
Hello, Same issue: on our project we have 2 differents “pools” of users within the same application. Finally we don’t use the same behavior for cognito triggers. On top of those issues, with only 1 user pool we are not able to provide 2 different accounts for the same user (They don’t have the same pricing plans, in fact it’s possible but with a bad user experience: sign out, sign in, sign out, sign in...) We did our backend development with the JavaScript SDK (which work very well with 2 user pools) and now we are doing the “final implementation” on iOS and Android and it’s an hard start for the project. Thank you in advance for your feedbacks. |
This is also something we are looking for on my project. When considering a disaster recovery solution, if a region goes down we would like to be able to reconfigure the application to point to a pool in a different region and have the user login again. It would be preferable if we didn't have to rely on the user correctly restarting the app in this situation and could reconfigure at runtime. |
Would being able to reconfigure amplify allow us to also update DataStore syncExpressions? for example I might start the app with the syncExpression Post.RATING.gt(5) but at runtime I might want to change that expression to be Post.STATUS.eq("ACTIVE") |
Using one user pool is not an option for us with our current setup and changing this setup with our third-parties is not ideal for anyone involved. |
Greetings to all! Any news here? |
Having to ask the user to open the app again because they want to sign into a new pool is disgraceful and distasteful user experience. Any update on when is this getting implemented? |
I have no updates at this time. However, I will relay concerns to our product team, understanding this is a commonly requested feature. |
@tylerjroach Hi! There's another issue which demands to call Amplify.configure more than once. There's a problem with configuring AWS lambda auth for DataStore (GraphQL API). The current implementation demands to provide an auth token in AWSApiPlugin configuration which is followed by Amplify.configure call. As far as we can't call Amplify.configure more than once in Android library, there's no option to provide a different auth token for AWSApiPlugin. Please, look at my comment for more info and a code example #1828 |
@yaroslav-v Responded on the other issue to keep this thread focused on feature request for multiple configures. |
A customer is developing an app using TWO Cognito User Pools.
Customer develops a web app, an Android app and an iOS App.
On their web app, they are able to call
Amplify.configure(configuration);
with one config (Cognito User Pool) or the other, depending on the URL of the app being used.But on Mobile, it seems that once configured, they can not switch to another configuration by calling
Amplify.configure(configuration);
a second time.There is a global configuration lock defined here https://github.com/aws-amplify/amplify-android/blob/master/core/src/main/java/com/amplifyframework/core/Amplify.java#L74
and used here
amplify-android/core/src/main/java/com/amplifyframework/core/Amplify.java
Line 125 in fdb36b4
I also raised an issue against
amplify-ios
: aws-amplify/amplify-swift#527The text was updated successfully, but these errors were encountered: