Restoring custom app after cloning

Rick Marsha
Giga Expert

So, here's my scenario:

-Built a custom scoped app in DEV instance

-Published app to PROD instance and installed as a release

-Exported the app from DEV as an update set

-Cloned PROD instance over DEV

-Imported update set to DEV after cloning

My issue is that when I imported my update set back to DEV, it didn't restore to 'sys_app'. The app package didn't seem to import and is not editable. Has anyone encountered this issue yet? I'd like to avoid rebuilding it from scratch.

1 ACCEPTED SOLUTION

Rick Marsha
Giga Expert

After an insightful discussion with SN support, there are a few different issues at play:


- The cloning process doesn't preserve the original sys_app (app creator) record for a custom app that was created in the target clone instance


- The 'Publish to update set' feature doesn't include the sys_app record, but creates the update set from a customer perspective (should be optional to include, IMO)


- The target clone instance receives the sys_remote_app & sys_store_app (app repository) records for the custom app from the source clone instance, and ACLs prevent the customer from deleting the records on the target clone instance. This could be by design, but mucks up the DEV instance with app store installs I originally pushed to PROD.




Their recommendation was to restore my DEV instance from backup and retrieve the sys_app record, but I'm choosing to build another app container for my code since it was a small app. Their workaround to avoid this issue in the future is below.




BEFORE the clone, on the source clone instance:


1) Add sys_app to the "Exclude Tables" module


2) Add sys_app to the "Preserve Data" module, and make sure "Theme" is false



Thanks,


-Rick


View solution in original post

9 REPLIES 9

ravish2
Giga Expert

You should be in global update set before uploading and commiting the update set- i guess


Rick Marsha
Giga Expert

After an insightful discussion with SN support, there are a few different issues at play:


- The cloning process doesn't preserve the original sys_app (app creator) record for a custom app that was created in the target clone instance


- The 'Publish to update set' feature doesn't include the sys_app record, but creates the update set from a customer perspective (should be optional to include, IMO)


- The target clone instance receives the sys_remote_app & sys_store_app (app repository) records for the custom app from the source clone instance, and ACLs prevent the customer from deleting the records on the target clone instance. This could be by design, but mucks up the DEV instance with app store installs I originally pushed to PROD.




Their recommendation was to restore my DEV instance from backup and retrieve the sys_app record, but I'm choosing to build another app container for my code since it was a small app. Their workaround to avoid this issue in the future is below.




BEFORE the clone, on the source clone instance:


1) Add sys_app to the "Exclude Tables" module


2) Add sys_app to the "Preserve Data" module, and make sure "Theme" is false



Thanks,


-Rick


Thanks for posting your solution Rick, we were having a similar problem as cloning and reinstalling the custom app manually via update set was essentially making it read only with no option to update! Finally, I can stop taking headache tablets for this!


The workaround is no longer necessary to preserve custom applications.


The clone engine has been corrected to preserve any custom applications or updates to these applications as long as they have been uploaded to the store or repository.


Development on these applications can continue as normal after the clone.


Any changes that have not been uploaded to the app store or repository will be lost.