Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
Open Deploy
mohit_maniar
Hi,
I want some information on how Open Deploy manages a Transaction.
Example:
I have a folder ABC with 100 modified files under my staging [source] and same Folder ABC with 100 files on production server[Target]. I have a requirement while deployment that if transaction fails then all deployed files should be reverted back.
I have some queries on above example:
1. Where does open deploy caches or stores the Folder ABC on Production server [Target] while deployment so as to revert back to it's original place incase any failure happens during deployment from source [staging] to target [Production].
2. Can we use customized perl scripts or java code using OD API's to ensure the deployment rollback and commit phases?
Thanks in advance.
-Mohit.
Find more posts tagged with
Comments
Adam Stoller
1. Where does open deploy caches or stores the Folder ABC on Production server [Target] while deployment so as to revert back to it's original place incase any failure happens during deployment from source [staging] to target [Production].
You probably need to do some RTFM'ing and/or training - but basically TS uses file and/or directory name extensions for the target files and then does a "shell-game" of putting them into place after all files have been deployed. I might be wrong on the exact naming, but it goes something like this:Transfer all files (e.g. foo, bar, etc.) from the source location to the target location with an added extension (e.g. foo.iw_new, bar.iw_new)If transfering a directory (not sure if it's just new, just old, or both) do the same with the directory name (e.g. /foo => /foo.iw_new)Once all files have been successfully deployed (or perhaps during the process of performing the transfer) copy all to-be-replaced files and/or directories on the target server with an extension (e.g. foo, bar, etc. => foo.iw_old, bar.iw_old, /foo => /foo.iw_old)Once there are 3 copies of each and every file (foo, foo.iw_new, foo.iw_old) the begin moving all the files into place (e.g., foo.iw_new => foo)Once all new files have been moved into place, remove all the old files (e.g. remove all *.iw_old files)With the exception of the very last step (I believe), if OD determines a problem in the deployment - all *.iw_old files will be moved
back
into place and all *.iw_new files will be (I believe) removedWith the newer versions of OD you can specify a location for all the temporary files to be written (e.g. /var/tmp) rather than the default, which is to create the temporary files adjacent to the actual files (e.g., /foo/bar, /foo/bar.iw_new, /foo/bar.iw_old)
2. Can we use customized perl scripts or java code using OD API's to ensure the deployment rollback and commit phases?
Not sure - either what you expect you would be doing that OD isn't itself doing, or whether it's possible to do so.
--fish
Senior Consultant, Quotient Inc.
http://www.quotient-inc.com
mohit_maniar
Hi,
Your explaination gave me good understanding to how files will be managed during a transaction.
As you have mentioned about "shell-game", could you please point out some documents or article to refer? It will be more helpful to me to understand more inner concept and design my deployment script file.
-Mohit
Adam Stoller
Have you tried reading the OD manuals? I believe this is covered within there to some degree.
Other than that - I don't think there's anything to point you to. As one might suspect, this is a commercial product and they are unlikely to publish a lot of internal details (both from a competitive standpoint and from the standpoint that the internals can change at any time - and it shouldn't matter to the customer [unless it stops working])
--fish
Senior Consultant, Quotient Inc.
http://www.quotient-inc.com