Kbase 21426: SonicMQ: How To Record and Replicate Broker Configuration
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  10/15/2001 |
|
SUMMARY:
This Solution applies to SonicMQ Version 3.x. It describes a simple
way to record and replicate a given SonicMQ broker's configuration.
SOLUTION:
The SonicMQ BrokerManager API provides administrative client
functionality via Java code. This means that running code which uses
the BrokerManagerAPI, you can output the same information about your
broker's configuration as you can using the Admin tool.
The ShowSetup sample, in
<SonicMQ install dir>\samples\BrokerManager\ShowSetup, takes this one
step further, and outputs this information in a form that can be used
to replicate a broker's configuration. This information includes
queues, routing information, users, groups, and topic and queue ACLs
and QoP.
By running the ShowSetup sample and directing output to a file as per
the instructions in this sample's accompanying Readme.txt, you create
a text file which you can use as a script with the Admin tool to
replicate the configuration of the broker with which you first ran the
sample.
For example, run the sample, connecting to a broker running on the
same machine with the command:
..\..\SonicMQ ShowSetup -b localhost:2506 > setup_script.txt
The output, captured in setup_script.txt, assumes a default target
broker URL of tcp//:locahost:2506 in its first line:
connect broker localhost Administrator Administrator
You can edit this if necessary, substituting the URL of your target
broker for "localhost", and then use setup_script.txt with the Admin
tool to replicate the first broker's configuration on the target
broker with the command:
admin < setup_script.txt
References to Written Documentation:
SonicMQ Online API Reference on class BrokerManager
<SonicMQ install dir>\samples\BrokerManager\ShowSetup\Readme.txt
SonicMQ Installation & Administration Guide, "Running Admin with a Script"