Question
· Sep 29, 2016

Migrating project from dev to prod

Hi All

 

I have a question on working with dev and prod environments.

 

After project is ready and signed, I usually migrate outcome to production using the export tool from the studio.

For changes/adding to existing projects, I exclude the production class (as it has some different values differing the dev from the live) and I add the differences manually afterwards.

 

My questions on migrating are:

Does anyone has (to share) his/her best practice steps on "migrating dev to prod"?

Does the export action (in management portal) is better to use?

Thanks

Gadi

Discussion (2)0
Log in or sign up to continue

You can use conditional compilation to differentiate between live and dev as below (PRP is our live). So $$$debug(x) either shows the value in x on the screen in test or does nothing in live. Slight disadvantage is that what you test is not EXACTLY identical to what you run in live - but that's going to be the case anyway if you are "adding differences afterwards". 

 #if $NAMESPACE'="PRP"
 ; ############### test environment includes debug code
 #Define debug(%var) Write @(%var)
 #Define CSPdebug(%prog,%var) S MACROT2=$P($ZTIMESTAMP,",",2),^CSPLOG(%prog,+$H,MACROT2,"%var")=$D(%var)_"`"_$G(%var)
 #Define CSPdebugfull(%prog,%var) S MACROT2=$P($ZTIMESTAMP,",",2),^CSPLOG(%prog,+$H,MACROT2,"%var")=$D(%var)_"`"_$G(%var) I $D(%var)>1 S MACROT1="%var" F  S MACROT1=$Q(@MACROT1) Q:MACROT1=""  S ^CSPLOG(%prog,+$H,MACROT2,MACROT1)="`"_@MACROT1
 #Define CSPdump(%prog) S MACROT2=$P($ZTIMESTAMP,",",2),MACROT3="" F  S MACROT3=$O(@MACROT3) Q:MACROT3=""  S ^CSPLOG(%prog,+$H,MACROT2,MACROT3)=$D(@MACROT3)_"`"_$G(@MACROT3) I $D(@MACROT3)>1 S MACROT1=MACROT3 F  S MACROT1=$Q(@MACROT1) Q:MACROT1=""  S ^CSPLOG(%prog,+$H,MACROT2,MACROT1)="`"_@MACROT1
 ; ############### end test environment includes debug code
 #else
 ; ############### live environment no debug code
 #Define debug(%var)
 #Define CSPdebug(%prog,%var)
 #Define CSPdebugfull(%prog,%var)
 #Define CSPdump(%prog) 
 #endif