amplify-cli icon indicating copy to clipboard operation
amplify-cli copied to clipboard

Deleting Cognito Pool = unrecoverable state?

Open ghost opened this issue 6 years ago • 5 comments

The user pool for one of my envs was accidentally deleted, which seemingly prevents any further interactions via Amplify CLI from working successfully. In fact, I can't even remove the user pool through amplify auth remove because apparently "other amplify dependencies rely on this resource".

Is this environment just permanently broken and beyond recovery? Seems like an incredibly fragile setup if that's the case.

ghost avatar Feb 06 '20 23:02 ghost

@dan-rxr If you deleted your cognito user pool and all your other resources depend on it - then the authorization for that wouldn't work. I would create a new environment if you do not want to re-create all the resources again. This would create a new userpool for you as well.

kaustavghosh06 avatar Feb 10 '20 05:02 kaustavghosh06

It is funnier than you think...if you make changes to an unmodifyable property of a UserPool(e.g. custom attributes) created by amplify outside of an amplify push(via cli or web console) then you also get into an unrecoverable state. There are several sharp edges you have to look out for.

Is there anything we can do to make this a better experience? e.g. split out the UserPools from the main cf stack and have a parallel system of cf-stacks to handle them, where we can force delete them and repair references prior to managing the rest of an amplify project? or do we wait for UserPools to be less brittle and allow for updating of all properties? (I'm not across the limitations of why there are immutable properties of UserPools - I'm assuming a technical limitation in the current implementation)

dconlon-wagetap avatar Mar 30 '20 00:03 dconlon-wagetap

@dconlon-monigo We've raised these concerns to the Cognito team regarding the immutable properties of user-pools and they're actively working on making this experience better.

kaustavghosh06 avatar Mar 30 '20 19:03 kaustavghosh06

Do you have some news about this ? How can we recover from a deleted user pool ? This is a great concern for us too, especially regarding our production

maximelebastard avatar Nov 16 '20 15:11 maximelebastard

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.

github-actions[bot] avatar Jun 01 '21 18:06 github-actions[bot]