[MNT-14275] ImporterComponent throws org.jaxen.saxpath.XPathSyntaxException if import binding is UUID_BINDING.UPDATE_EXISTING and childname has space Created: 25-Jun-15  Updated: 12-Feb-16  Resolved: 21-Aug-15

Status: Closed
Project: Service Packs and Hot Fixes
Component/s: Repository
Affects Version/s: 5.0.1
Fix Version/s: 5.0.3

Type: Service Pack Request
Reporter: Jennie Soria [X] (Inactive) Assignee: Closed Bugs (Inactive)
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: 0 minutes
Time Spent: 1 day, 6 hours, 30 minutes
Original Estimate: Not Specified


Attachments: Text File SiteBootstrapExecutorUPDATE_EXISTING.txt     XML File concept-library-folders.xml     Text File diffImporter5005.501.txt    
Issue Links:
Bug Priority:
Category 3
ACT Numbers:


Build Location: https://releases.alfresco.com/Enterprise-5.0/5.0.3/build-00084/ALL/
Regression Since:


Given that we do not list import/export service in the public API, see ref: http://docs.alfresco.com/5.0/concepts/java-public-api-list.html, the following was discovered and likely needs to be reviewed/addressed as it looks like a minor fix.

When using ImporterBinding where the UUID_BINDING is set to

If the childName contains a space for example the xml has the following:

<cm:folder view:childName="cm:Vollständige Konzepte">

then it throws error similar to this

"org.jaxen.saxpath.XPathSyntaxException: null/cm:Vollständige Konzepte: 21: Unexpected 'Konzepte'"

It looks like the ImporterComponent.java method UpdateExistingNodeImporterStrategy was updated in v5.0.1 Alfresco One, lines #1608-1621 added the "if (uuid==null)" to include this:

//Resolve to path within node, if one specified
String path = location.getPath() + "/" + QName.createQName(node.getTypeDefinition().getName().getNamespaceURI(), node.getChildName()).toPrefixString();

This looks like where this issue is propagating from.

Attached customer's example class and the xml file used to test as well as svn diff to 5.0.1 /root/projects/repository/source/java/org/alfresco/repo/importer/

Generated at Thu Aug 05 16:10:01 BST 2021 using Jira 7.13.15#713015-sha1:7c5ddd2c3e1709974ae9c48c17df8edd3919fe2c.