· Apr 20, 2022 4m read

Method to recompile classes and routines after a major upgrade

During a major version upgrade it is advisable to recompile the classes and routines of all your namespaces (see Major Version Post-Installation Tasks).

do $system.OBJ.CompileAllNamespaces("u")
do ##Class(%Routine).CompileAllNamespaces()

To automate this administration task and keep a log of any errors, below is an example of a class to import and compile into the USER namespace that you can use after each upgrade : admin.utils.cls

 Class admin.utils.cls

After upgrading, just run the admin.utils.upgrade method from an IRIS Terminal session :

USER>do ##class(admin.utils).upgrade()

And see the result from the administration portal via the explorer System > Globals > upgradeLog

Discussion (3)1
Log in or sign up to continue