Expand my Community achievements bar.

AEM 6.1 reverse replication single wofklow launcher for multiple node types

Avatar

Level 3

Hi,

We are using AEM 6.1 SP1. We have created an AEM form for registration which has 'Store Content' submit action and it takes firstname, lastname and an image from user as input. Upon submission the details are stored under /content/usergenerated... (both text and image attachment). 

We want these details to be approved by workflow in author instance. So we reverse replicated it back to Author using workflow launcher. However, here we are facing issue that it reverse replicates only one of the two. Either text properties (when node type selected is sling:Folder) or image attachment (when node type selected is nt:file) in workflow launcher. 

Is there any way we can have single workflow launcher which listens to both the node types and reverse replicate in single operation? Creating two different workflow launchers might also lead to race condition?

2 Replies

Avatar

Level 10

RonakB wrote...

Is there any way we can have single workflow launcher which listens to both the node types and reverse replicate in single operation? Creating two different workflow launchers might also lead to race condition?

Firstly there is no option to your specific questions.    However simple case made complex here. When you save form make sure all the properties & image are under one parent node. Then reverse replicate the same.   Additional make use of sling distribution rather than reverse replication.

Avatar

Level 3

Thanks for your reply Sham. 

We are using File Attachment component for accepting image from user. This component stores image under the structure: /FormInstancexxxx/subfolder/myfile.jpg

Attached screenshot   

The text inputs are stored as properties at sling:folder FormInstancexxxx whereas myfile.jpg is stored under subfolder as nt:file. 

Is there any way, we can configure File Attachment component to store file directly as property of FormInstancexxxx ?

Also, when I triage normal reverse replication, it only reverse replicates the folder whose path I pass in the payload. If it has files under it, they are not reverse replicated to author instance. Is this right behavior or I am missing something ?