[
https://issues.jboss.org/browse/WFLY-3830?page=com.atlassian.jira.plugin....
]
Jeff Mesnil updated WFLY-3830:
------------------------------
Comment: was deleted
(was: As explained in the PR, the TIBCO JNDI provider accepts only CompoundName in its
lookup(Name) method.
With the PR, it is possible to use the external-context with TIBCO EMS by using the
StringOnlyInitialContext wrapper that convert the lookup(Name) call to the corresponding
lookup(String) call.
{noformat}
<external-context name="java:global/tibco" module="com.tibco"
class="org.jboss.as.naming.StringOnlyInitialContext">
<environment>
<property name="java.naming.factory.initial"
value="com.tibco.tibjms.naming.TibjmsInitialContextFactory"/>
<property name="java.naming.provider.url"
value="tcp:/<server>:<port>"/>
<property name="java.naming.factory.url.pkgs"
value="com.tibco.tibjms.naming"/>
</environment>
</external-context>
{noformat}
Note that the com.tibco module *must* have a dependency on the org.jboss.as.naming module
to access this wrapper.
)
Use external-context for remote TIBCO ems lookup
------------------------------------------------
Key: WFLY-3830
URL:
https://issues.jboss.org/browse/WFLY-3830
Project: WildFly
Issue Type: Bug
Components: Naming
Affects Versions: 8.1.0.Final
Reporter: Jeff Mesnil
Assignee: Jeff Mesnil
If an users uses the generic JMS RA with the TIBCO EMS messaging server, he has to
duplicate all the JNDI parameters in the MDB annotations.
Instead, he should be able to use a naming's external-context to connect to the
Remote TIBCO server with the following configuration:
{noformat}
<bindings>
<external-context name="java:global/tibco"
module="com.tibco" class="javax.naming.InitialContext">
<environment>
<property name="java.naming.factory.initial"
value="com.tibco.tibjms.naming.TibjmsInitialContextFactory"/>
<property name="java.naming.provider.url"
value="tcp://<tibco_server>:<tibco_port>"/>
<property name="java.naming.factory.url.pkgs"
value="com.tibco.tibjms.naming"/>
</environment>
</external-context>
</bindings>
{noformat}
With these settings, the user only needs to pass the expected connection factory and
destination lookup in the MDB:
{noformat}
@ActivationConfigProperty(propertyName = "connectionFactory",
propertyValue = "java:global/tibco/XACF"),
@ActivationConfigProperty(propertyName = "destination", propertyValue =
"java:global/tibco/Q1"),
{noformat}
The local JNDI lookup "java:global/tibco/Q1" will then use the external context
(bound to "java:global/tibco") to lookup the "Q1" name on the TIBCO
EMS.
There are a few bugs in the ExternalObjectFactory that prevents to use this configuration
with a regular javax.naming.InitialContext to build the external context.
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)