summaryrefslogtreecommitdiff
path: root/doc/book/src/MessageStore-Tool.xml
blob: fdcb3cd560ff6a289dd9035172cacac76af28d5b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
<?xml version="1.0" encoding="utf-8"?>
<!--
 
 Licensed to the Apache Software Foundation (ASF) under one
 or more contributor license agreements.  See the NOTICE file
 distributed with this work for additional information
 regarding copyright ownership.  The ASF licenses this file
 to you under the Apache License, Version 2.0 (the
 "License"); you may not use this file except in compliance
 with the License.  You may obtain a copy of the License at
 
   http://www.apache.org/licenses/LICENSE-2.0
 
 Unless required by applicable law or agreed to in writing,
 software distributed under the License is distributed on an
 "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 KIND, either express or implied.  See the License for the
 specific language governing permissions and limitations
 under the License.
 
-->

<section><title>
      MessageStore Tool
    </title><section role="h2" id="MessageStoreTool-MessageStoreTool"><title>
            MessageStore Tool
          </title>

	 <para>
            We have a number of implementations of the Qpid MessageStore
            interface. This tool allows the interrogation of these stores
            while the broker is offline.
          </para>

	  <section role="h3" id="MessageStoreTool-MessageStoreImplementations"><title>
            MessageStore
            Implementations
          </title>

	 <itemizedlist>
            <listitem><para>
              <xref linkend="qpid_BDBMessageStore--3rd-Party-"/>
            </para></listitem>
            <listitem><para>
              <xref linkend="qpid_JDBCStore"/>
            </para></listitem>
            <listitem><para>
              <xref linkend="qpid_MemoryMessageStore"/>
            </para></listitem>
          </itemizedlist>
<!--h3--></section>

	  <section role="h3" id="MessageStoreTool-Introduction"><title>
            Introduction
          </title>

	 <para>
            Each of the MessageStore implementations provide different back
            end storage for their messages and so would need a different tool
            to be able to interrogate their contents at the back end.
          </para><para>
            What this tool does is to utilise the Java broker code base to
            access the contents of the storage providing the user with a
            consistent means to inspect the storage contents in broker
            memory. The tool allows the current messages in the store to be
            inspected and copied/moved between queues. The tool uses the
            message instance in memory for all its access paths, but changes
            made will be reflected in the physical store (if one exists).
          </para>
<!--h3--></section>

	  <section role="h3" id="MessageStoreTool-Usage"><title>
            Usage
          </title>

	 <para>
            The tools-distribution currently includes a unix shell command
            'msTool.sh' this script will launch the java tool.
          </para><para>
            The tool loads $QPID_HOME/etc/config.xml by default. If an
            alternative broker configuration is required this should be
            provided on the command line as would be done for the broker.
          </para>
            <programlisting>
msTool.sh -c &lt;path to different config.xml&gt;
</programlisting>
          <para>
            On startup the user is present with a command prompt
          </para>
            <programlisting>
$ msTool.sh
MessageStoreTool - for examining Persistent Qpid Broker MessageStore instances
bdb$ 
</programlisting>
<!--h3--></section>

          <section role="h3" id="MessageStoreTool-AvailableCommands"><title>
            Available
            Commands
          </title>

	 <para>
            The available commands in the tool can be seen through the use of
            the 'help' command.
          </para>
            <programlisting>
bdb$ help
+----------------------------------------------------------------+
|                       Available Commands                       |
+----------------------------------------------------------------+
| Command | Description                                          |
+----------------------------------------------------------------+
| quit    | Quit the tool.                                       |
| list    | list available items.                                |
| dump    | Dump selected message content. Default: show=content |
| load    | Loads specified broker configuration file.           |
| clear   | Clears any selection.                                |
| show    | Shows the messages headers.                          |
| select  | Perform a selection.                                 |
| help    | Provides detailed help on commands.                  |
+----------------------------------------------------------------+
bdb$
</programlisting>
          <para>
            A brief description is displayed and further usage information is
            shown with 'help &lt;command&gt;'
          </para>
            <programlisting>
bdb$ help list
list availble items.
Usage:list queues [&lt;exchange&gt;] | exchanges | bindings [&lt;exchange&gt;] | all
bdb$
</programlisting>
<!--h3--></section>


          <section role="h3" id="MessageStoreTool-FutureWork"><title>
            Future Work
          </title>

	 <para>
            Currently the tool only works whilst the broker is offline i.e.
            it is up, but not accepting AMQP connections. This requires a
            stop/start of the broker. If this functionality was incorporated
            into the broker then a telnet functionality could be provided
            allowing online management.
          </para>
<!--h3--></section>
<!--h2--></section>
</section>