-
1. Re: MarshalException when creating remote session bean
channingwalton Feb 9, 2003 6:27 AM (in response to channingwalton)More info: I believe this may be already reported as bug 663114 reported on 6 June 2003 - http://sourceforge.net/tracker/?group_id=22866&atid=376685&func=detail&aid=663114
Channing -
2. Re: MarshalException when creating remote session bean
channingwalton Feb 9, 2003 6:29 AM (in response to channingwalton)More info: I believe this may be already reported as bug 663114 reported on 6 June 2003 - http://sourceforge.net/tracker/?group_id=22866&atid=376685&func=detail&aid=663114
Channing -
3. Re: MarshalException when creating remote session bean
channingwalton Feb 9, 2003 6:31 AM (in response to channingwalton)More info: I believe this may be already reported as bug 663114 reported on 6 June 2003 - http://sourceforge.net/tracker/?group_id=22866&atid=376685&func=detail&aid=663114
Channing -
4. Re: MarshalException when creating remote session bean
channingwalton Feb 9, 2003 6:36 AM (in response to channingwalton)More info: I believe this may be already reported as bug 663114 reported on 6 June 2003 - http://sourceforge.net/tracker/?group_id=22866&atid=376685&func=detail&aid=663114
Channing -
5. Re: MarshalException when creating remote session bean
channingwalton Feb 9, 2003 2:01 PM (in response to channingwalton)Whoa! Sorry about the multiple posts - when i submitted them it didn't look like they were getting to the forum (they weren't appearing).
-
6. Re: MarshalException when creating remote session bean
gadgetman Mar 13, 2003 12:13 AM (in response to channingwalton)Hi, I believe I am having this kind of problem too, I've read the link on Sourceforge about the solution but I don't understand what I have to do. Here's my situation:
I have one EJB (EJB 1) on one instance of JBoss (JBoss 1)that wishes to call a method on another EJB (EJB 2) in another instance of JBoss (JBoss 2). Both instances are located on the same machine but obviously on different ports (and these are configured properly). From EJB 2, I do the jndi context and obtain the remote interface to EJB 1, then invoke the create method on EJB 1. The call to create on EJB 1 works cause I see it in JBoss 1.
However, the problem exists when I want to invoke a method on EJB 1 after creating the bean, I get this error:
java.rmi.MarshalException: error marshalling arguments; nested exception is:
java.io.NotSerializableException: org.jboss.tm.TransactionImpl
So, what exactly is happening here, why I can't marshall the arguments?
Thanks for any help, I am stuck at this point, and am not sure on how to solve it. -
7. Re: MarshalException when creating remote session bean
gadgetman Mar 14, 2003 12:28 AM (in response to channingwalton)OK, on closer inspection I am able to do a create on the bean cause I see it being invoked (by println commands in the ejbCreate method of the bean). But on the calling bean (the bean that is calling this remote method on this bean), I get a RemoteException and I don't get anything printed right after the home.create() but am able to see stuff printed after the catch block.
So the question is why does this RemoteException happen? I have an EJB class that makes calls to another EJB to invoke on its method and I've copied the same code and have no problems.
Can any body tell me what's going on? -
8. Re: MarshalException when creating remote session bean
gadgetman Mar 14, 2003 1:36 AM (in response to channingwalton)OK, let me clarify what I am trying to do here. I have EJB 1 on JBoss 1 server and EJB 2 on JBoss 2 server. I want EJB 2 to call a method in EJB 1. So, this means I have to create an EJB reference in the jboss.xml and ejb-jar.xml files for EJB 2. I've done so according to here:
http://www.jboss.org/online-manual/HTML/ch05s13.html
and for jndi-name in the ejb-ref tag in jboss.xml, I put <jndi-name>jnp://localhost/EJB1</jndi-name> (EJB1 resides in the first instance of JBoss in localhost on port 1099). But I still encounter the problem of
java.rmi.MarshalException: error marshalling arguments, nested exception is:
java.io.NotSerializableException: org.jboss.tm.TransactionImpl
Is there still anything I am missing or doing wrong?
Thanks for any help. -
9. Re: MarshalException when creating remote session bean
belokrylov Mar 19, 2003 3:03 AM (in response to channingwalton)I modified my local sources jboss-3.0.4 to locate this problem:
/* Original "server/src/main/org/jboss/invocation/MarshalledInvocation.java" */
/***************** Begin ****************/
out.writeInt(as_is_payload.size());
keys = as_is_payload.keySet().iterator();
while (keys.hasNext())
{
Object currentKey = keys.next();
out.writeObject(currentKey);
out.writeObject(as_is_payload.get(currentKey));
}
/******************* End ****************/
/* Modified "server/src/main/org/jboss/invocation/MarshalledInvocation.java" */
/***************** Begin ****************/
int n = as_is_payload.size();
if( as_is_payload.containsKey(Invocation.TRANSACTION) ) n=n-1;
out.writeInt(n);
keys = as_is_payload.keySet().iterator();
while (keys.hasNext())
{
Object currentKey = keys.next();
if( currentKey != Invocation.TRANSACTION ){
out.writeObject(currentKey);
out.writeObject(currentValue);
}
}
/******************* End ****************/
Please check it.