[EJB 3.0] - Bidirectional Relationship MarshalException on EJB3 Client
by octaviob
I'm getting a MarshalException on a client application (Eclipse RCP).
I have a bidirectional relationship Employee-Supervisor, both of the same class.
My client app can retrieve a Supervisor entity, including the subordinate employees, without a problem. However, if I attempt to retrieve an employee that has a supervisor, I get a MarshalException on the client side:
java.rmi.MarshalException: Failed to communicate. Problem during marshalling/unmarshalling; nested exception is:
| java.lang.NullPointerException
| at org.jboss.remoting.transport.socket.SocketClientInvoker.transport(SocketClientInvoker.java:306)
| at org.jboss.remoting.RemoteClientInvoker.invoke(RemoteClientInvoker.java:143)
| at org.jboss.remoting.Client.invoke(Client.java:525)
| at org.jboss.remoting.Client.invoke(Client.java:488)
|
I'm using JBoss 4.0.5.GA. There are no Exceptions on the server side.
I'm including the code that defines the relationship (I do initialize the subordinate set on the server before sending the entity to the client):
| @OneToMany(mappedBy = "supervisor", fetch=FetchType.LAZY )
| public Set<Employee> getSubordinateSet(){
| return subordinateSet;
| }
|
| @ManyToOne(fetch=FetchType.EAGER)
| @JoinColumn(name = "supervisor")
| public Employee getSupervisor(){
| return supervisor;
| }
|
Any suggestions/guidance will be greatly appreciated...
Octavio
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4066478#4066478
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4066478
18Â years, 9Â months
[JBoss and NetBeans] - Jboss with J2EE and netbeans
by gutierrez.ge
hi all, i had this problem, i did an app using Sun App. Server with some cool stuff, but my boss told me that the app. needs to be run on jboss jbpm, so i added jboss jbpm as a jboss app. server to netbeans and it worked.. but here is the problem, netbeans recognized the jboss app server as a J2EE 1.4 version and this cool stuff (persistence, autoboxing, foreach, generics, annotation and on) they dont run on that version of J2EE, so i want to know if there is a way to change that, a way to upgrade the server j2ee version on netbeans.
Thanks on advance your comments,
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4066476#4066476
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4066476
18Â years, 9Â months