활동이 없어 이 대화는 잠겼습니다. 새 게시물을 작성해 주세요.
활동이 없어 이 대화는 잠겼습니다. 새 게시물을 작성해 주세요.
Hi,
I am trying to upgrade workflow from CQ 5.4 to 5.6.1 I am trying to invoke customized workflow which extends AbstractAssetWorkflowProcess.
so trying to get asset in execute method but getting null pointer exception while fetching asset using getAssetFromPayload method.
public void execute(WorkItem workItem, WorkflowSession wfSession, MetaDataMap metaData) throws WorkflowException {
Session session = wfSession.getSession();
final Asset asset = getAssetFromPayload(workItem, session);
.....
.....
}
Can any one please let me know I need to upgrade currently I am using cq-workflow-api version 5.6.2.
regards
Rajesh Karka
해결되었습니다! 솔루션으로 이동.
조회 수
답글
좋아요 수
Make sure right version of api is used. You might need to change from [1] to [2].
[1]
import com.day.cq.workflow.WorkflowException;
import com.day.cq.workflow.WorkflowSession;
import com.day.cq.workflow.exec.ParticipantStepChooser;
import com.day.cq.workflow.exec.WorkItem;
import com.day.cq.workflow.exec.WorkflowData;
import com.day.cq.workflow.metadata.MetaDataMap;
[2]
import com.adobe.granite.workflow.WorkflowException;
import com.adobe.granite.workflow.WorkflowSession;
import com.adobe.granite.workflow.exec.ParticipantStepChooser;
import com.adobe.granite.workflow.exec.WorkItem;
import com.adobe.granite.workflow.metadata.MetaDataMap;
조회 수
답글
좋아요 수
Make sure right version of api is used. You might need to change from [1] to [2].
[1]
import com.day.cq.workflow.WorkflowException;
import com.day.cq.workflow.WorkflowSession;
import com.day.cq.workflow.exec.ParticipantStepChooser;
import com.day.cq.workflow.exec.WorkItem;
import com.day.cq.workflow.exec.WorkflowData;
import com.day.cq.workflow.metadata.MetaDataMap;
[2]
import com.adobe.granite.workflow.WorkflowException;
import com.adobe.granite.workflow.WorkflowSession;
import com.adobe.granite.workflow.exec.ParticipantStepChooser;
import com.adobe.granite.workflow.exec.WorkItem;
import com.adobe.granite.workflow.metadata.MetaDataMap;
조회 수
답글
좋아요 수
Have you read this document that talks about upgrading - including workflows: http://dev.day.com/docs/en/cq/current/deploying/upgrading.html ?
Please let us know. Thxs!
조회 수
답글
좋아요 수
Hey Sham,
I have one question here. As per your comment if we want to upgrade we need to re compile again our workflow code?
Hi Sham,
As per the documentation AbstractAssetWorkflowProcess is still using CQ workflow API and not included granite workflow API. All my workflows are using AbstractAssetWorkflowProcess which is causing Null pointer Exception while getting resource resolver inside Abstract asset workflow process. But there are lot of OOTB workflows are using this class and working fine.
Caused by: java.lang.NullPointerException
at com.day.cq.dam.commons.process.AbstractAssetWorkflowProcess.getResourceResolver(AbstractAssetWorkflowProcess.java:253)
at com.day.cq.dam.commons.process.AbstractAssetWorkflowProcess.getAssetFromPayload(AbstractAssetWorkflowProcess.java:90)
at com.aptimus.common.workflow.FFMpegTranscodeProcess.execute(FFMpegTranscodeProcess.java:87)
regards
Rajesh Karka
조회 수
답글
좋아요 수
Might need further investigation then. File a daycare ticket.
조회 수
답글
좋아요 수
I would always recommend to see the api difference [1] & update your code base accordingly.
[1]
http://dev.day.com/docs/en/cq/current/diff-previous/changes.html
http://dev.day.com/docs/en/cq/5-6/diff-previous/changes.html
조회 수
답글
좋아요 수
We are hitting the exact same problem here after upgrading from 5.5 to 6.0. Was there ever a Daycare ticket filed for this? If so, do we have a solution?
Thanks!
조회 수
답글
좋아요 수