DevelopingDeveloper
DevelopingDeveloper

Reputation: 913

Camel Spring JMS Queue Connection Example

I have 3 JMS queue's I need to test on a server. I have the following properties for these queues:

  1. Hostname
  2. Port
  3. Channel
  4. Queue Manager
  5. Queue Names

I am looking for a way in which to test these queues through a java program. I would like to just have a simple main class to test these queues. One that I can modify the queue properties (particularly in a spring config file) and ensure I can message the queue and receive my message when I call to grab it.

I would just like to send the queue Hello World! and recevie back Hello World!

I assume this has been done time and time again, but I cannot find any resources that use properties for the queue other than the example below:

@Override
public void configure() throws Exception {
	from("activemq:queue:test.queue")
	.to("stream:out"); 
}

Upvotes: 0

Views: 710

Answers (1)

Matt Pavlovich
Matt Pavlovich

Reputation: 4306

It looks like you are trying to connect to an IBM MQ server. You simply need to configure a JMS component and configure an MQConnectionFactory using the values for those properties.

See this related article: Apache Camel: Is it possible to configure WMQ without using Spring?

Upvotes: 1

Related Questions