Bugs item #536502, was opened at 2002-03-28 16:29
You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=376685&aid=536502&group_id=22866

Category: JBossCMP
Group: v3.0 Rabbit Hole
>Status: Closed
>Resolution: Fixed
Priority: 5
Submitted By: Leon Doud (ldoud)
Assigned to: Dain Sundstrom (dsundstrom)
Summary: CMR Cascade Delete Fails

Initial Comment:
The test cases use two entities "One" and "Many", when 
an instance of "One" is created it creates 5 instances 
of "Many".  This is a undirectional 1-M relation with 
cascade delete.  

The last two tests cases both fail when it tries to 
remove the first "One" entity created.

Using JDK 1.3, Win 2000 and JBoss beta 2 build 3/28.


Stack trace of the second to last test case failing:

    [junit] Testcase: testSingleInstance took 0.221 sec
    [junit] Testcase: testSingleInstanceWithFindAll 
took 0.09 sec
    [junit] Testcase: testTwoInstances took 0.29 sec
    [junit] Testcase: testTwoInstancesWithFindAll took 
0.141 sec
    [junit]     Caused an ERROR
    [junit] RemoteException occurred in server thread; 
nested exception is:
    [junit]     java.rmi.ServerException: Internal 
error setting instance field id
    [junit] Embedded Exception
    [junit] object is not an instance of declaring 
class; nested exception is:
    [junit]     javax.ejb.EJBException: Internal error 
setting instance field id
    [junit] Embedded Exception
    [junit] object is not an instance of declaring 
class
    [junit] java.rmi.ServerException: RemoteException 
occurred in server thread; nested exception is:
    [junit]     java.rmi.ServerException: Internal 
error setting instance field id
    [junit] Embedded Exception
    [junit] object is not an instance of declaring 
class; nested exception is:
    [junit]     javax.ejb.EJBException: Internal error 
setting instance field id
    [junit] Embedded Exception
    [junit] object is not an instance of declaring 
class
    [junit] java.rmi.ServerException: Internal error 
setting instance field id
    [junit] Embedded Exception
    [junit] object is not an instance of declaring 
class; nested exception is:
    [junit]     javax.ejb.EJBException: Internal error 
setting instance field id
    [junit] Embedded Exception
    [junit] object is not an instance of declaring 
class
    [junit] javax.ejb.EJBException: Internal error 
setting instance field id
    [junit] Embedded Exception
    [junit] object is not an instance of declaring 
class
    [junit]     at 
sun.rmi.transport.StreamRemoteCall.exceptionReceivedFro
mServer(StreamRemoteCall.java:245)
    [junit]     at 
sun.rmi.transport.StreamRemoteCall.executeCall
(StreamRemoteCall.java:220)
    [junit]     at sun.rmi.server.UnicastRef.invoke
(UnicastRef.java:122)
    [junit]     at 
org.jboss.invocation.jrmp.server.JRMPInvoker_Stub.invok
e(Unknown Source)
    [junit]     at 
org.jboss.invocation.jrmp.interfaces.JRMPInvokerProxy.i
nvoke(JRMPInvokerProxy.java:128)
    [junit]     at 
org.jboss.invocation.InvokerInterceptor.invoke
(InvokerInterceptor.java:108)
    [junit]     at 
org.jboss.proxy.TransactionInterceptor.invoke
(TransactionInterceptor.java:73)
    [junit]     at 
org.jboss.proxy.SecurityInterceptor.invoke
(SecurityInterceptor.java:76)
    [junit]     at 
org.jboss.proxy.ejb.EntityInterceptor.invoke
(EntityInterceptor.java:116)
    [junit]     at 
org.jboss.proxy.ClientContainer.invoke
(ClientContainer.java:96)
    [junit]     at $Proxy2.remove(Unknown Source)
    [junit]     at foo.Test.testTwoInstancesWithFindAll
(Test.java:76)
    [junit]     at java.lang.reflect.Method.invoke
(Native Method)
    [junit]     at junit.framework.TestCase.runTest
(TestCase.java:166)
    [junit]     at junit.framework.TestCase.runBare
(TestCase.java:140)
    [junit]     at junit.framework.TestResult$1.protect
(TestResult.java:106)
    [junit]     at 
junit.framework.TestResult.runProtected
(TestResult.java:124)
    [junit]     at junit.framework.TestResult.run
(TestResult.java:109)
    [junit]     at junit.framework.TestCase.run
(TestCase.java:131)
    [junit]     at junit.framework.TestSuite.runTest
(TestSuite.java:173)
    [junit]     at junit.framework.TestSuite.run
(TestSuite.java:168)
    [junit]     at 
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestR
unner.run(JUnitTestRunner.java:231)
    [junit]     at 
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestR
unner.main(JUnitTestRunner.java:409)
    [junit] java.lang.IllegalArgumentException: object 
is not an instance of declaring class
    [junit]     <<no stack trace available>>

----------------------------------------------------------------------

>Comment By: Dain Sundstrom (dsundstrom)
Date: 2002-04-11 11:40

Message:
Logged In: YES 
user_id=251431

Fixed. I was creating the wrong PK class when loading a 
foreign key field.

----------------------------------------------------------------------

You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=376685&aid=536502&group_id=22866

_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to