[jboss-jira] [JBoss JIRA] Updated: (EJBTHREE-1153) Client container needs an java:comp/ORB binding
Carlo de Wolf (JIRA)
jira-events at lists.jboss.org
Mon Sep 15 02:34:33 EDT 2008
[ https://jira.jboss.org/jira/browse/EJBTHREE-1153?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Carlo de Wolf updated EJBTHREE-1153:
------------------------------------
Fix Version/s: 1.0.0-Beta4
(was: 1.0.0-Beta3)
> Client container needs an java:comp/ORB binding
> -----------------------------------------------
>
> Key: EJBTHREE-1153
> URL: https://jira.jboss.org/jira/browse/EJBTHREE-1153
> Project: EJB 3.0
> Issue Type: Feature Request
> Reporter: Scott M Stark
> Fix For: 1.0.0-Beta4
>
>
> EE.5.11ORB References
> Some Java EE applications will need to make use of the CORBA ORB to perform certain operations. Such applications can find an appropriate object implementing the ORB interface by looking up the JNDI name java:comp/ORB or by requesting injection of an ORB object. The container is required to provide the java:comp/ORB name for all components except applets. Any such reference to a ORB object is only valid within the component instance that performed the lookup.
> The following example illustrates how an application component acquires and uses an ORB object via injection.
> @Resource ORB orb;
> public void method(...) {
> ...
> // Get the POA to use when creating object references.
> POA rootPOA = (POA)orb.resolve_initial_references("RootPOA");
> ...
> }
> The following example illustrates how an application component acquires and uses an ORB object using a JNDI lookup.
> public void method(...) {
> ...
> // Obtain the default initial JNDI context.
> Context initCtx = new InitialContext();
> // Look up the ORB object.
> ORB orb = (ORB)initCtx.lookup("java:comp/ORB");
> // Get the POA to use when creating object references.
> POA rootPOA = (POA)orb.resolve_initial_references("RootPOA");
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list