我使用jackrabbit
2.12
作为部署到tomcat
的Web应用程序。我用
xml
session.exportSystemView(..)
方法。当我尝试导入此备份
InputStream xmlInputStream=new FileInputStream("d://sk.xml");
jcrSession.importXML("/",xmlInputStream,ImportUUIDBehavior.IMPORT_UUID_COLLISION_REPLACE_EXISTING);
发生此异常:
javax.jcr.RepositoryException: Internal Server Error
at org.apache.jackrabbit.spi2dav.ExceptionConverter.generate(ExceptionConverter.java:120)
at org.apache.jackrabbit.spi2dav.ExceptionConverter.generate(ExceptionConverter.java:51)
at org.apache.jackrabbit.spi2dav.ExceptionConverter.generate(ExceptionConverter.java:45)
at org.apache.jackrabbit.spi2dav.RepositoryServiceImpl.isGranted(RepositoryServiceImpl.java:882)
at org.apache.jackrabbit.jcr2spi.WorkspaceManager.canRead(WorkspaceManager.java:695)
at org.apache.jackrabbit.jcr2spi.state.ItemStateValidator.checkIsWritable(ItemStateValidator.java:199)
at org.apache.jackrabbit.jcr2spi.xml.SessionImporter.<init>(SessionImporter.java:130)
at org.apache.jackrabbit.jcr2spi.SessionImpl.getImportContentHandler(SessionImpl.java:380)
at org.apache.jackrabbit.jcr2spi.SessionImpl.importXML(SessionImpl.java:390)
...
Caused by: org.apache.jackrabbit.webdav.DavException: Internal Server Error
at org.apache.jackrabbit.webdav.client.methods.DavMethodBase.getResponseException(DavMethodBase.java:165)
at org.apache.jackrabbit.webdav.client.methods.DavMethodBase.checkSuccess(DavMethodBase.java:174)
at org.apache.jackrabbit.spi2dav.RepositoryServiceImpl.isGranted(RepositoryServiceImpl.java:854)
... 81 more
和tomcat catalina日志:
ERROR [http-nio-8080-exec-1] DavLocatorFactoryImpl.java:64 Unexpected format of resource path.
我找到了关于此问题的issue,但没有合适的解决方案。如何导入此xml?
(存储库中的当前文件微不足道,可以删除它们以导入此xml
。)