12-18-2020 05:05 AM
12-18-2020 12:00 PM
The error comes when a node doesn't exists as indicated :
org.alfresco.service.cmr.repository.InvalidNodeRefException: Node does not exist
Are you sure that node exists in the repository where you are executing the code?
Also, it is a good idea to always check node existance before trying to extract node properties or performing any operation using the nodeRef on a node.
NodeRef connectedDocument = new NodeRef(stringRepresentationOfaNode); if (nodeService.exists(connectedDocument )) { Serializable nodePropMark = nodeService.getProperty(connectedDocument, NDBaseDocumentModel.PROP_MARK) } else { //LOG or report error }
12-20-2020 05:26 AM
I abolutely sure the node DOES exist, and I can see that node in NodeBrowser and the defined property also exists. Morover the same node works with similar code in certain place of programm. but fails in another. Probably there is something with environment.
Explore our Alfresco products with the links below. Use labels to filter content by product module.