Using the ServiceLocator pattern from the web tier
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Dhiren_Bhatia
Posted On:   Thursday, August 1, 2002 02:29 PM

All, I'm trying to use the Service Locator pattern to access the home interfaces of my EJBs. Since I don't want any application specific code in the ServiceLocator, I have a jndi.properties file as follows: java.naming.factory.initial=weblogic.jndi.WLInitialContextFactory java.naming.provider.url=t3://localhost:7001 When I execute my unit tests(JUnit) which use this pattern to locate the EJB's there's no problem. However, I also have a JSP Tag Library which attempts to access the EJB's. I'm using a separate JSP Engine(JRun, not Weblogic). The JSP tag handlers can't seem to access the EJB's. My guess is that they can't pick up the properties required    More>>


All,



I'm trying to use the Service Locator pattern to access the home interfaces of my EJBs. Since I don't want any application specific code in the ServiceLocator, I have a jndi.properties file as follows:



java.naming.factory.initial=weblogic.jndi.WLInitialContextFactory
java.naming.provider.url=t3://localhost:7001


When I execute my unit tests(JUnit) which use this pattern to locate the EJB's there's no problem. However, I also have a JSP Tag Library which attempts to access the EJB's. I'm using a separate JSP Engine(JRun, not Weblogic). The JSP tag handlers can't seem to access the EJB's.


My guess is that they can't pick up the properties required for creating the InitalContext in the ServiceLocator.
I provided these parameters to JRun as java arguments(i.e. -Djava.naming........ )


What am i missing? Is there anything specific i need to access the beans using the ServiceLocator from the web tier.


Thanks,


Dhiren

   <<Less
About | Sitemap | Contact