Red Hat AMQ 6
As of February 2025, Red Hat is no longer supporting Red Hat AMQ 6. If you are using AMQ 6, please upgrade: Migrating to AMQ 7.Questo contenuto non è disponibile nella lingua selezionata.
Chapter 3. ActiveMQ Console Commands
activemq: then press Tab at the prompt to view the available commands.
3.1. activemq:browse, browse Copia collegamentoCollegamento copiato negli appunti!
Abstract
Synopsis Copia collegamentoCollegamento copiato negli appunti!
activemq:browse {
--amqurl brokerURL
} [
--msgsel
{
msgsel
...}
] [
--factory className
] [
--passwordFactory className
] [
--user username
] [
--password password
] [
--view
{
attr
...}
] [[
-Vheader
] | [
-Vcustom
] | [
-Vbody
]] [
--version
] [[
--help
] | [
-h
] | [
-?
]]
destName
Arguments Copia collegamentoCollegamento copiato negli appunti!
| Argument | Interpretation |
|---|---|
--amqurl brokerURL | Specifies the URL of the broker to which you are connecting. |
--msgsel msgsel1,msgsel2,... | Displays messages matched by the message selector. |
--factory className | Load className as the javax.jms.ConnectionFactory to use for creating connections. |
--passwordFactory className | Load className as the org.apache.activemq.console.command.PasswordFactory for retrieving the password from a keystore. |
--user username | Username to use for JMS connections. |
--password password | Password to use for JMS connections. |
-Vheader | Shows all the standard JMS message headers. |
-Vcustom | Shows all the custom fields added to each JMS message. |
-Vbody | Shows the body of the message. |
--view attr1,attr1,... | Selects the specific attribute of the message to view. |
--version | Displays the version information. |
-h, -?, --help | Displays the online help for this command. |
Message filters Copia collegamentoCollegamento copiato negli appunti!
--msgsel option take the form header=value. Table 3.2, “Message Headers for Filtering” lists the headers you can use to filter messages.
| Name | Type |
|---|---|
JMSCorrelationID | String |
JMSDeliveryMode | 1-Non-Persistent, 2-Persistent |
JMSDestination | javax.jms.Destination |
JMSExpiration | long |
JMSMessageID | String |
JMSPriority | int |
JMSRedelivered | boolean |
JMSReplyTo | javax.jms.Destination |
JMSTimestamp | long |
JMSType | String |
Examples Copia collegamentoCollegamento copiato negli appunti!
TEST.FOO on a broker:
JBossA-MQ:karaf@root>activemq:browse --amqurl tcp://localhost:61616 TEST.FOO
JBossA-MQ:karaf@root>activemq:browse --amqurl tcp://localhost:61616 TEST.FOO
TEST.FOO queue:
JBossA-MQ:karaf@root>activemq:browse --amqurl tcp://localhost:61616 -Vbody TEST.FOO
JBossA-MQ:karaf@root>activemq:browse --amqurl tcp://localhost:61616 -Vbody TEST.FOO
10:
JBossA-MQ:karaf@root>activemq:browse --amqurl tcp://localhost:61616 --msgsel JMSMessaageID='*:10' TEST.FOO
JBossA-MQ:karaf@root>activemq:browse --amqurl tcp://localhost:61616 --msgsel JMSMessaageID='*:10' TEST.FOO
3, enter:
JBossA-MQ:karaf@root>activemq:browse --amqurl tcp://localhost:61616 --msgsel JMSPriority=3 TEST.FOO
JBossA-MQ:karaf@root>activemq:browse --amqurl tcp://localhost:61616 --msgsel JMSPriority=3 TEST.FOO
JBossA-MQ:karaf@root>activemq:browse --amqurl tcp://localhost:61616 --msgsel JMSMessaageID='*:10',JMSPriority=3 TEST.FOO
JBossA-MQ:karaf@root>activemq:browse --amqurl tcp://localhost:61616 --msgsel JMSMessaageID='*:10',JMSPriority=3 TEST.FOO