10.15. Configuring the JBoss Remoting Gateway

Here is the basic configuration of the JBoss Remoting provider:
<jbr-provider name="socket_provider" protocol="socket" host="localhost">
    <jbr-bus busid="socket_bus" port="64111"/>
The <jbr-bus> can then be referenced from a <service> configuration through the <jbr-listener>:
    <jbr-listener name="soc" busidref="socket_bus" is-gateway="true"/>


The <jbr-listener> is only supported as a gateway. If you set is-gateway to false an error will occur.
You can set the following configuration options for the JBoss Remoting Gateway on any of the <jbr-provider>, <jbr-bus> or <jbr-listener> elements (set them as <property> elements).

Table 10.11. Configuration

Name Description Default
synchronous Is the target Service to be invoked Synchronously. True
serviceInvokerTimeout Asynchronous invocation timeout. 20000
asyncResponse Asynchronous response. "<ack/>
securityNS This is the namespace for the version of Web Service Security that should be used. This namespace is used to match security headers in SOAP messages. This is to allow the Enterprise Service Bus to extract security information from these headers. http://docs.oasis-open.org/wss/2004/01/oasis-200401http-wss-wssecurity-secext-1.0.xsd

Also note that you can set JBoss Remoting-specific configuration properties. This can be done by prefixing the property name with "jbr-". Consult the JBoss Remoting documentation (http://www.jboss.org/jbossremoting/) for details.
Here is an example of a configuration that uses JBoss Remoting- specific settings to configure a keystore and client authentication mode for HTTPS:
<jbr-provider name="https_provider" protocol="https" host="localhost">
    <!-- Https/SSL settings -->
    <property name="jbr-KeyStoreURL" value="/keys/myKeystore" />
    <property name="jbr-KeyStorePassword" value="keys_ssl_pass" />
    <property name="jbr-TrustStoreURL" value="/keys/myKeystore" />
    <property name="jbr-TrustStorePassword" value="keys_ssl_pass" />
    <property name="jbr-ClientAuthMode" value="need" />
    <property name="serviceInvokerTimeout" value="20000" />

    <jbr-bus busid="https_bus" port="9433"/>


The JBoss Remoting Gateway expects all response headers to be located in the Message.Properties as instances of org.jboss.soa.esb.message.ResponseHeader class. If you require the Gateway to set specific response headers, the enterprise service bus message provided to the gateway response decompose (for example, after a synchronous invocation of the target service) must contain instances of the ResponseHeader class, set on the Message.Properties.