我正在尝试创建一个CQ
5.4 工作流程来更新启动此工作流程的数字资产图像的描述。CQ
我的问题是,当我编译和构建此代码时,WorkFlow Process 没有出现在5.4 作者服务器实例中的 Process Step 下拉列表中。
这是代码,如果需要任何其他步骤或者我在某处做错了,请告诉我,
import org.apache.felix.scr.annotations.Component;
import org.apache.felix.scr.annotations.Properties;
import org.apache.felix.scr.annotations.Property;
import org.apache.felix.scr.annotations.Service;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import com.day.cq.dam.commons.process.AbstractAssetWorkflowProcess;
import com.day.cq.workflow.WorkflowException;
import com.day.cq.workflow.WorkflowSession;
import com.day.cq.workflow.exec.WorkItem;
import com.day.cq.workflow.exec.WorkflowProcess;
import com.day.cq.workflow.metadata.MetaDataMap;
@Component
@Service(WorkflowProcess.class)
@Properties({
@Property(name = "service.description", value = "Update the Image Description"),
@Property(name = "service.vendor", value = "******"),
@Property(name = "process.label", value = "Update the Image Description") })
public class RemoveImgPropBatchWorkFlowProcessStep extends AbstractAssetWorkflowProcess{
private static final Logger log = LoggerFactory.getLogger(RemoveImgPropBatchWorkFlowProcessStep.class);
@Override
public void execute(WorkItem workItem, WorkflowSession workFlowSesion, MetaDataMap meta)
throws WorkflowException {
// TODO Auto-generated method stub
log.info("RemoveImgPropBatchWorkFlowProcessStep Workflow called up");
workItem.getNode().setDescription("Image is updated");
}
}