This content has been marked as final.
Show 2 replies
-
1. Re: Call remote EJB on other JBoss from web
citystory Mar 9, 2005 11:30 PM (in response to citystory)Solved it but even not require ExternalContext.
Changes :
1. jboss-web.xml
<jndi-name>jnp://myremotehost:1099/time/arr/UstCourseInfoService</jndi-name>
Remove "application"
2. ServiceLocator.java
java:comp/env/time/arr/UstCourseInfoService
Add "java:comp/env/
Yet, my scheduler in SAR still can't access remote EJB with
javax.naming.NameNotFoundException: env not bound
Following workarounds failed :
1. package WAR into SAR (hope to able to use jboss-web.xml JNDI)
2. add<depends>jboss.j2ee:service=EJB,jndiName=time/arr/UstCourseInfoService</depends>
into jboss-service.xml of SAR
Any help? thanks much -
2. Re: Call remote EJB on other JBoss from web
citystory Mar 11, 2005 2:11 AM (in response to citystory)Fixed by setup InitialContext in code without java:comp/env
Since ServiceLocator.getRemoteHome is centralized.
add utility method StackTrace.findInStackTrace(String classNamePattern)
to distinguish the caller from WEB or SAR.
Also JAAS is added for both case.
Thanks anyway