Staging Sync Issue in Portal engine

Chandra Bhattarai asked on April 8, 2021 03:56

I am facing two issue in staging synchronization. Actually what is happening is:

  1. When i make page with adhoc template then it is not being synced on production. The message in production for that page is like this: The file '/CMSVirtualFiles/Templates/AdHoc/SC/d3/d31c5418-c653-45e1-8038-9a12349981b6.ascx' does not exist.

  2. The code written in page transformation is not being synced in production. It says synced successfully but when we visit the source code of page transformation in production then the code from staging is not there.

Can you please help me out.

Recent Answers


Juraj Ondrus answered on April 8, 2021 05:35

Hi, What version of Kentico are you using? I would recommend checking the documentation on what can be synchronized.
It looks like you are using pre-compiled project on production which means the deployment mode is on. I am assuming it since the system is looking for the virtual file on disk and cannot find it. And if you check the staging docs, it says that in this setup the staging is not fully supported

"Object code stored and edited in physical files via deployment mode or source control mode
- On source servers, staging tasks are generated only if you edit code in the Kentico UI or after you synchronize changes from files into the database.
- On target servers, staging tasks do not update object code if deployment or source control mode is enabled."

So, this means if you are using pre-compiled project on the target, that you need to save the virtual files to disk on the source instance and perform the pre-compilation/publishing again and move the project files to the production server again. And the same applies for transformations as those are virtual objects too.

1 votesVote for this answer Mark as a Correct answer

Chandra Bhattarai answered on April 8, 2021 07:00

Hi @Juraj, I am using v11.0.34 . Is there any other way to make it even with using pre-compiled project? If i click the 'Synchorinize changes to database' button after changes done in staging, do it works on pre-compiled too?

0 votesVote for this answer Mark as a Correct answer

Juraj Ondrus answered on April 8, 2021 07:12 (last edited on April 8, 2021 07:12)

I am afraid that this is not possible - when you use precompiled project, the virtual objects must be stored on disk. If you synchronize them to the DB - the data will be there, but the system will still look for them on disk since in a precompiled project the VirtualPathProvider cannot run and system cannot find the virtual objects in the DB. This means that after you make changes on your source instance, which is not precompiled, you need to save the virtual objects to disk and precompile the project again and deploy to the target instance.

1 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.