How to revert a provisioning

Let say you have a C3 production environment with version 1.0.0 of your project deployed. Everything works fine, but you want now to deploy version 1.1.0 of your code to improve performance of your algorithms. You provision to the environment, but after a while, you realise your QA process missed some critical issue.

Is it possible to do a clean revert of the last provisioning you did ? If yes do you know the command to perform the revert ?

This is a virtual scenario, but we are not feeling confident with a checkout to the tag 1.0.0 and provision back the version 1.0.0 of the code as it does not feel we are really going back to initial situation that way (considering incremental provisioning). Maybe it is not founded.

Normally, you should deploy to the production environment only tested artifacts produced by c3’s CI process. These are stored in C3 Package Manager. Documentation on this process can be found in the doc: “Automated Build & Deploy Process”.

If you deploy someting to production that is not behaving correctly, that should be adressed as a process failure and the team should have a meeting to identify the problem in the process and avoid it in the future.

That being said, downgrading from 1.1.0 to 1.0.0 is as simple as deploying 1.0.0. The preferred api for this is Tag.deploy({tenant: YOUR_TENANT, tag: YOUR_TAG, package: YOUR_PACKAGE, packageVersion: '1.0.0')} Please note that if you have done a data migration as part of deploying 1.1.0, you will not be able to undo that migration except manually.

I see; thank you very much @rileysiebel for your answer and advice ! :slight_smile: