上次更新時間
2021年4月29日
Symptom
The pageinfo.json fails with 500 due to NullPointerException while initializing CQPayloadMap object.
Usually it shows a stacktrace as follow:
Internal Server Error (500)
The requested URL /libs/wcm/core/content/pageinfo.json resulted in an error in com.day.cq.wcm.core.impl.servlets.PageInfoServlet.
Exception:
java.lang.NullPointerException
at com.day.cq.workflow.impl.CQPayloadMap.checkResourceCollection(CQPayloadMap.java:490)
at com.day.cq.workflow.impl.CQPayloadMap.init(CQPayloadMap.java:358)
at com.day.cq.workflow.impl.CQPayloadMap.exists(CQPayloadMap.java:291)
at com.day.cq.workflow.impl.CQPayloadMap.isInWorkflow(CQPayloadMap.java:113)
Resolution
Find workflow instances without "path" property in the payload using CRX Explorer search for example.
Execute the XPATH query: "/jcr:root/etc/workflow//element(*, cq:Payload) [not(@path)]".
For each result found, set a dummy value to the path property.
The CQPayloadMap object can be initialized, later you can find and remove the workflow instances that used the dummy value as path in the Workflow administration.
Applies to
CQ 5.x