Copying a Message From One Endpoint to Another

In some situations, you may want to copy a single message from one queue or topic endpoint to another endpoint, or from the message replay log to an endpoint. For example, if the event broker moves a message to a dead message queue (DMQ) because an application is unable to consume the message, you can copy the message from the DMQ back to the original queue after any issues with the client application have been resolved.

This feature is not available from Mission Control or Broker Manager. It requires you to use the Solace Event Broker CLI. For more information, see Enabling the Solace Event Broker CLI for Event Broker Services.

To copy a message from one endpoint to another, enter the following Admin command:

solace(admin)# message-spool message-vpn <vpn-name>
solace(admin/message-spool)# copy-message {source {{queue <queue-name>} | {topic-endpoint <te-name>} | {replay-log <replay-log-name>}}} {destination {{queue <queue-name>} | {topic-endpoint <te-name>}}} {message <replication-group-msg-id>}

Where:

<queue-name> is the full name of the specified message queue.

<te-name> is the full name of the specified topic endpoint.

<replay-log-name> is the name of the message replay log.

<replication-group-msg-id> is the replication group message ID of the message you want to copy. A replication group message ID is an attribute of Solace messages, assigned by the event broker delivering the messages to the queue and topic endpoints, that uniquely identifies a message on a particular queue or topic endpoint within a high availability group or replication group of event brokers.

Example:

solace(admin)# message-spool message-vpn orange
solace(admin/message-spool)# copy-message source queue dmq1 destination queue q1 message rmid1:12eb1-a19b418311c-00000000-00000005