hstrack
New Creator

Remote Projects, Datasources and Delta Deployments

Hi,

we have a setup with a some projects for different departments an a common remote project containing a data source for news. 

Selection_858.png

When we release a news from our datasource in the remote project and link it on our news page in the actual project, the detail pages that are generated from the datasource in the remote project are not generated in the delta deployment. So we ending up in an 404. The only possibilities that allow us to deploy the news detail pages are:

1) Full deployment (takes very long, no solution) in the actual project

2) we run a delta deployment only on the news detail page template in the actual project. This generates all news and takes also very more than an hour (there a lot of news)

Selection_859.png

Releasing the news from the local project is no option, there we get an exception

Error creating task - java.lang.IllegalStateException: failed to create workflowable for de.espirit.or.impl.EntityImpl@e0967c61{event,PERSISTENT,fs_id=254592,fs_valid_from=1666593029763,fs_...

What we simple try to reach is a delta deployment for the one or two news pages when the news are relaased. 

The generation is configured as follows:

import de.espirit.firstspirit.access.schedule.*;

deltaGeneration = DeploymentUtil.createDeltaGeneration(context);
deltaGeneration.dependencyRules(EnumSet.of(DependencyRule.PROPAGATE_PAGE_CHANGES,
DependencyRule.PROPAGATE_SECTION_CHANGES,
DependencyRule.PROPAGATE_TEMPLATE_CHANGES, // references pagestore-content based on the changed template will be generated
DependencyRule.PROPAGATE_GCA_CHANGES)); // regenerate content projections if datasets changed

DeltaGeneration.ChangeSet changeSet = deltaGeneration.levelRule(0,1).levelRule(2,4).calculateChangeSet();

changeSet.configureGenerateTask();

So we do not use 

UPDATE_PAGEREF_WHEN_ENTITY_HAS_CHANGED

But this should not be related, isn't it?

Our FS version is 5.2.

 

0 Kudos
3 Replies
hoebbel
Crownpeak employee

Hello hstrack,

i am afraid that this is a problem for which there is (in my opinion) no solution within the Delta Deployment.
To explain, here's some background. The delta deployment checks the revisions of the project to determine if there have been releases since the last time it was run, and uses the appropriate revision information to calculate what needs to be generated.
When a database is mounted read-only in a project, there are no changes to the datasets found within the revisions of the project. (After all, the changes are made in the source project, where the corresponding revisions are created).

A solution could be to write a module, which monitors the release of news in the source project (for example within the release workflow or via the IDProviderEventAgent) and then starts a publication for the detail pages (and if necessary the overview page) in the corresponding target projects.
The list of records to be generated can then be temporarily restricted via API in the page reference so that only the required records are generated.

Best regards
Holger

0 Kudos

Hi Holger,

thank you very much for your detailed answer. To be sure, this means, that a script like this one

 

context.getProject().createTaggedRevision("Generation","needed for external database content");

context.setStartTime(new Date());

 

as described here https://community.crownpeak.com/t5/Questions-Answers/Delta-Generierung-und-CorporateContent/m-p/2449... 

would not help either, right?

 

 

0 Kudos
hoebbel
Crownpeak employee

Hello hstrack,

good query 🙂
Unfortunately, from my understanding, this will not work. It would cause that there is a change in the project (so the start time of the generation is definitely after the changes to the records), but there is still no revision with the release of the affected records. Thus, the delta deployment cannot identify them and will not generate the corresponding detail pages.
A solution approach could be to use the CaaS to submit the database contents to a central location on the frontend and then play out the detail pages via an SPA.

Best regards
Holger

0 Kudos