Business Objects products in this release may contain redistributions of software
licensed from third-party contributors. Some of these individual components may
also be available under alternative licenses. A partial listing of third-party
contributors that have requested or permitted acknowledgments, as well as required
notices, can be found at: http://www.businessobjects.com/thirdparty
2008-08-26
Contents
Introduction7Chapter 1
About this guide...........................................................................................8
Error handling and tracing....................................................................48
Appendix49Chapter 4
Weblogic as JMS Provider ........................................................................50
To create a JMS Connection Factory........................................................50
To configure the Connection Factory...................................................50
Create a JMS queue..................................................................................51
4Data Services JMS Adapter Interface
Contents
Index53
Data Services JMS Adapter Interface5
Contents
6Data Services JMS Adapter Interface
Introduction
1
Introduction
1
About this guide
About this guide
This guide provides a detailed step-by-step method of installing and
configuring the Data Services JMS adapter. It includes a description of
required support software, including supported versions, details of the adapter
components, environment setup both for Data Services and external
applications, and instructions for executing the adapter.
Who should read this guide
This document assumes the following:
•You understand how to use Data Services Designer to design and run
real-time data flows (RTDFs) and batch jobs.
•You have a basic understanding of how to use Data Services Administrator
to administer Data Services processes. (You administer adapters from
the Administrator.)
•You have a working knowledge of the environment this adapter is
targeting.
•You know the role an adapter plays in business systems integration.
•You have some familiarity with XML and XML configuration schemas.
•Also, to integrate Data Services with an external system, Business Objects
recommends that you be familiar with systems administration and systems
integration issues.
General Data Services product documentation assumes the following:
•You are an application developer, consultant or database administrator
working on data extraction, data warehousing, or data integration.
•You understand your source and target data systems, DBMS, legacy
systems, business intelligence, and messaging concepts.
•You understand your organization's data needs.
•If you are interested in using this product to design real-time processing
you are familiar with:
•DTD and XML Schema formats for XML files
8Data Services JMS Adapter Interface
•Publishing Web Services (WSDL, HTTP/S and SOAP protocols, etc.)
•You are familiar with Data Services installation environments: Microsoft
Windows or UNIX.
Adapter overview
Typical enterprise infrastructure is a complex mix of off-the-shelf and custom
applications, databases, ERP applications etc. Data Services combines and
extends critical Extraction Transformation Loading (ETL) and Enterprise
Application Integration (EAI) technology components required for true
enterprise data integration.
Integrating disparate applications with the Business Objects Data Integration
platform requires adapters. These adapters help facilitate otherwise
incompatible applications and systems work together, thereby sharing data.
About Java Messaging Service (JMS)
Introduction
Adapter overview
1
Enterprise-messaging or Message Oriented Middleware (MOM) products
are fast becoming an essential component for integrating intra-company
operations. They allow separate business components to be combined into
a reliable, yet flexible, system. In addition to the traditional MOM vendors,
several database vendors and Internet-related companies also provide
enterprise-messaging products.
Java language clients and Java language middle-tier services must be
capable of using these messaging systems. Java Messaging Service (JMS)
provides a common way for Java language programs to access these
systems.
JMS is a set of interfaces and associated semantics that define how a JMS
client accesses the facilities of an enterprise-messaging product. Since
messaging is peer-to-peer, all users of JMS are generically referred to as
clients. A JMS application is composed of a set of application-defined
messages and a set of clients that exchange them. Products that implement
JMS do this by supplying a provider that implements the JMS interfaces.
Data Services JMS Adapter Interface9
Introduction
1
Adapter overview
Scope of the JMS adapter
•Data Services initiates Request/Reply
Data Services initiates the request by sending the message on a
pre-configured request queue and gets the reply on a pre-configured reply
queue.
•Data Services initiates Request/Acknowledgment
Data Services initiates the request by sending the message on a
pre-configured target queue or by publishing a message to a JMS topic.
In this case, only the acknowledgment is sent back to Data Services.
In this case, an external Information Resource (IR is a JMS compatible
application) sends the requests to Data Services and gets the reply or
acknowledgment.
Alternatively, the IR publishes a message to a JMS topic to which the
JMS Adapter has subscribed.
10Data Services JMS Adapter Interface
Installation and
configuration
2
Installation and configuration
2
Installing the JMS adapter
Installing the JMS adapter
This section details the components of the Data Services Adapter for JMS
as well as system requirements and installation information.
System prerequisites
Before you install your Data Services Adapter for JMS, ensure that the
following software is installed. For specific installation instructions, see the
technical documentation for each product.
CommentVersionSoftware
JMS Provider
11.7.0 or laterData Services
Data Services Adapter
SDK
2.0.0.0 or later
Adapter product components
The following diagram shows a functional overview of the Data Services
Adapter for JMS with other components and their potential interrelationships:
For example, Weblogic
Application Server
Use Data Services to
configure the services
and adapter
12Data Services JMS Adapter Interface
Installation and configuration
Installing the JMS adapter
2
The diagram shows the architecture and functionality of the Data Services
Adapter for JMS as well as how the Data Services Adapter for JMS interacts
with the external JMS application through the JMS Provider. The Data
Services Adapter for JMS sends or receives data on queues using the Point
to Point (P2P) mode of communication, or publishes or subscribes to a JMS
topic using the Publish/Subscribe mode of communication.
The flow of control in the previous diagram is as follows:
1. External application invokes a service on Data Services.
2. Based on the service invoked on Data Services, its respective real-time
data flow (RTDF) invokes the Operation instance with XML data sent by
the external application as input.
3. This operation instance sends the message to the configured queue or
topic in the JMS provider. Based on the type of operation (such as
Request/Reply or Request/Acknowledge), the JMS provider sends the
Reply/Acknowledgment message back to Data Services.
Data Services JMS Adapter Interface13
Installation and configuration
2
JMS adapter configuration
4. External JMS application sends messages to the JMS Provider on a
request queue or publishes the message to a topic. The JMS Adapter
receives these messages after polling them from the JMS Provider and
for P2P, sends the reply back to external JMS application on a configured
reply queue. No reply is sent if the message was from a topic.
Installing JMS adapter
The Data Services Adapter for JMS is automatically installed when you install
Data Services version 12.0.0 or later.
JMS adapter configuration
Before the Data Services Adapter for JMS can begin integrating the JMS
Provider with the Data Services system you must create and configure at
least one adapter instance and at least one operation for each instance.
Adapter instances identify the JMS Application used in the integration.
Adapter operations identify the integration operations to be used with the
configured adapter instance.
Operations provided with Data Services Adapter for JMS include the following:
•PutGet Operation (Request/Reply): Data Services initiates a request,
sending a message on a pre-configured request queue. Simultaneously,
Data Services listens on a pre-configured reply queue. An external
JMS-compatible application listens on the request queue, processes the
request, and returns an XML response message to the reply queue. The
adapter sends the message to the Data Services service.
•Put Operation (Request/Acknowledgment): Data Services initiates a
request, sending a message on a pre-configured target queue. If the
message was sent successfully, the adapter sends an acknowledgement
to the Data Services service. The adapter raises an exception if it was
unable to send the message.
•Get Operation (Request/Acknowledgment and Request/Reply from
Information Resource): An external information resource (IR) sends a
request XML message to a JMS queue. The adapter polls the JMS queue
at a time interval you specify in the configuration. When the adapter
receives a message from the JMS queue, it sends the message to the
pre-configured Data Services service.
14Data Services JMS Adapter Interface
After processing the XML message, the Data Services service may send
a response message to the adapter. When this happens, the adapter
puts the message in a pre-configured response queue. If the response
queue is not configured, it becomes a request/acknowledgment operation
and no reply is sent. If there is any error in invoking another service from
the Data Services service, the original message is sent to the undelivered
queue for reference by the IR.
•PutTopic Operation (Request/Acknowledgment): A Data Services service
initiates a request, publishing an XML message to a pre-configured target
topic. If the message was sent successfully, the adapter sends an
acknowledgement to the Data Services service. The adapter raises an
exception if it was unable to send the message.
•GetTopic Operation (Request/Acknowledgment): An external information
resource (IR) publishes an XML message to a JMS topic. The adapter
polls the topic at the time intervals specified in the configuration. When
the adapter receives the message from the topic, it sends the message
to the Data Services service that handles the message.
Configuring the JMS adapter
Installation and configuration
JMS adapter configuration
2
All Data Services adapters communicate with Data Services through a
designated Adapter Manager Job Server. Install adapters on the computer
containing your designated Adapter Manager Job Server. This special Job
Server integrates adapters with Data Services using the Administrator and
Designer. After you install your adapter:
1. Use the Server Manager utility to configure adapter connections with the
Adapter Manager Job Server.
2. From the Data Services Administrator, perform the following tasks:
•Add at least one instance of the adapter to Data Services system.
•Add at least one operation for each adapter instance.
•Start the adapter instance (operations are started automatically).
3. Open the Data Services Designer and create an adapter datastore. Use
metadata accessed through the adapter to create batch and/or real-time
jobs.
Data Services JMS Adapter Interface15
Installation and configuration
2
JMS adapter configuration
Related Topics
•Installation Guide: To configure Job Servers
Configuring an adapter instance
From the Data Services Administrator you can add a JMS adapter to the
Data Services system as well as edit existing adapter configurations. Add
the adapter in the Administrator before you run jobs that use information
from that adapter.
To add an adapter instance in the Administrator
1. Select Adapter Instances > Job Server.
2. Select the Configuration tab.
3. Click Add.
4. Select JMSAdapter from the list of adapters available on this Job Server
and click Apply.
5. Enter the required information to create a JMS Adapter instance and click
Apply.
The Administrator makes the adapter instance available to Data Services.
Adapter instance configuration information
To configure a JMS adapter instance in Data Services, you need to complete
the fields in the Administrator under Adapter instance startup configuration.
16Data Services JMS Adapter Interface
Installation and configuration
JMS adapter configuration
DescriptionField
2
Adapter Instance
Name
Access Server
Host
Access Server
Port
Adapter Retry
Count
Interval
Classpath
Enter a unique name that identifies this instance of the
adapter.
Enter the host ID of the computer running the Access
Server that connects to this adapter instance. To run a realtime job, you must configure a service that the Access
Server will use to run the job. When a job uses adapterbased data, the Access Server must be able to connect to
the adapter instance.
The message broker port of the Access Server host. After
you log into the Administrator for this Access Server, select
Configuration > Client Interfaces to view message broker
port information.
Applies if adapter instance fails or crashes. Enter 0 for no
retries; enter a negative number for indefinite retries.
Wait in msec. between adapter retry attempts.Adapter Retry
The adapter is a Java program, so you must configure the
jar files required by the adapter CLASSPATH. The adapter
is pre-configured with all necessary jar files except for the
vendor-specific JMS provider jar files. Add your JMS
provider's jar files to the CLASSPATH. For example:
•<LINK_DIR>/lib/acta_adapter_sdk.jar
•<LINK_DIR>/lib/acta_broker_client.jar
•<LINK_DIR>/lib/acta_tool.jar
•<LINK_DIR>/ext/lib/xerces.jar
•<LINK_DIR>/lib/acta_jms_adapter.jar
•<LINK_DIR>/ext/lib/jms/<JMS Provider Jar File>
Autostart
Note:
Specify the jar file provided with the JMS provider that you
are using. For Weblogic, the name of jar file is weblogic.jar.
When set to True, the adapter interface automatically starts
when the Administrator starts.
Data Services JMS Adapter Interface17
Installation and configuration
2
JMS adapter configuration
DescriptionField
Trace Mode
Additional Java
Launcher Options
Adapter Type
Name
Adapter Version
Adapter Class
Set this flag to control the number of trace messages the
adapter produces. There are two settings:
•True: The adapter interface writes information and error
messages to help debug problems. The adapter writes
information and error messages to the adapter_instance_name_trace.txt file in the LINK_DIR\adapters\logs
directory.
•False: The adapter interface writes only error information
messages. The adapter writes error messages to the
adapter_instance_name_error.txt file in the
LINK_DIR\adapters\logs directory.
Additional command line parameters used for the javaw.exe
command line and for the adapter itself. (See specific
adapter documentation for details.)
(Read-only) Name of the adapter used to create this instance.
(Read-only) Version of the adapter used to create this instance.
(Read-only) Name that identifies the adapter class. The
name depends on the type of adapter.
In the JMS Adapter section, select a Configuration Type and enter
Configuration parameters.
DescriptionParameter
Configuration
Type
Uses only the configuration parameters associated with the
selected configuration type.
•JNDI configuration type
•MQ configuration type
For the JNDI configuration type, use the following configuration parameters.
18Data Services JMS Adapter Interface
Installation and configuration
JMS adapter configuration
DescriptionParameter
2
Server URL
JNDI Context
Factory
Queue Connection Factory
Topic Connection Factory
For the MQ configuration type, use the following configuration parameters.
Represents the URL of the JMS Provider. For example:
t3://<JMS Provider IP Address>:<port number>.
JNDI context factory name is JMS Provider specific. You can
choose the context factory from a list.which includes common
context factories. If you require a context factory that is not
listed, you can add it to the list by editing file
%LINK_DIR%/adapters/config/templates/JMSAdapter.xml
and updating the <jndiFactory> element. For Weblogic as a
JMS Provider, the JNDI Factory name is: weblogic.jndi.WLInitialContextFactory.
Queue connection factory name. For example: JMSConnections.AdapterConnectionFactory.
Topic connection factory name. For example: JMSConnections.AdapterTopicConnectionFactory.
Data Services JMS Adapter Interface19
Installation and configuration
2
JMS adapter configuration
DescriptionParameter
MQ Queue
Manager
Name
MQ Channel
Name
MQ Computer Name
MQ User ID
MQ Password
(Optional) Specify if not using the default MQ Queue Manager
on the system running MQ.
(Optional) Specify if not using the default MQ Channel on the
system running the adapter.
(Optional) Specify if not using the MQ Queue Manager on the
same system running the adapter.
(Optional) Specify if not using the default MQ port (1414).MQ Port
(Optional) Specify if required to login to the MQ Queue Manager.
(Optional) Specify if required to login to the MQ Queue Manager.
Configuring an operation instance
To add an operation instance to an adapter instance
1. Select Configuration > Adapter instances.
2. Click Operations under Dependent Objects.
3. Click Add to configure a new operation. Or, you can click the link of an
existing operation instance to edit its configuration.
4. Select an operation type from the list and click Apply. The options that
appear on this page vary based on operation-specific design.
Complete the operation instance configuration form (see operation instance
configuration information for details) and click Apply.
Operation instance configuration options
Each operation type contains different configuration options. Operations
include:
When specifying a queue or topic, you must provide the JNDI queue name
or the MQ queue name as indicated by the Adapter Configuration Type
property.
Put Operation (request/acknowledgment) options
To set up an operation instance of type Put Operation in Data Services
system, complete the following fields in the Administrator.
DescriptionFIeld
2
Operation instance
Thread count
Operation retry
count
Operation retry
interval
Display name
Description
The unique operation instance name. In the Designer, your
operation metadata object is imported with this name.
The number of copies of Request/Reply operation to run in
parallel. For parallel (asynchronous) processing of messages
coming from real-time service, more than one copy should be
used. But if the sequence of messages is important (synchronous processing), more than one thread should not be
used. (Multiple copies of real-time services must be supported
by multiple instances of Request/Reply.) The default is 1.
The number of times to retry this operation if it fails. Enter 0
to indicate no retries are to be attempted. Enter a negative
number to indicate the operation should be retried indefinitely.
The time (in milleseconds) to wait between operation retry
attempts.
The display name of the operation instance. This display name
is visible in the Designer's metadata browsing window.
The description of the operation instance. This description is
visible in the Designer's metadata browsing window.
Data Services JMS Adapter Interface21
Installation and configuration
2
JMS adapter configuration
DescriptionFIeld
Enable
Destination
Queue
Request Format
Root Element
Whether to enable the operation to start at the same time as
the adapter instance. Valid values are true and false.
•When true, the operation starts when the adapter instance
starts.
•When false, the operation needs to be started manually
from "Adapter Operations Status" window of the adapter
administrator.
The name of the destination queue where the message will
be sent.
The DTD or XSD file name that defines the XML message
used in the operation.
To set up an operation instance of type PutTopic in the Data Services,
complete the following fields in the Administrator.
DescriptionField
Operation instance
Thread count
Operation retry
count
Operation retry
interval
22Data Services JMS Adapter Interface
The unique operation instance name. In the Designer, your
operation metadata object is imported with this name.
The number of copies of Request/Reply operation to run in
parallel. For parallel (asynchronous) processing of messages
coming from real-time service, more than one copy should be
used. But if the sequence of messages is important (synchronous processing), more than one thread should not be
used. (Multiple copies of real-time services must be supported
by multiple instances of Request/Reply.) The default is 1.
The number of times to retry this operation if it fails. Enter 0
to indicate no retries are to be attempted. Enter a negative
number to indicate the operation should be retried indefinitely.
The time (in milliseconds) to wait between operation retry attempts.
Installation and configuration
JMS adapter configuration
DescriptionField
2
Display name
Description
Enable
Destination
Topic
Message Format
Root Element
Persistent
Message
The display name of the operation instance. This display name
is visible in the Designer's metadata browsing window.
The description of the operation instance. This description is
visible in the Designer's metadata browsing window.
Whether to enable the operation to start at the same time as
the adapter instance. Valid values are true and false.
•When true, the operation starts when the adapter instance
starts.
•When false, the operation needs to be started manually
from "Adapter Operations Status" window of the adapter
administrator.
The topic to which the operation is published. Use JNDI or
MQ name as specified by Adapter Configuration Type.
The DTD or XSD file name defining the XML message used
in this operation.
The name of the XML root element.Request XML
Whether to make published messages available to durable
subscribers. Valid values are true and false. When true, published messages are available to durable subscribers.
PutGet Operation (request/reply) options
To set up an operation instance of type PutGet Operation in Data Services
system, complete the following fields in the Administrator.
Data Services JMS Adapter Interface23
Installation and configuration
2
JMS adapter configuration
DescriptionField
Operation instance
Thread count
Operation retry
count
Operation retry
interval
Display name
Description
Enable
The unique operation instance name. In the Designer, your
operation metadata object is imported with this name.
The number of copies of Request/Reply operation to run in
parallel. For parallel (asynchronous) processing of messages
coming from real-time service, more than one copy is used.
If the sequence of messages is important (synchronous
processing), more than one thread should not be used.
(Multiple copies of real-time services must be supported by
multiple instances of Request/Reply.) The default is 1.
The number of times to retry this operation if it fails. Enter 0
to indicate no retries are to be attempted. Enter a negative
number to indicate the operation should be retried indefinitely.
The amount of time (in milliseconds) to wait between operation retry attempts.
The display name of the operation instance. This display
name is visible in the Designer's metadata browsing window.
The description of the operation instance. This description
is visible in the Designer's metadata browsing window.
Whether to enable the operation to start at the same time as
the adapter instance. Valid values are true and false.
•When true, the operation starts when the adapter instance
starts.
•When false, the operation needs to be started manually
from "Adapter Operations Status" window of the adapter
administrator.
Request Queue
Reply Queue
Timeout
24Data Services JMS Adapter Interface
The name of the destination queue where the message will
be sent.
The name of the destination queue where the message will
be sent.
The maximum time (in milliseconds) the operation should
wait for the reply message.
Installation and configuration
JMS adapter configuration
DescriptionField
2
Continue After
Error
Request Format
Request XML
Root Element
Reply Format
Element
Whether to continue after encountering an error. Valid values
are true and false.
•When true, the operation instance remains in start stage
even after the error.
•When false, the operation instance stops after the error
occurs during the process.
The DTD or XSD file name that defines the Request XML
message used in this operation.
The name of the XML root element in the Request DTD or
XSD.
The DTD or XSD file name that defines the Reply XML
message used in the operation.
The name of the XML root element in the Reply DTD or XSD.Reply XML Root
Get Operation (request/reply and request/acknowledgment)
options
To set up an operation instance of type Get Operation in Data Services
system, complete the following fields in the Administrator.
Operation instance
Polling interval
Operation retry
count
Operation retry
interval
DescriptionField
The unique operation instance name. In the Designer, your
operation metadata object is imported with this name.
The time interval (in milliseconds) for polling the source queue
by this operation instance. For example, If the polling interval
is 1000, then it polls the source queue after every one second.
The number of times to retry this operation if it fails. Enter 0
to indicate no retries are to be attempted. Enter a negative
number to indicate the operation should be retried indefinitely.
The time (in milliseconds) to wait between operation retry attempts.
Data Services JMS Adapter Interface25
Installation and configuration
2
JMS adapter configuration
DescriptionField
Enable
Source Queue
Service
Timeout
Continue After
Error
Whether to enable the operation to start at the same time as
the adapter instance. Valid values are true and false.
•When true, the operation starts when the adapter instance
starts.
•When false, the operation needs to be started manually
from "Adapter Operations Status" window of the adapter
administrator.
The name of the queue where the message is sent by the IR
and received by the adapter. Use JNDI or MQ name as
specified by the Adapter Configuration Type.
The name of Data Services real-time service invoked by the
operation when it receives a new message from the Source
Queue.
The maximum time (in milliseconds) that the Service takes to
process a message. If the operation instance is unable to invoke the service within the Timeout limit, it sends the error
message to the undelivered queue.
Whether to continue after encountering an error. Valid values
are true and false.
•When true, the operation instance remains in start stage
even after the error.
•When false, the operation instance stops after the error
occurs during the process.
26Data Services JMS Adapter Interface
Installation and configuration
JMS adapter configuration
DescriptionField
2
Default Response Queue
Undelivered
Queue
Request DTD
Root Element
[optional]: Used only for Request/Reply operation. In case of
Request/Acknowledgment operation, it remains blank. The
application sends the reply back to external JMS application
(IR) on this queue. Use JNDI or MQ name as specified by the
Adapter Configuration Type.
[optional]: The undelivered queue for receiving the error
messages, if any. Use JNDI or MQ name as specified by the
Adapter Configuration Type.
The name of the root element for the input DTD for this operation.
To set up an operation instance of type GetTopic in Data Services system,
complete the following fields in the Administrator.
DescriptionField
Operation instance
Polling interval
The unique operation instance name. In the Designer, your
operation metadata object is imported with this name.
The time interval (in milliseconds) for polling the source topic
by this operation instance. For example, if the polling interval
is 1000, then it polls the source topic after every one second.
Operation
retry count
Operation
retry interval
Enable
The number of times to retry this operation if it fails. Enter 0 to
indicate no retries are to be attempted. Enter a negative number
to indicate the operation should be retried indefinitely.
The time (in milliseconds) to wait between operation retry attempts.
Whether to enable the operation to start at the same time as
the adapter instance. Valid values are true and false.
•When true, the operation starts when the adapter instance
starts.
•When false, the operation needs to be started manually
from "Adapter Operations Status" window of the adapter
administrator.
Data Services JMS Adapter Interface27
Installation and configuration
2
JMS adapter configuration
DescriptionField
Source Topic
Durable subscriber
Service
Timeout
Continue After Error
The topic to which the operation subscribes. Use JNDI or MQ
name as specified by Adapter Configuration Type.
The subscription name of Durable subscriber. If not applicable,
leave this field blank.
The name of Data Services real-time service invoked by the
operation when it receives a new message from the source
topic.
The maximum time (in milliseconds) that the service takes to
process a message.
Whether to continue after encountering an error. Valid values
are true and false.
•When true, the operation instance remains in start stage
even after the error.
•When false, the operation instance stops after the error oc-
curs during the process.
Defining a JMS adapter datastore
Use the Data Services Adapter for JMS with a batch job or real-time data
flow (RTDF) when the batch job or RTDF passes a message to an operation
instance, using either:
•A Message Function (for Request/Reply operations)
You must first define an adapter datastore in the Data Services Designer.
Then, the batch job or RTDF can pass a message to one of the adapter
operation instances defined in that datastore. To define an adapter, you
must:
•Define a datastore object for each adapter instance
•Define one function or one outbound message for each operation instance
to which you want to pass a message.
28Data Services JMS Adapter Interface
Installation and configuration
JMS adapter configuration
For each adapter instance, define a corresponding datastore object in the
Datastore Editor window of the Designer object library.
To define a JMS adapter datastore
1. From the Datastore Editor:
a. Select the Job Server configured to manage your JMS adapter.
b. Select the Adapter instance name you configured in the Administrator.
2. Select the Adapter Properties tab and enter values for each property.
3. Click OK to save values and create the datastore.
Importing message functions and outbound messages
to the datastore
You can pass messages from a batch job or RTDF to an operation instance.
Import either a function or an outbound message (depends on the type of
operation involved) in the Designer Datastore library for each operation
instance.
2
Real-time data flows use following methods.
DescriptionMethod
Message functions
Outbound messages
Operation types in the Data Services Adapter for JMS have the following
invocation types.
Pass messages to an operation instance if the RTDF
waits for a return XML message from the IR.
Outbound messages Pass messages to an operation instance if the RTDF waits for a confirmation only (not a
return XML message) from the IR.
Invocation TypeOperation Type
Message FunctionRequest/Reply Operation
Data Services JMS Adapter Interface29
Installation and configuration
2
JMS adapter configuration
Invocation TypeOperation Type
Request/Acknowledge Operation
Outbound Message
To import message functions and outbound messages
1. In Data Services Designer, double-click the datastore associated with
your JMS Adapter Instance to display the Adapter metadata browser
window.
2. Right-click the operation instance to be imported and select Import.
The selected operation instance is added to the datastore.
These message functions and outbound message functions can be used for
creating Batch Jobs or RTDFs in Data Services.
30Data Services JMS Adapter Interface
Using the JMS Adapter
3
Using the JMS Adapter
3
Starting an instance of the JMS adapter
Starting an instance of the JMS adapter
1. From the Data Services Administrator go to Adapter Instance -> Job
Server, select the Status tab.
2. Select the check-box next to the previously configured adapter instance.
3. Click Start.
When the adapter instance and its operations start, the message “Started”
appears in the Status column.
Operations from Data Services to the JMS Adapter
Request/Reply - PutGet operation
Data Services initiates the request by sending a message on a pre-configured
request queue. Simultaneously, Data Services also listens on a pre-configured
reply queue. An external JMS-compatible application listening on this request
queue, after processing, sends back the response on response queue. This
response, in the form of the reply XML message, is returned back to Data
Services.
Related Topics
•Testing PutGet: Request/Reply on page 37
Request/Acknowledge - Put operation
Data Services initiates the request by sending the message on a
pre-configured target queue.
Related Topics
•Testing Put: Request/Acknowledge on page 45
Request/Acknowledge - PutTopic operation
Data Services initiates the request by publishing the message to a
pre-configured target topic.
32Data Services JMS Adapter Interface
Using the JMS Adapter
Starting an instance of the JMS adapter
Related Topics
•Testing Put: Request/Acknowledge on page 45
Operations from Information Resource (IR) to Data
Services
Request/Reply - Get operation
IR initiates the request by putting a message in the source queue of the Get
operation. The Get operation receives the message from the source queue
during a polling cycle and sends the message to the configured Data Services
service. The service sends a reply message to the Get operation, which then
puts the message in the response queue. The IR then gets the message
from the response queue.
Related Topics
•Testing Get: Request/Reply on page 41
3
Request/Acknowledge - Get operation
IR initiates the request by putting a message in the source queue of the Get
operation. The Get operation receives the message from the source queue
during a polling cycle and sends the message to the configured Data Services
service.
Related Topics
•Testing Get: Request/Acknowledge on page 44
Request/Acknowledge - GetTopic operation
IR initiates the request by publishing a message to the source topic of the
GetTopic operation. The GetTopic operation receives the message from the
source queue during a polling cycle and sends the message to the configured
Data Services service.
Data Services JMS Adapter Interface33
Using the JMS Adapter
3
Running the sample
Related Topics
•Testing GetTopic Operation on page 42
Running the sample
This section details the JMS Adapter operations.
To run the sample
1. Import the JMSAdapter.atl file into Data Services Designer. Find the ATL
file in %LINK_DIR%/adapters/jms/samples. The imported project name
is Acta_JMSAdapter_Sample.
2. Change the input and output XML files path for all the batch jobs
depending on your location of your Data Services <LINK_DIR>
environment variable.
3. Use the Administrator Real-Time Services Configuration tab to create the
service Queue.TestService referencing job TestService_Job and
Topic.TestService referencing job TestServiceTopic_Job.
4. Open Data Services Web Administrator and configure a JMS adapter.
Define the operations detailed in the following tests.
5. Use the Data Services Designer to edit the JMSAdapter datastore and
rename it to the name of the adapter you just created.
Before running the sample, create the following queues and topic using your
JMS provider utilities:
•Queue.MyQueue
•Queue.ActaQueuePutGet
•Queue.ActaQueuePutGet1
•Queue.ActaQueueGet
•Queue.ActaReplyQueueGet
•Queue.ActaUndeliveredQueue
•Topic.MyTopic
34Data Services JMS Adapter Interface
Note:
The JMSAdapterTest.properties file and the scripts to execute the samples
are located in the <LINK_DIR>/adapters/jms/samples directory.
The JMSAdapterTest.properties file TopicConnectionFactoryName property
value is Tcf and the QueueConnectionFactoryName property value is Qcf.
You must edit this file and change the property values if the adapter was
configured using different factory names.
The JMSAdapterTest.properties file MessageSource property refers to the
file C:/Program Files/Business Objects/Data Integrator
11/adapters/jms/samples/xml/JMSSource.xml. You must edit this file and
change the property value if this is not where your JMSSource.xml file is
located.
You must edit setTestEnv.bat on Windows or setTestEnv.sh on Unix to set
the JMS Provider jar files in the class path used by the sample test programs.
Configuring the JMS provider
Using the JMS Adapter
Running the sample
3
Create a JMS Server, Connection Factory and configure JMS queues to run
Data Services JMS Adapter. For testing JMS Adapter, using sample
applications, configure the following queues and topic:
•Queue.MyQueue
•Queue.ActaQueuePutGet
•Queue.ActaQueuePutGet1
•Queue.ActaQueueGet
•Queue.ActaReplyQueueGet
•Queue.ActaUndeliveredQueue
•Topic.MyTopic
Refer to the Appendix section for instructions on using Weblogic as the JMS
Provider. Steps for JMS Provider may differ from the example provided in
this section.
Data Services JMS Adapter Interface35
Using the JMS Adapter
3
Running the sample
Using MQ instead of JNDI configuration
The properties file used by the samples, JMSAdapterTest.properties, is set
up to use the JNDI configuration. You can edit this file to use MQ configuration
parameters
To edit the JMSAdapterTest.properties file for MQ configuration
parameters
1. Set ConfigType = MQ.
2. Set any of the following properties as required by your system:
•MqQueueManager
•MqChannel
•MqComputerName
•MqPort
•MqUserID
•MqPassword
3. For the queue and topic names, use MQ names instead of the JNDI
names for the following properties:
•TopicGetName
•TopicPutName
•QueueSourceGetName
•QueueResponseGetName
•QueuePutName
•QueueRequestPutGetName
•QueueReplyPutGetName
36Data Services JMS Adapter Interface
Testing PutGet: Request/Reply
To configure the Operation Type PutGet (Request/Reply), enter the following
information in the operation instance configuration page in Data Services
Web Administrator.
EnterOption
JMSPutGetOperationOperation instance
1Thread count
JMSPutGetOperationDisplay name
This operation instance represents the
PutGet Request/Reply operation. It
Description
sends the request message to the request queue and receives the reply
message from the reply queue.
After entering this information, click Apply and restart JMS Adapter instance.
When the JMS Adapter starts running, the operation instance also starts
running.
Testing on Windows NT
Open a command prompt window and change directory to
<LINK_DIR>\adapters\jms\samples. Run the sample application (external
IR) by running sampleTest_PutGet.bat. The application displays the message:
Ready to receive message from queue Queue.ActaQueuePutGet
Execute the batch Job JMSPutGetOperation_BatchJob from the Data
Services Designer. This sends the message to the request queue.
The sample application (external IR) listens for a message to arrive at the
request queue of the JMSPutGetOperation instance. When it receives the
message, it prints a message to the command prompt window such as:
The sample test program then sends a reply message to the reply queue
configured for the JMSPutGetOperation instance. It echoes a message to
the command prompt window such as:
After the adapter operation receives the reply from the reply queue, it sends
the message to the Data Services job which then generates the output file
JMSSourceOutput_PutGet.xml under the directory
<LINK_DIR>/adapters/JMS/samples/xml. The contents of the file should be
similar to the message sent from the sample test with the addition of a
timestamp and error information.
Testing on UNIX
Run the sample application (external IR) by running sampleTest_PutGet.sh
file from the command prompt.
38Data Services JMS Adapter Interface
Execute the batch Job JMSPutGetOperation_BatchJob from Data Services
Designer. This sends the message at the request queue.
Sample application (external IR) listens for the message at the request queue
of JMSPutGetOperation instance and sends the message to the reply queue
configured for the JMSPutGetOperation instance. After receiving the reply
from the reply queue an output file JMSSourceOutput_PutGet.xml is
generated under the directory <LINK_DIR>/adapters/JMS/samples/xml.
Testing PutTopic Operation
To configure the Operation Type Put topic (Request/Acknowledge), enter
the following information in the operation instance configuration page in Data
Services Web Administrator.
EnterOption
JMSPutTopicOperationOperation instance
1Thread count
Using the JMS Adapter
Testing PutTopic Operation
3
Message Format
5Operation retry count
15000Operatin retry interval
JMSPutTopicOperation Display NameDisplay name
JMSPutTopicOperation Display NameDescription
trueEnable
TopicDestination Queue
C:\ProgramFiles\Business Objects\BusinessObjects Data Services
sourceRequest XML Root Element
truePersistent Message
Data Services JMS Adapter Interface39
Using the JMS Adapter
3
Testing PutTopic Operation
After entering this information, click Apply and restart JMS Adapter instance.
When the JMS Adapter starts running, the operation instance also starts
running.
Add the testing sections:
Testing on Windows NT
Open a command prompt window and change directory to
<LINK_DIR>\adapters\jms\samples. Run the sample application (external
IR) by running sampleTest_PutTopic.bat. The application should display the
message:
Ready to receive message from topic Topic.MyTopic
If you do not see this message, then start the JMS publish/subscribe broker.
The message should appear after you start the broker.
Execute the batch Job JMSPutTopicOperation_BatchJob from Data Services
Designer.
The sample application (external IR) listens for a message to be published
by the JMSPutTopicOperation instance. When it receives the message, it
will print a message to the command prompt window such as:
Received message:<?xml version="1.0" encoding="UTF-8"?>
<source><age>18</age><salary>200000000</salary><ac
no>2356376438743</acno></source>
After the adapter operation acknowledges sending the message to the IR,
the Data Services job then generates the output file
JMSSourceOutput_PutTopic.xml under the directory
<LINK_DIR>/adapters/JMS/samples/xml. The contents of the file should be
similar to the message received by the sample test with the addition of a
timestamp. Note that this file is created as a result of the design of the Data
Services job, not as a result of the adapter operation sending a reply message
to the job.
Testing on UNIX
Run the sample application by running sampleTest_Put.sh file from the
command prompt. This sample application listens at the destination queue
configured for the Put operation instance.
40Data Services JMS Adapter Interface
Execute the batch Job JMSPutOperation_BatchJob from Data Services
Designer.
Testing Get: Request/Reply
To configure the Operation Type Get (Request/Reply), enter the following
information in the operation instance configuration page in Data Services
Web Administrator.
EnterOption
JMSGetOperationOperation instance
1000Polling interval
1Thread count
trueEnable
Queue.ActaQueueGetSource Queue
Using the JMS Adapter
Testing Get: Request/Reply
3
After entering this information, click Apply and restart JMS Adapter instance.
When the JMS Adapter starts running, the operation instance also starts
running.
Testing on Windows NT
Run the sample application (external IR) by running sampleTest_Send.bat
file from the command prompt. This sample application sends the message
at the source queue of the Get operation instance configured at Data
Services.
Also, run another sample application (external IR) by running the batch file
sampleTest_Get.bat file, which receives the reply from Data Services on a
default response queue.
The sample application sampleTest_Send.bat (external IR) sends the
message as a request on a source queue configured for JMSGetOperation
instance. JMSGetOperation instance invokes the real-time batch job and
also sends the reply back at the default response queue. The sample
application sampleTest_Get.bat (external IR) receives the reply on this default
response queue. If any error occurs while invoking another service from this
Data Services service, then the original message is sent to the undelivered
queue, for reference by the IR.
Testing on UNIX
Run the sample application (external IR) by running sampleTest_Send.sh
file from the command prompt. This sample application sends the message
at the request queue of the operation instance configured at Data Services.
Also, run another sample application (external IR) by running the batch file
sampleTest_Get.sh file. This receives the reply from Data Services on a
default response queue.
The sample application sampleTest_Send.sh (external IR) sends the message
as a request on a source queue configured for JMSGetOperation instance.
JMSGetOperation instance will invoke the real-time batch job and also sends
the reply back at the default response queue. The sample application
sampleTest_Get.sh (external IR) receives the reply on this default response
queue. If any error occurs while invoking another service from this Data
Services service, then the error message is sent to the undelivered queue,
for reference by the IR.
Testing GetTopic Operation
To configure the Operation Type Get topic (Request/Acknowledge), enter
the following information in the operation instance configuration page in Data
Services Web Administrator.
42Data Services JMS Adapter Interface
Using the JMS Adapter
Testing GetTopic Operation
EnterOption
JMSGetTopicOperationOperation instance
1000Polling interval
1Thread count
trueEnable
Topic.MyTopicSource Topic
Topic.TestServiceService
2000Timeout
trueContinue After Error
After entering this information, click Apply and restart JMS Adapter instance.
When the JMS Adapter starts running, the operation instance also starts
running.
3
Testing on Windows
Run the sample application (external IR) by running the
sampleTest_GetTopic.bat file from the command prompt. This sample
application publishes a message to the source topic of the GetTopic operation
instance.
JMSGetTopicOperation, which has subscribed to the topic, receives the
message and sends it to the real-time service. The service then puts the
message into file JMSFileTarget_GetTopic.xml in directory
<LINK_DIR>/adapters/jms/samples/xml.
Testing on UNIX
Run the sample application (external IR) by running the
sampleTest_GetTopic.sh file from the command prompt. This sample
Data Services JMS Adapter Interface43
Using the JMS Adapter
3
Testing Get: Request/Acknowledge
application publishes a message to the source topic of the GetTopic operation
instance.
JMSGetTopicOperation, which has subscribed to the topic, receives the
message and sends it to the real-time service. The service then puts the
message into file JMSFileTarget_GetTopic.xml in directory
<LINK_DIR>/adapters/jms/samples/xml.
Testing Get: Request/Acknowledge
To configure the Operation Type Get (Request/Acknowledgment), enter the
following information in the operation instance configuration page in Data
Services Web Administrator.
EnterOption
JMSGetOperationOperation instance
1000Polling interval
Default Response Queue
Undelivered Queue
44Data Services JMS Adapter Interface
1Thread count
trueEnable
Queue.ActaQueueGetSource Queue
Queue.TestServiceService
2000Timeout
trueContinue After Error
Note:
When you specify a value, this operation changes from Request/Acknowledgement to Request/Reply.
Note:
When you specify a value, this operation changes from Request/Acknowledgement to Request/Reply.
After entering this information, click Apply and restart JMS Adapter instance.
When the JMS Adapter starts running, the operation instance also starts
running.
Testing on Windows NT
Run the sample application by running sampleTest_Send.bat file from the
command prompt.
This sample application (external IR) sends the message as a request on a
source queue configured for JMSGetOperation instance. JMSGetOperation
instance invokes the real-time batch job. This creates an output file
JMSSourceOutput_Get.xml as an acknowledgement at the location
<LINK_DIR>/adapters/JMS/samples/xml. No response is sent to the default
response queue since it is not configured for this type of operation.
Testing on UNIX
Using the JMS Adapter
Testing Put: Request/Acknowledge
3
Run the sample application by running sampleTest_Send.sh file from the
command prompt.
This sample application (external IR) sends the message as a request on a
source queue configured for JMSGetOperation instance. JMSGetOperation
instance invokes the real-time batch job. This creates an output file
JMSSourceOutput_Get.xml as an acknowledgement at the location
<LINK_DIR>/adapters/JMS/samples/xml. No response is sent to the default
response queue since it is not configured for this type of operation.
Testing Put: Request/Acknowledge
To configure the Operation Type Put (Request/Acknowledge), enter the
following information in the operation instance configuration page in Data
Services Web Administrator.
EnterOption
JMSPutOperationOperation instance
Data Services JMS Adapter Interface45
Using the JMS Adapter
3
Testing Put: Request/Acknowledge
Description
EnterOption
1Thread count
JMSPutOperationDisplay name
This operation instance represents the
Put Request/Acknowledge operation.
It queues the message to the configured destination queue.
trueEnable
Queue.MyQueueDestination Queue
Request Format
Click Apply after entering this information, then restart the adapter instance.
When the JMS Adapter is running, the operation instance is also running.
Testing on Windows NT
Open a command prompt window and change directory to
<LINK_DIR>\adapters\jms\samples. Run the sample application (external
IR) by running sampleTest_Put.bat. The application should display the
message:
Ready to receive message from queue Queue.MyQueue.
Execute the batch Job JMSPutOperation_BatchJob from Data Services
Designer.
The sample application (external IR) listens for a message to arrive at the
request queue of the JMSPutOperation instance. When it receives the
message, it will print a message to the command prompt window such as:
Received message:<?xml version="1.0" encoding="UTF-8"?>
<source><age>18</age><salary>200000000</salary><ac
no>2356376438743</acno></source>
After the adapter operation acknowledges sending the message to the IR,
the Data Services job then generates the output file
JMSSourceOutput_Put.xml under the directory
<LINK_DIR>/adapters/JMS/samples/xml. The contents of the file should be
similar to the message received by the sample test with the addition of a
timestamp. Note that this file is created as a result of the design of the Data
Services job, not as a result of the adapter operation sending a reply message
to the job.
Testing on UNIX
Run the sample application by running sampleTest_Put.sh file from the
command prompt. This sample application listens at the destination queue
configured for the Put operation instance.
Execute the batch Job JMSPutOperation_BatchJob from Data Services
Designer.
The sample application receives the message from the destination queue
and an output file JMSSourceOutput_Put.xml as an acknowledgment gets
created under the directory <LINK_DIR>/adapters/JMS/samples/xml.
Using the JMS Adapter
Technical implementation
3
Technical implementation
This section provides the design limitations of the adapter. It also provides
troubleshooting tips for running the adapter.
Design considerations
In the current design:
•JMS queues and topics used in the Operation instances must be
pre-configured in the Messaging System.
•Only XML messages are handled.
•GetTopic operations should be configured to specify a Thread Count of
1. Since each thread would be a subscriber to the topic, each thread
would receive the same message and send it to the service, resulting in
multiple copies of the same message going to the service.
Data Services JMS Adapter Interface47
Using the JMS Adapter
3
Technical implementation
Error handling and tracing
Error messages are logged in error log file under Data Services/adapters/log
directory before throwing any exception. The name of the error log file is
same as the name of the adapter configured in Data Services Administrator.
For tracing, the trace messages are logged in the trace file under Data
Services/adapters/log directory. The name of the trace file is same as the
name of the adapter configured in Data Services Administrator. You can
enable the trace option in Data Services Administrator for this adapter. Trace
message shows the execution flow of the adapter and contain useful
information on finding the cause of an error. The output in this trace file is of
great help for Data Services Support Team.
48Data Services JMS Adapter Interface
Appendix
4
Appendix
4
Weblogic as JMS Provider
Weblogic as JMS Provider
Before you run the Data Services JMS Adapter, you need to create a
JMSServer, Connection Factory and configure JMS queues.
•Create a JMS Server
•Start the BEA Weblogic server.
•Open the Weblogic console.
•Under services\JMS, click Servers.
•Click Create a new JMS Server button.
Create the instance of JMS server. Then, click Create.
Click the Target link on the screen and select the server from available block
to a chosen block. Click Apply to create the server instance.
To create a JMS Connection Factory
1. Start the BEA Weblogic server
2. Open the Weblogic console
3. Under services\JMS, click Connection Factories.
Configure the Connection Factory.
For testing purposes, "JMSConnections.AdapterConnectionFactory" must
be configured.
Click the Target link on the screen. Select the server from available block to
chosen block.
To configure the Connection Factory
For testing purposes, "JMSConnections.AdapterConnectionFactory" must
be configured.
1. Click the Target link on the screen.
2. Select the server from available block to chosen block.
3. Click Apply to create the connection factory.
50Data Services JMS Adapter Interface
Create a JMS queue
1. Start the BEA Weblogic server.
2. Open the Weblogic console
3. Under services\JMS\Servers\ConfigJMSServer\Destinations, click Create
a New JMSQueue.
For testing purposes, configure the following queues in the server: