Este contenido no está disponible en el idioma seleccionado.

activemq:browse


Name

activemq:browse, browse — displays messages on a specified destination

Synopsis

activemq:browse { --amqurl brokerURL } [ --msgsel { msgsel ...} ] [ --factory className ] [ --passwordFactory className ] [ --user username ] [ --password password ] [ --view { attr ...} ] [[ -Vheader ] | [ -Vcustom ] | [ -Vbody ]] [ --version ] [[ --help ] | [ -h ] | [ -? ]] destName

Arguments

Table 3.1, “activemq:browse Arguments” describes the command's arguments.
Table 3.1. activemq:browse Arguments
ArgumentInterpretation
--amqurl brokerURL Specifies the URL of the broker to which you are connecting.
--msgsel msgsel1,msgsel2,...Displays messages matched by the message selector.
--factory classNameLoad className as the javax.jms.ConnectionFactory to use for creating connections.
--passwordFactory classNameLoad className as the org.apache.activemq.console.command.PasswordFactory for retrieving the password from a keystore.
--user usernameUsername to use for JMS connections.
--password passwordPassword to use for JMS connections.
-Vheader Shows all the standard JMS message headers.
-VcustomShows all the custom fields added to each JMS message.
-VbodyShows the body of the message.
--view attr1,attr1,... Selects the specific attribute of the message to view.
--versionDisplays the version information.
-h, -?, --helpDisplays the online help for this command.

Message filters

Message filters specified using the --msgsel option take the form header=value. Table 3.2, “Message Headers for Filtering” lists the headers you can use to filter messages.
Table 3.2. Message Headers for Filtering
NameType
JMSCorrelationIDString
JMSDeliveryMode1-Non-Persistent, 2-Persistent
JMSDestinationjavax.jms.Destination
JMSExpirationlong
JMSMessageIDString
JMSPriorityint
JMSRedelivered boolean
JMSReplyTojavax.jms.Destination
JMSTimestamplong
JMSTypeString

Examples

The following command prints the JMS message header, custom message header, and message body of all the messages in the queue TEST.FOO on a broker:
JBossA-MQ:karaf@root>activemq:browse --amqurl tcp://localhost:61616 TEST.FOO
The following command displays the attributes from the body of the messages in the TEST.FOO queue:
JBossA-MQ:karaf@root>activemq:browse --amqurl tcp://localhost:61616 -Vbody TEST.FOO
The following command displays any messages with an ID ending in 10:
JBossA-MQ:karaf@root>activemq:browse --amqurl tcp://localhost:61616 --msgsel JMSMessaageID='*:10' TEST.FOO
The following command displays messages with a priority of 3, enter:
JBossA-MQ:karaf@root>activemq:browse --amqurl tcp://localhost:61616 --msgsel JMSPriority=3 TEST.FOO
The message selectors from the preceding two examples can be combined as follows:
JBossA-MQ:karaf@root>activemq:browse --amqurl tcp://localhost:61616 --msgsel JMSMessaageID='*:10',JMSPriority=3 TEST.FOO
Red Hat logoGithubRedditYoutubeTwitter

Aprender

Pruebe, compre y venda

Comunidades

Acerca de la documentación de Red Hat

Ayudamos a los usuarios de Red Hat a innovar y alcanzar sus objetivos con nuestros productos y servicios con contenido en el que pueden confiar.

Hacer que el código abierto sea más inclusivo

Red Hat se compromete a reemplazar el lenguaje problemático en nuestro código, documentación y propiedades web. Para más detalles, consulte el Blog de Red Hat.

Acerca de Red Hat

Ofrecemos soluciones reforzadas que facilitan a las empresas trabajar en plataformas y entornos, desde el centro de datos central hasta el perímetro de la red.

© 2024 Red Hat, Inc.