Start your JMS server.
See the documentation for your JMS server.
Create two queues within your JMS server: qa_testmessage and qa_receive. You may need to restart your JMS server after creating the queues.
See the documentation for your JMS server.
Create a directory to hold the files you create for this tutorial. For example, c:\JMSTestMessage. Navigate to that directory.
Create a QAnywhere connector:
In Sybase Central, choose File > New Connector and following the prompts in the Connector wizard.
Start the MobiLink server for messaging:
From the Windows Start menu, choose Programs > SQL Anywhere 10 > MobiLink > MobiLink with Messaging Sample.
Alternatively, at a command prompt, navigate to samples-dir\QAnywhere\server and type the following command:
mlsrv10 -m -c "dsn=QAnywhere 10.0 Demo" -sl java(-cp "jarfiles") -vcrs -zu+
Start the QAnywhere Agent:
From the Start menu, choose Programs > SQL Anywhere 10 > QAnywhere > Agent for Client1 Sample.
Start the TestMessage sample:
From the Windows Start menu, choose Programs > SQL Anywhere 10 > QAnywhere > TestMessage for Client1 Sample.
At a command prompt, navigate to Samples\QAnywhere\connectors\JMS\TestMessage and type the following:
java -cp .;JMS-client-jar-files ianywhere.message.samples.TestMessage
where JMS-client-jar-files is a semicolon delimited list of jar files that are required to access the JMS server. See your JMS server documentation for details.
For Sybase EAServer, this command would be:
java -cp .;path\easclient.jar;path\easj2ee.jar ianywhere.message.samples.TestMessage
where path is the location of the jar files.
NoteOn Unix, use colons instead of semicolons. |
Move the JMS TestMessage window to the right side of your screen under the existing TestMessage for Client1 window.