jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lubos and Alena Pochman" <pochm...@gmail.com>
Subject Re: [JCR Browser] nodetype.ConstraintViolationException: no matching property definition found for {}
Date Wed, 14 Mar 2007 00:39:44 GMT
I would be also interested in that. I would not mind doing it
programatically (if I know how 8-).
I read JSR-170 spec and jackrabbit website but could not find it, probably
did not look hard enough 8-).

On 3/13/07, Sudhan <s.kanade@gmail.com> wrote:
>
>
> Hi Guy,
>
> Sorry, i am new to this CMS:jackrabbit, can you tell me how to define
> those
> custom node types. Is there a configuration setting where i can add or
> update any of the xml configuration and add my custom nodetype.
>
> Do you have a example ?
>
> thanks,
>
> Sudhan
>
>
> Stefan Guggisberg wrote:
> >
> > On 3/13/07, Guy Spillman <gspillman@hal-inc.com> wrote:
> >> I'm getting a similar error.  All I'm doing is creating
> >> a nt:file node, and setting a new property as a string
> >> value.  I've tried both of the following:
> >>
> >> Node fileNode = node.addNode("FormData.xml","nt:file");
> >> fileNode.setProperty("RevisionLabel", "1");
> >>
> >> and
> >>
> >> Node fileNode = node.addNode("FormData.xml","nt:file");
> >> fileNode.setProperty("RevisionLabel", "1",
> >> PropertyType.STRING);
> >>
> >> I'm am currently running JackRabbit on Weblogic 8.1sp6
> >> and JDK 1.4.2_06.  I updated JackRabbit from 1.1.1 to
> >> 1.2.2 last Monday (Mar 5th), and had no problems until
> >> today.  I have tried upgrading to 1.2.3, and
> >> downgrading to the original 1.1.1, both give me the
> >> same error.  The Exception I'm getting is as follows:
> >>
> >> javax.jcr.nodetype.ConstraintViolationException: no
> >> matching property definition found for {}RevisionLabel
> >
> > this exception tells you that there's no matching property
> > definition for "RevisionLabel" in the given primary/mixin
> > types of the said node.
> >
> > you could e.g. create your own node type which declares
> > your required properties and which extends nt:file.
> >
> > cheers
> > stefan
> >
> >> at
> >>
> org.apache.jackrabbit.core.nodetype.EffectiveNodeType.getApplicablePropertyDef
> (EffectiveNodeType.java:775)
> >> at
> >> org.apache.jackrabbit.core.NodeImpl.getApplicablePropertyDefinition(
> NodeImpl.java:926)
> >> at
> >> org.apache.jackrabbit.core.NodeImpl.getOrCreateProperty(NodeImpl.java
> :457)
> >> at
> >> org.apache.jackrabbit.core.NodeImpl.getOrCreateProperty(NodeImpl.java
> :407)
> >> at
> >> org.apache.jackrabbit.core.NodeImpl.setProperty(NodeImpl.java:2121)
> >>
> >> Guy Spillman
> >>
> >> On Mon, 12 Mar 2007 12:29:58 -0700 (PDT), Sudhan wrote:
> >>
> >> >
> >> >
> >> > Hello,
> >> >
> >> > I am developing a application which requires to set
> >> > custom property on
> >> > either jcr:content node, nt:file node or nt:version
> >> > node. Let me explain you
> >> > how this works :
> >> >
> >> > I have a listener which listens to
> >> > "/jcr:system/jcr:versionStorage", on any
> >> > node added to versionStorage. The events are getting
> >> > triggered when i add or
> >> > update any node by updating jcr:data property of
> >> > jcr:content node (which is
> >> > versionable).
> >> >
> >> > Now my problem is when i get this event and my
> >> > application processes the
> >> > size of the updated file, i need some mechanism to put
> >> > back the size of the
> >> > file as a property on this versionable node.
> >> >
> >> > I am able to prepopulate and set property "size" on
> >> > versionable node and
> >> > when i try to update this property by, check out,
> >> > update and checkin there
> >> > is one more verisonable node added to that
> >> > versionStorage (which i do not
> >> > want ).
> >> >
> >> > Now when i try to insert a new property by setting
> >> > setProperty("size","292"); to a nt:file node i am
> >> > getting following
> >> > constraintViolationExcpetion :
> >> >
> >> > nodetype.ConstraintViolationException: no matching
> >> > property definition found
> >> > for {}deltaSize
> >> >
> >> >
> >> org.apache.jackrabbit.rmi.server.ServerObject.getRepositoryException(
> ServerObject.java:102)
> >> >
> >> >
> >> org.apache.jackrabbit.rmi.server.ServerNode.setProperty(ServerNode.java
> :249)
> >> >  sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> >> > Method)
> >> >
> >> >
> >> sun.reflect.NativeMethodAccessorImpl.invoke(
> NativeMethodAccessorImpl.java:39)
> >> >
> >> >
> >> sun.reflect.DelegatingMethodAccessorImpl.invoke(
> DelegatingMethodAccessorImpl.java:25)
> >> >  java.lang.reflect.Method.invoke(Method.java:585)
> >> >
> >> sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:294)
> >> >  sun.rmi.transport.Transport$1.run(Transport.java:153)
> >> >  java.security.AccessController.doPrivileged(Native
> >> > Method)
> >> >
> >> sun.rmi.transport.Transport.serviceCall(Transport.java:149)
> >> >
> >> sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java
> :460)
> >> >
> >> >
> >> sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(
> TCPTransport.java:701)
> >> >  java.lang.Thread.run(Thread.java:595)
> >> >
> >> >
> >> sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(
> StreamRemoteCall.java:247)
> >> >
> >> sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java
> :223)
> >> >  sun.rmi.server.UnicastRef.invoke(UnicastRef.java:126)
> >> >
> >> org.apache.jackrabbit.rmi.server.ServerNode_Stub.setProperty(Unknown
> >> > Source)
> >> >
> >> >
> >> org.apache.jackrabbit.rmi.client.ClientNode.setProperty(ClientNode.java
> :127)
> >> >
> >> >
> >> org.apache.jackrabbit.rmi.client.ClientNode.setProperty(ClientNode.java
> :173)
> >> >
> >> >
> >> com.idcglobal.cloe.VersioningTest.testRepositoryCheck(
> VersioningTest.java:119)
> >> >  sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> >> > Method)
> >> >
> >> >
> >> sun.reflect.NativeMethodAccessorImpl.invoke(
> NativeMethodAccessorImpl.java:39)
> >> >
> >> >
> >> sun.reflect.DelegatingMethodAccessorImpl.invoke(
> DelegatingMethodAccessorImpl.java:25)
> >> >  java.lang.reflect.Method.invoke(Method.java:585)
> >> >  junit.framework.TestCase.runTest(TestCase.java:154)
> >> >  junit.framework.TestCase.runBare(TestCase.java:127)
> >> >
> >> junit.framework.TestResult$1.protect(TestResult.java:106)
> >> >
> >> junit.framework.TestResult.runProtected(TestResult.java:124)
> >> >  junit.framework.TestResult.run(TestResult.java:109)
> >> >  junit.framework.TestCase.run(TestCase.java:118)
> >> >  junit.framework.TestSuite.runTest(TestSuite.java:208)
> >> >  junit.framework.TestSuite.run(TestSuite.java:203)
> >> >  sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> >> > Method)
> >> >
> >> >
> >> sun.reflect.NativeMethodAccessorImpl.invoke(
> NativeMethodAccessorImpl.java:39)
> >> >
> >> >
> >> sun.reflect.DelegatingMethodAccessorImpl.invoke(
> DelegatingMethodAccessorImpl.java:25)
> >> >  java.lang.reflect.Method.invoke(Method.java:585)
> >> >
> >> org.apache.maven.surefire.junit.JUnitTestSet.execute(JUnitTestSet.java
> :213)
> >> >
> >> >
> >>
> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(
> AbstractDirectoryTestSuite.java:138)
> >> >
> >> >
> >> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(
> AbstractDirectoryTestSuite.java:125)
> >> >
> >> org.apache.maven.surefire.Surefire.run(Surefire.java:132)
> >> >  sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> >> > Method)
> >> >
> >> >
> >> sun.reflect.NativeMethodAccessorImpl.invoke(
> NativeMethodAccessorImpl.java:39)
> >> >
> >> >
> >> sun.reflect.DelegatingMethodAccessorImpl.invoke(
> DelegatingMethodAccessorImpl.java:25)
> >> >  java.lang.reflect.Method.invoke(Method.java:585)
> >> >
> >> >
> >> org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(
> SurefireBooter.java:290)
> >> >
> >> >
> >> org.apache.maven.surefire.booter.SurefireBooter.main(
> SurefireBooter.java:818)
> >> >  1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed:
> >> > 1.031 sec <<< FAILURE!
> >> >
> >> > Now my question is that, is there a way to update or
> >> > insert a new property -
> >> > size onto a non-versioned parent node or any other way
> >> > to update property to
> >> > versioned node without incrementing version number.
> >> >
> >> > Once again thanks for your help and would appreciate
> >> > any pointers or help in
> >> > this matter.
> >> >
> >> > thanks,
> >> >
> >> > Sudhan
> >> > --
> >> > View this message in context:
> >> >
> >>
> http://www.nabble.com/nodetype.ConstraintViolationException%3A-no-matching-property-definition-found-for-%7B%7D-tf3391684.html#a9441553
> >> > Sent from the Jackrabbit - Users mailing list archive
> >> > at Nabble.com.
> >>
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/nodetype.ConstraintViolationException%3A-no-matching-property-definition-found-for-%7B%7D-tf3391684.html#a9466196
> Sent from the Jackrabbit - Users mailing list archive at Nabble.com.
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message