Returning superclass of return type from remote EJB method

Posted by fish on Stack Overflow See other posts from Stack Overflow or by fish
Published on 2010-04-07T09:25:14Z Indexed on 2010/04/07 13:53 UTC
Read the original article Hit count: 227

Filed under:
|
|

Let's say I have remote interface A:

@Remote
public interface A {
  public Response doSomething();
}

And implementation:

@Stateless
public class B implements A {
  public BeeResponse doSomething() {...}
}

Where:

  • BeeResponse extends Response.
  • Response is located in the EJB-API jar and BeeResponse is in the implementation jar.
  • Response and BeeResponse have different serialVersionUID.

My assumption is that the unmarshalling of the response from B will fail, am I correct?

© Stack Overflow or respective owner

Related posts about ejb3

Related posts about return-type