Details
-
Bug
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
OpenCMIS 0.13.0
-
None
-
Client 0.13.0 / bridge 0.13.0
Description
Hi,
The following code raises an NPA when using opencmls bridge with atompub binding. The bridge is using the stock SimpleForwardingCmisService.
There is no problem when connecting directly to the target cmis service (nuxeo 7.10).
public void BridgeNPE () {
Folder rootFolder = directCmisSession.getRootFolder();
Folder subFolder = FileUtils.createFolder(rootFolder, "TestNPA", "cmis:folder");
FileUtils.createTextDocument(subFolder.getId(), "test.txt", "dummy content", "cmis:document", VersioningState.MAJOR, directCmisSession);
cmisSession.clear();
OperationContext opContext = OperationContextUtils.createMaximumOperationContext();
ItemIterable<CmisObject> childrenWithOpContext = subFolder.getChildren(opContext);
for (CmisObject child: childrenWithOpContext) {
if (child instanceof Document)
}
/* The same without opContext
ItemIterable<CmisObject> children = subFolder.getChildren();
for (CmisObject child: children) {
if (child instanceof Document){ ((Document) child).getPaths(); }
}
*/
}