I think that's how the EJB container behaves. For your interface to be
part of the business interface of the bean class, the bean class has to
implement it directly or it has to be specified in the annotation/dd of
the bean class. Inheritance of component information does not take
place. This is how I understand when I read the following example of the
spec:
A session bean class is permitted to have superclasses that are
themselves session bean classes. How-
ever, there are no special rules that apply to the processing of
annotations or the deployment descriptor
for this case. For the purposes of processing a particular session bean
class, all superclass processing is
identical regardless of whether the superclasses are themselves session
bean classes. In this regard, the
use of session bean classes as superclasses merely represents a
convenient use of implementation inher-
itance, but does not have component inheritance semantics.
As an example, the client views exposed by a particular session bean are
not inherited by a subclass that
also happens to define a session bean.
@Stateless
public class A implements Foo { ... }
@Stateless
public class B extends A implements Bar { ... }
Assuming Foo and Bar are local business interfaces and there is no
associated deployment descriptor,
session bean A exposes local business interface Foo and session bean B
exposes local business interface
Bar, but not Foo.
To confirm this behavior, you should look at the output in the
server.log where osgi-ejb-container prints the information about the
EJB. It does prints all the business interface names.
HTH,
Sahoo
On Thursday 05 May 2011 07:54 PM, forums_at_java.net wrote:
> Hi,
>
> I use glassfish 3.1 GA build.
>
> I have an EJB that extends Abstract class that implements an Interface.
> Abstract class and Interface are located in a separate jar. I added
> "Export-EJB:ALL" to a jar that contains EJB.
>
> The export-ejb doesn't work in such case.
>
> If I change EJB to implement Interface directly, export-ejb works ok.
>
> Is it a known bug?
>
>
>
> thanks
>
>
>
>
> --
>
> [Message sent by forum member 'okna2000']
>
> View Post: http://forums.java.net/node/798506
>
>