Difference between revisions of "How to work with Solution Patches"
Line 3: | Line 3: | ||
Imagine that you have your solution live in a production environment and you are about to start a new big project. During this project it might be the case that you need to do a smaller update/fix in the production environment, but you will not be able to do that from the DEV environment where you are working with your big new project. Because there will be changes you do not want to add to production yet. In the future you could potentially use Settings for this, but for now and an alternative approach is to make a copy of DEV to another environment before you start with your new project. In that temporarily DEV environment you could do the small fix and create a patch to import to the production environment. | Imagine that you have your solution live in a production environment and you are about to start a new big project. During this project it might be the case that you need to do a smaller update/fix in the production environment, but you will not be able to do that from the DEV environment where you are working with your big new project. Because there will be changes you do not want to add to production yet. In the future you could potentially use Settings for this, but for now and an alternative approach is to make a copy of DEV to another environment before you start with your new project. In that temporarily DEV environment you could do the small fix and create a patch to import to the production environment. | ||
− | + | Here follows an example: | |
+ | |||
+ | 1. Make sure it is the same version of the solution in "your new DEV" as in Production. If not, adjust version in "your new DEV". | ||
+ | 2. Make a Clone of the solution in "your new dev". Under the Solution -> Clone -> Clone a Patch. | ||
+ | 3. You will then get a new Solution and in that Solution you do the changes you want to do, which are meant to be the "fix for production". | ||
+ | 4. Import the Patch to Production. | ||
+ | 5. Make sure to do the same change in the "real DEV" environment. Either by doing it manually or by adding the components to an unmanaged solution in "your new DEV" and import to "real DEV". | ||
+ | 6. The next time a deployment of the whole solution is done from "real dev" to Production, all Patches will be merged and you will get one solution in Production. | ||
== Microsoft Resources == | == Microsoft Resources == |
Revision as of 15:41, 21 December 2021
Sometimes when working with Solutions you might not need a full deployment of the whole solution, here patches come in.
Imagine that you have your solution live in a production environment and you are about to start a new big project. During this project it might be the case that you need to do a smaller update/fix in the production environment, but you will not be able to do that from the DEV environment where you are working with your big new project. Because there will be changes you do not want to add to production yet. In the future you could potentially use Settings for this, but for now and an alternative approach is to make a copy of DEV to another environment before you start with your new project. In that temporarily DEV environment you could do the small fix and create a patch to import to the production environment.
Here follows an example:
1. Make sure it is the same version of the solution in "your new DEV" as in Production. If not, adjust version in "your new DEV". 2. Make a Clone of the solution in "your new dev". Under the Solution -> Clone -> Clone a Patch. 3. You will then get a new Solution and in that Solution you do the changes you want to do, which are meant to be the "fix for production". 4. Import the Patch to Production. 5. Make sure to do the same change in the "real DEV" environment. Either by doing it manually or by adding the components to an unmanaged solution in "your new DEV" and import to "real DEV". 6. The next time a deployment of the whole solution is done from "real dev" to Production, all Patches will be merged and you will get one solution in Production.