Wednesday, August 21, 2013

Self_Note: Weblogic remote EJB lookup string

pattern:
<remote_interface> beanRemote = (<remote_interface>) context.lookup("mappedName#qualified_name_of_businessInterface");

sample:
NumberService service = (NumberService)context.lookup("NumberCreator#coreservlets.bean.NumberService");

for the below 

package coreservlets.bean;
import javax.ejb.*;
@Stateless(mappedName="NumberCreator")
public class NumberServiceBean implements NumberService {
    public double getNumber(double range) {
        return(Math.random() * range);
    }
}

LinkWithin

Related Posts Plugin for WordPress, Blogger...