hi,
I'm using BEA weblogic8.1 to develop
J2EE application in a cluster environment, where EJB is clustered.
But java.net.UnknownHostException occurred, when I call clustered Stateless session bean from a webapp outside of the cluster.
my code is below:
try{
CatalogServiceRemote catalogServiceRemote = (CatalogServiceRemote)Locator.getSessionBean("CatalogService");
//Remote Stub is successfully acquired using ServiceLocator
this.categoryList = (ArrayList)catalogServiceRemote.getTopCategories();
//when a remote method is called, remote exception is thrown
}
catch(NamingException ne){
System.out.println(ne);
}
catch(RemoteException re){
System.out.println(re);
}
exception like below:
java.rmi.RemoteException: EJB Exception: ; nested exception is:
javax.ejb.EJBException: nested exception is: javax.naming.ServiceUnavail
ableException [Root exception is java.net.UnknownHostException: 192.168.10.4:
192.168.10.4]
I'm not sure why it cannot find host:192.168.10.4, which is a host where a weblogic instance of the cluster resides. and I can ping 192.168.10.4 successfully.
any help appreciated!