hivemind-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hivemind-...@jakarta.apache.org
Subject [Jakarta HiveMind Wiki] Updated: FrequentlyAskedQuestions
Date Wed, 03 Nov 2004 21:02:44 GMT
   Date: 2004-11-03T13:02:43
   Editor: DavidKarlsen <david@davidkarlsen.com>
   Wiki: Jakarta HiveMind Wiki
   Page: FrequentlyAskedQuestions
   URL: http://wiki.apache.org/jakarta-hivemind/FrequentlyAskedQuestions

   no comment

Change Log:

------------------------------------------------------------------------------
@@ -44,3 +44,27 @@
 Registry registry = builder.constructRegistry(Locale.getDefault());
 }}}
 
+'''Question 4):''' '''["How can I use HiveMind to lookup my EJB remote component interfaces?
(aka ServiceLocator pattern)"]''' (DavidKarlsen 03/10/2004)  
+
+I'd like to lookup my EJB beans and receive the narrowed remote component interface via HiveMind.
+
+'''Answer'''
+
+David Karlsen: Use the hivemind.lib.EJBProxyFactory:
+{{{
+<module id="com.mypackage" version="1.0.0">
+         <service-point id="SessionFacade" interface="com.mypackage.SessionFacade">
+         <invoke-factory service-id="hivemind.lib.EJBProxyFactory">
+                 <construct
+                 home-interface="com.mypackage.SessionFacadeHome"
+                 jndi-name="ejb/com.mypackage/SessionFacadeHome"/>
+         </invoke-factory>
+         </service-point>
+</module>
+}}}
+
+{{{
+Then in your code:
+//initialize Registry registry some way
+SessionFacade sf = (SessionFacade) registry.getService(SessionFacade.class);
+}}}

---------------------------------------------------------------------
To unsubscribe, e-mail: hivemind-cvs-unsubscribe@jakarta.apache.org
For additional commands, e-mail: hivemind-cvs-help@jakarta.apache.org


Mime
View raw message