Hello everyone in List,
I want to know what is the difference between session.exportDocumentView and
session.exportSystemView ,
I know the format of the export file is diffrent. And any thing else?
Let's
1:session.exportDocumentView(..) , save file as docFile.xml;
2:session.exportSystemView (..) , save file as sysFile.xml
Then session.importXML() each file, sysFile.xml will success, but docFile.xml
failed with error info:
ERROR com.tingup.cms.portlet.CmsImportExportPortlet - Constraint has been
violated; nested exception is javax.jcr.nodetype.ConstraintViolationException:
no matching property definition found for
{http://jackrabbit.apache.org/ocm}classname
org.springframework.dao.DataIntegrityViolationException: Constraint has been
violated; nested exception is javax.jcr.nodetype.ConstraintViolationException:
no matching property definition found for
{http://jackrabbit.apache.org/ocm}classname
at
org.springmodules.jcr.SessionFactoryUtils.translateException(SessionFactoryUtils.java:182)
at
org.springmodules.jcr.JcrAccessor.convertJcrAccessException(JcrAccessor.java:58)
at org.springmodules.jcr.JcrTemplate.execute(JcrTemplate.java:82)
at org.springmodules.jcr.JcrTemplate.importXML(JcrTemplate.java:331)
at
com.tingup.cms.service.impl.JcrNodeServiceOcmImpl.importData(JcrNodeServiceOcmImpl.java:100)
..........................
Caused by: javax.jcr.nodetype.ConstraintViolationException: no matching
property definition found for {http://jackrabbit.apache.org/ocm}classname
at
org.apache.jackrabbit.core.nodetype.EffectiveNodeType.getApplicablePropertyDef(EffectiveNodeType.java:822)
at
org.apache.jackrabbit.core.xml.PropInfo.getApplicablePropertyDef(PropInfo.java:95)
at
org.apache.jackrabbit.core.xml.SessionImporter.startNode(SessionImporter.java:403)
at
org.apache.jackrabbit.core.xml.DocViewImportHandler.startElement(DocViewImportHandler.java:287)
at
org.apache.jackrabbit.core.xml.ImportHandler.startElement(ImportHandler.java:170)
at
org.apache.jackrabbit.commons.xml.DefaultContentHandler.startElement(DefaultContentHandler.java:162)
can somebody explain it?
Thank you!
Regards ,
Edward.