You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by "Christian Schneider (Jira)" <ji...@apache.org> on 2022/07/21 10:17:00 UTC

[jira] [Reopened] (JCRVLT-645) Incorrect logging if namespace can not be created while importing a package

     [ https://issues.apache.org/jira/browse/JCRVLT-645?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Christian Schneider reopened JCRVLT-645:
----------------------------------------

Seems we need to backport the fix to 3.4.x branch.

> Incorrect logging if namespace can not be created while importing a package
> ---------------------------------------------------------------------------
>
>                 Key: JCRVLT-645
>                 URL: https://issues.apache.org/jira/browse/JCRVLT-645
>             Project: Jackrabbit FileVault
>          Issue Type: Improvement
>          Components: vlt
>    Affects Versions: 3.4.0
>            Reporter: Christian Schneider
>            Priority: Critical
>
> We had an issue where an asset could not be imported because of a not yet registered namespace.
> The error looked like this:
> {code:java}
> Caused by: javax.jcr.NamespaceException: Unknown namespace URI: http://ns.adobe.com/xap/1.0/sType/ManifestItem#
> 	at org.apache.jackrabbit.oak.jcr.session.SessionNamespaces.getNamespacePrefix(SessionNamespaces.java:154) [org.apache.jackrabbit.oak-jcr:1.42.0.T20220608154910-4c59b36]
> 	at org.apache.jackrabbit.oak.jcr.session.SessionImpl.getNamespacePrefix(SessionImpl.java:794) [org.apache.jackrabbit.oak-jcr:1.42.0.T20220608154910-4c59b36]
> 	at org.apache.jackrabbit.vault.fs.impl.io.DocViewSAXImporter.startPrefixMapping(DocViewSAXImporter.java:540) [org.apache.jackrabbit.vault:3.4.0]
> 	... 38 common frames omitted{code}
> The problem with this error reporting is that it only says the namespace is unknown while swallowing the real error.
> By patching the filevault core bundle I was able to get the real error:
> {code:java}
> 20.07.2022 08:44:11.876 *ERROR* [Queue Processor for Subscriber agent publishSubscriber] org.apache.jackrabbit.vault.fs.impl.io.GenericArtifactHandler Error while parsing null: {}
> org.xml.sax.SAXException: javax.jcr.AccessDeniedException: Failed to register namespace mapping stMfs -> http://ns.adobe.com/xap/1.0/sType/ManifestItem#
> 	at org.apache.jackrabbit.vault.fs.impl.io.DocViewSAXImporter.startPrefixMapping(DocViewSAXImporter.java:546)
> 	at  {code}
> I will provide a PR to fix the exception handling.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)