>>>Can't remember if the spec clearly defines that point. AFAIK, spec. says that define one of them @Local or @Remote but not both
2010/2/9 Jean-Louis MONTEIRO <jean-louis.monte...@atosorigin.com> > > Hi > > > joe-2 wrote: > > > > I am quite new to OpenEJB and EJB3 in general, so many things are > > nebulous for me. > > > Welcome :) > > > joe-2 wrote: > > > > I guessed to make an EJB locally testable it has to implement an > > interface annotated with @Local. > > > Before EJB 3.1, @local was not required. If you have a bean implementing a > single interface, the container will assume it's the local interface. If > you > implement more than one interface, you have to explicitly add the @Local > annotation. > Since EJB 3.1, a bean is not required to implement an interface (@local or > @remote). > As you already noticed, some details are available at > http://openejb.apache.org/3.0/simple-stateless-example.html > http://openejb.apache.org/3.0/simple-stateless-example.html . > > > joe-2 wrote: > > > > But it seems i am wrong. My EJBs methods are also invokeable even if > > they implement an interface annotated > > with @Remote. > > > > So in general Remote-EJBs are locally invokeable? if yes whats the > > @Local for? > > Just to make EJB methods not invokeable for remote clients? > > > > in the "Simple Stateless Example" > > (http://openejb.apache.org/3.0/simple-stateless-example.html) > > two interfaces (with identical signatures) are used one with implicit > > @Local and one with @Remote annotation. > > Why, maybe some use case? > > > Can't remember if the spec clearly defines that point. > > Jean-Louis > > -- > View this message in context: > http://n4.nabble.com/testing-Local-Remote-tp1474295p1474348.html > Sent from the OpenEJB User mailing list archive at Nabble.com. > -- Gurkan Erdogdu http://gurkanerdogdu.blogspot.com