[ 
https://issues.apache.org/jira/browse/DISPATCH-1871?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17248558#comment-17248558
 ] 

Jiri Daněk edited comment on DISPATCH-1871 at 12/13/20, 12:15 PM:
------------------------------------------------------------------

[~chug] I think that you are answering a different question. I edited the 
summary according to my understanding, and I will try to answer that.

Apache ActiveMQ Artemis can speak AMQP, same as Qpid Dispatch does. That means 
you can keep using the {{artemis producer}} and {{artemis consumer}} commands 
with Dispatch. You only need to specify an option to make them use AMQP 
protocol:

{noformat}
% bin/artemis producer --url=amqp://127.0.0.1:5672 --protocol=amqp 
--message="Ahoy vole" --message-count=3 
Connection brokerURL = amqp://127.0.0.1:5672
2020-12-13 13:13:56,669 WARN  
[org.apache.qpid.jms.provider.amqp.builders.AmqpResourceBuilder] Open of 
resource:(JmsConnectionInfo { ID:35e57d3f-4915-44ff-9ce1-2b75b2bb6407:1, 
configuredURI = amqp://127.0.0.1:5672, connectedURI = null }) failed: Open 
failed unexpectedly.
2020-12-13 13:13:56,719 INFO  [org.apache.qpid.jms.JmsConnection] Connection 
ID:3534783a-7bce-4b05-9007-7319ee946d5a:2 connected to server: 
amqp://127.0.0.1:5672
Producer TEST, thread=0 Started to calculate elapsed time ...

Producer TEST, thread=0 Produced: 3 messages
Producer TEST, thread=0 Elapsed time in second : 0 s
Producer TEST, thread=0 Elapsed time in milli second : 67 milli seconds
{noformat}

{noformat}
% bin/artemis consumer --url=amqp://127.0.0.1:5672 --protocol=amqp 
--message-count=3 --verbose 
Executing org.apache.activemq.artemis.cli.commands.messages.Consumer consumer 
--url=amqp://127.0.0.1:5672 --protocol=amqp --message-count=3 --verbose 
Home::/home/jdanek/Downloads/AMQ7/apache-artemis-2.16.0, 
Instance::/home/jdanek/Downloads/AMQ7/apache-artemis-2.16.0/i0
Connection brokerURL = amqp://127.0.0.1:5672
Consumer:: filter = null
2020-12-13 13:13:53,263 WARN  
[org.apache.qpid.jms.provider.amqp.builders.AmqpResourceBuilder] Open of 
resource:(JmsConnectionInfo { ID:37b39df2-8eeb-411a-9a0d-6b08488035f8:1, 
configuredURI = amqp://127.0.0.1:5672, connectedURI = null }) failed: Open 
failed unexpectedly.
2020-12-13 13:13:53,305 INFO  [org.apache.qpid.jms.JmsConnection] Connection 
ID:0be6cd68-6466-4dfe-8716-b79884250de1:2 connected to server: 
amqp://127.0.0.1:5672
Consumer TEST, thread=0 wait until 3 messages are consumed
Consumer TEST, thread=0 Received Ahoy vole
Received text sized at 9
Consumer TEST, thread=0 Received Ahoy vole
Received text sized at 9
Consumer TEST, thread=0 Received Ahoy vole
Received text sized at 9
Consumer TEST, thread=0 Consumed: 3 messages
Consumer TEST, thread=0 Elapsed time in second : 3 s
Consumer TEST, thread=0 Elapsed time in milli second : 3479 milli seconds
Consumer TEST, thread=0 Consumed: 3 messages
Consumer TEST, thread=0 Consumer thread finished
{noformat}

In Dispatch docs 
([qpid-dispatch-1.14.0/user-guide/index.html#sending-test-messages-qdr|https://qpid.apache.org/releases/qpid-dispatch-1.14.0/user-guide/index.html#sending-test-messages-qdr]),
 we use simple_send.py and simple_recv.py. That is an alternative option.

If you want yet another alternative cli applications, you can use Justin's tool 
([github.com/ssorj/qtools|https://github.com/ssorj/qtools]), Kevin's tool 
([github.com/kevinboone/amqutil|https://github.com/kevinboone/amqutil]), or one 
of the rh-messaging/cli- tools 
([cli-java|https://github.com/rh-messaging/cli-java], 
[cli-netlite|https://github.com/rh-messaging/cli-netlite], 
[cli-rhea|https://github.com/rh-messaging/cli-rhea], 
[cli-proton-python|https://github.com/rh-messaging/cli-proton-python], 
[cli-proton-ruby|https://github.com/rh-messaging/cli-proton-ruby], 
[cli-cpp|https://github.com/rh-messaging/cli-cpp]).

If you want something that is already packaged in Linux distros, try the utils 
that come with Qpid Cpp:

{noformat}
$ yum install qpid-cpp-client-devel
$ /usr/bin/qpid-receive
{noformat}

[~raj888] can you tell if any of the answers actually answered your question?


was (Author: jdanek):
[~chug] I think that you are answering a different question. I edited the 
summary according to my understanding, and I will try to answer that.

Apache ActiveMQ Artemis can speak AMQP, same as Qpid Dispatch does. That means 
you can keep using the {{artemis producer}} and {{artemis consumer}} commands 
with Dispatch. You only need to specify an option to make them use AMQP 
protocol:

{noformat}
% bin/artemis producer --url=amqp://127.0.0.1:5672 --protocol=amqp 
--message="Ahoy vole" --message-count=3 
Connection brokerURL = amqp://127.0.0.1:5672
2020-12-13 13:13:56,669 WARN  
[org.apache.qpid.jms.provider.amqp.builders.AmqpResourceBuilder] Open of 
resource:(JmsConnectionInfo { ID:35e57d3f-4915-44ff-9ce1-2b75b2bb6407:1, 
configuredURI = amqp://127.0.0.1:5672, connectedURI = null }) failed: Open 
failed unexpectedly.
2020-12-13 13:13:56,719 INFO  [org.apache.qpid.jms.JmsConnection] Connection 
ID:3534783a-7bce-4b05-9007-7319ee946d5a:2 connected to server: 
amqp://127.0.0.1:5672
Producer TEST, thread=0 Started to calculate elapsed time ...

Producer TEST, thread=0 Produced: 3 messages
Producer TEST, thread=0 Elapsed time in second : 0 s
Producer TEST, thread=0 Elapsed time in milli second : 67 milli seconds
{noformat}

{noformat}
% bin/artemis consumer --url=amqp://127.0.0.1:5672 --protocol=amqp 
--message-count=3 --verbose 
Executing org.apache.activemq.artemis.cli.commands.messages.Consumer consumer 
--url=amqp://127.0.0.1:5672 --protocol=amqp --message-count=3 --verbose 
Home::/home/jdanek/Downloads/AMQ7/apache-artemis-2.16.0, 
Instance::/home/jdanek/Downloads/AMQ7/apache-artemis-2.16.0/i0
Connection brokerURL = amqp://127.0.0.1:5672
Consumer:: filter = null
2020-12-13 13:13:53,263 WARN  
[org.apache.qpid.jms.provider.amqp.builders.AmqpResourceBuilder] Open of 
resource:(JmsConnectionInfo { ID:37b39df2-8eeb-411a-9a0d-6b08488035f8:1, 
configuredURI = amqp://127.0.0.1:5672, connectedURI = null }) failed: Open 
failed unexpectedly.
2020-12-13 13:13:53,305 INFO  [org.apache.qpid.jms.JmsConnection] Connection 
ID:0be6cd68-6466-4dfe-8716-b79884250de1:2 connected to server: 
amqp://127.0.0.1:5672
Consumer TEST, thread=0 wait until 3 messages are consumed
Consumer TEST, thread=0 Received Ahoy vole
Received text sized at 9
Consumer TEST, thread=0 Received Ahoy vole
Received text sized at 9
Consumer TEST, thread=0 Received Ahoy vole
Received text sized at 9
Consumer TEST, thread=0 Consumed: 3 messages
Consumer TEST, thread=0 Elapsed time in second : 3 s
Consumer TEST, thread=0 Elapsed time in milli second : 3479 milli seconds
Consumer TEST, thread=0 Consumed: 3 messages
Consumer TEST, thread=0 Consumer thread finished
{noformat}

In Dispatch docs 
([qpid-dispatch-1.14.0/user-guide/index.html#sending-test-messages-qdr|https://qpid.apache.org/releases/qpid-dispatch-1.14.0/user-guide/index.html#sending-test-messages-qdr]),
 we use simple_send.py and simple_recv.py. That is an alternative option.

If you want yet another alternative cli applications, you can use Justin's tool 
([github.com/ssorj/qtools|https://github.com/ssorj/qtools]), Kevin's tool 
([github.com/kevinboone/amqutil|https://github.com/kevinboone/amqutil]), or one 
of the rh-messaging/cli- tools 
([cli-java|https://github.com/rh-messaging/cli-java], 
[cli-netlite|https://github.com/rh-messaging/cli-netlite], 
[cli-rhea|https://github.com/rh-messaging/cli-rhea], 
[cli-proton-python|https://github.com/rh-messaging/cli-proton-python], 
[cli-proton-ruby|https://github.com/rh-messaging/cli-proton-ruby]).

If you want something that is already packaged in Linux distros, try the utils 
that come with Qpid Cpp:

{noformat}
$ yum install qpid-cpp-client-devel
$ /usr/bin/qpid-receive
{noformat}

[~raj888] can you tell if any of the answers actually answered your question?

> Do we have CLI tools to send/receive messages from/to QDR network?
> ------------------------------------------------------------------
>
>                 Key: DISPATCH-1871
>                 URL: https://issues.apache.org/jira/browse/DISPATCH-1871
>             Project: Qpid Dispatch
>          Issue Type: Test
>         Environment: Test
>            Reporter: raj
>            Priority: Blocker
>
> Do we have any commands to send data from Qpid Dispatch server to AMQ. like 
> in Artemis we can use producer and consumer commands to send data that is 
> reached to queue or not like wise do we have any command to test it from qpid 
> to amq



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to