Can you provide the code for this case as well?

I can not off my head recall a ValidatableAbstractComposite, so I
don't think that is what you should be implementing at all, but
perhaps this sits in a library...


Cheers
Niclas

On Thu, Nov 4, 2010 at 12:28 AM, Ronnie Nessa <[email protected]> wrote:
> Hi guys.
> I´m trying to use the validation-support framework in the
> qi4j-lib-validation module. I´m letting my entity composites implement
> the ValidatableAbstractComposite implement, which I believe is the only
> thing I have to do to get the basic validation support to work. But when I
> try to change my entities I get an StackOverFlowException:
> java.lang.Exception: Unexpected exception,
> expected<org.qi4j.api.unitofwork.NoSuchEntityException> but
> was<java.lang.StackOverflowError>
> at
> org.junit.internal.runners.statements.ExpectException.evaluate(ExpectException.java:28)
> at
> org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:28)
> at
> org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:31)
> at
> org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:76)
> at
> org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50)
> at org.junit.runners.ParentRunner$3.run(ParentRunner.java:193)
> at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:52)
> at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:191)
> at org.junit.runners.ParentRunner.access$000(ParentRunner.java:42)
> at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:184)
> at org.junit.runners.ParentRunner.run(ParentRunner.java:236)
> at
> org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:46)
> at
> org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
> at
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
> at
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
> at
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
> at
> org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
> Caused by: java.lang.StackOverflowError
> at
> java.lang.reflect.InvocationTargetException.<init>(InvocationTargetException.java:54)
> at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:597)
> at net.sf.cglib.proxy.MethodProxy.find(MethodProxy.java:167)
> at
> org.qi4j.runtime.composite.MixinModel.newInvocationHandler(MixinModel.java:228)
> at
> org.qi4j.runtime.composite.AbstractMixinsModel.newInvocationHandler(AbstractMixinsModel.java:270)
> at
> org.qi4j.runtime.composite.CompositeMethodModel.newCompositeMethodInstance(CompositeMethodModel.java:175)
> at
> org.qi4j.runtime.composite.CompositeMethodModel.getInstance(CompositeMethodModel.java:166)
> at
> org.qi4j.runtime.composite.CompositeMethodModel.invoke(CompositeMethodModel.java:150)
> at
> org.qi4j.runtime.composite.CompositeMethodsModel.invoke(CompositeMethodsModel.java:122)
> at
> org.qi4j.runtime.composite.AbstractCompositeModel.invoke(AbstractCompositeModel.java:122)
> at org.qi4j.runtime.entity.EntityInstance.invoke(EntityInstance.java:84)
> at
> org.qi4j.runtime.composite.ProxyReferenceInvocationHandler.invoke(ProxyReferenceInvocationHandler.java:49)
> at $Proxy29.checkValid(Unknown Source)
> at
> org.qi4j.library.validation.ChangeValidationConcern.invoke(ChangeValidationConcern.java:67)
> at
> org.qi4j.runtime.composite.MethodConcernsInstance.invoke(MethodConcernsInstance.java:52)
> at
> org.qi4j.runtime.composite.CompositeMethodInstance.invoke(CompositeMethodInstance.java:60)
> at org.qi4j.runtime.entity.EntityInstance.invoke(EntityInstance.java:173)
> at
> org.qi4j.runtime.composite.CompositeMethodModel.invoke(CompositeMethodModel.java:153)
> at
> org.qi4j.runtime.composite.CompositeMethodsModel.invoke(CompositeMethodsModel.java:122)
> at
> org.qi4j.runtime.composite.AbstractCompositeModel.invoke(AbstractCompositeModel.java:122)
> at org.qi4j.runtime.entity.EntityInstance.invoke(EntityInstance.java:84)
> at
> org.qi4j.runtime.composite.ProxyReferenceInvocationHandler.invoke(ProxyReferenceInvocationHandler.java:49)
> at $Proxy29.checkValid(Unknown Source)
>
>
> Maybe I missed something. Does anybody have any pointers on what I need to
> do to get this working?
> Best regards
> Ronnie Nessa
>
>
>
>
>
> _______________________________________________
> qi4j-dev mailing list
> [email protected]
> http://lists.ops4j.org/mailman/listinfo/qi4j-dev
>
>



-- 
Niclas Hedhman, Software Developer
http://www.qi4j.org - New Energy for Java

I  live here; http://tinyurl.com/2qq9er
I  work here; http://tinyurl.com/2ymelc
I relax here; http://tinyurl.com/2cgsug

_______________________________________________
qi4j-dev mailing list
[email protected]
http://lists.ops4j.org/mailman/listinfo/qi4j-dev

Reply via email to