Skip to main content

Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "SMILA/Documentation/QueueWorker/BrokerConnectionService"

(Configuration)
(Configuration Sample)
Line 20: Line 20:
 
== Configuration Sample==
 
== Configuration Sample==
 
<source lang="java">
 
<source lang="java">
<ConnectionsConfig xmlns="http://www.eclipse.org/eilf/queue"
+
<ConnectionsConfig xmlns="http://www.eclipse.org/smila/queue"
 
   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
 
   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
 
   xsi:noNamespaceSchemaLocation="schemas/QueueWorkerConfig.xsd"
 
   xsi:noNamespaceSchemaLocation="schemas/QueueWorkerConfig.xsd"

Revision as of 05:00, 13 November 2008

What is Broker Connection Service

The main goal of Broker Connection Service is to provide common cached connection pool to JMS brokers for Router and Listener.


Interface

public interface BrokerConnectionService {
  Connection getConnection(QueueConnectionType connectionType, boolean cached) throws BrokerConnectionException;
}

Configuration

Schema:org.eclipse.smila.connectivity.queue.worker/schemas/QueueWorkerConfig.xsd Location: "configuration/org.eclipse.smila.connectivity.queue.worker/ConnectionConfig.xml"

Configuration is a list of JMS broker connection specific properties like URL, user, password and connection type (factory). Also it should be specified unique Id for each connection configuration.

Configuration Sample

<ConnectionsConfig xmlns="http://www.eclipse.org/smila/queue"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:noNamespaceSchemaLocation="schemas/QueueWorkerConfig.xsd"
>
 
  <ConnectionConfig Id="broker1">
    <URL>tcp://localhost:61616</URL>
    <User>any</User>
    <Password>any</Password>
    <ConnectionFactory>org.apache.activemq.ActiveMQConnectionFactory</ConnectionFactory>
  </ConnectionConfig>
 
  <ConnectionConfig Id="broker_alernate">
    <URL>tcp://10.0.0.1:61616</URL>
    <User>me</User>
    <Password>mypass</Password>
    <ConnectionFactory>org.apache.activemq.ActiveMQConnectionFactory</ConnectionFactory>
  </ConnectionConfig>
 
 
</ConnectionsConfig>

Back to the top