i am very new to WebSphere MQ someone please tell me how to see header portion of message in WebSphere MQ (7.0.1.3)
/opt/mqm/samp/bin/amqsbcg on linux can browse the messages for you. It prints the message header as well as the content. But you have to be on the same server as MQ qmgr.
If you are on a mq client, /opt/mqm/samp/bin/amqsbcgc should do, but you need to use a svrconn channel to connect to the qmgr and browse the messages.
Related
I need to know how IBM Websphere MQ works.
As of my knowledge.
IBM Websphere MQ is an application that runs continuously
IBM Websphere MQ has a queue manager, queue name, port, host where it is runs, channel name.
We have a two different application in two different remote place.
Two applications and the IBM Websphere MQ applications are connected through network.
Using IBM Websphere MQ credentials the applications are able to send and receive messages between them via IBM Websphere MQ.
If I have anything wrong then please guide me.
My questions are:
If one application sends a message to the queue then where will the memory be consumed?
Where do we run the MQ listeners? On the applications environment or the Websphere environment (where we installed the IBM Websphere MQ)?
Do we need to run any programs in the application environments or are the IBM Websphere MQ credentials (queue manager, queue name, port, host where it is runs, channel name) enough to send and receive the messages?
If one application sends a message to the queue then where will the memory be consumed?
A Running Queue Manager requires memory in order to run and handle processing/storage of messages. As well as that every MQ Client application that connects to a Queue Manager requires memory to connect to and put/get messages. This is no different than any application that runs on any system.
Where do we run the MQ listeners?
Assuming you mean MQ Listeners. The MQ Listeners are run on the Queue Manager and specify the (TCP) port you want the Queue Manager to listen on.
Do we need to run any programs in the application environments or are the IBM Websphere MQ credentials (queue manager, queue name, port, host where it is runs, channel name) enough to send and receive the messages?
To run a Queue Manager on a machine, your machine must meet the System requirements stated in the System Requirements for WebSphere MQ page.
Here is the MQ v8 one
Likewise to run a MQ Client application that can connect into a Queue Manager, the application needs to have be ran on a machine that has the IBM MQ Client libraries installed on and meet the system requirements.
You also need to tell the application:
The location of the Queue Manager hostname/IP Address and port number.
The channel to connect into, which must exist on the Queue Manager
The Queue name to interact with, which must exist on the Queue Manager
Depending on your Queue Manager's configuration you need to ensure that your application is running with the correct user/supplying the correct user to ensure it is properly authorized to access the Queue Manager.
I am newbie to Websphere MQ and i have some basic understanding on the concept of MQ. I know that MQ client would create a message (with MQMD and application data) and then send to MQ manager. MQ client will get the correct response back from MQ Manager. Supposedly there are many messages on the MQ Queue Manager, how does MQ client able to retrieve the right messages? What determines the uniqueness of a MQ message?
There are different ways this can be approached - one common way is for the applications processing the messages to use the message ID and correlation ID fields. The message ID can be randomly generated and saved then copied to correlation ID field to be match when the reply is sent. Applications can do gets matching on those fields in the message header.
I suggest you read through the application programming guide and reference in the knowledge center.
How do I send multiple messages to Websphere MQ from HERMES JMS Application in one go?
I was successful in sending a single message, as soon as I process 2 or more messages to the Hermes application it fails.
If you are not stuck with HermesJMS you could give a try to JMSToolBox (on sourceforge) where you can manage "scripts" to post multiple messages to various destinations
I'm new in using Websphere MQ. I need help in this.
I have a websphere located in a server remotely and I have an application that retrieves and sends the information to the websphere. Is it possible to send my queue to a remote websphere server and at the same time retrieve it? It's something like this.
If yes, how should I configure this one in the websphere remote server? Thanks!
Sorry to say your question is confusing. You don't send/receive queue. You send/receive messages to queue or topic. Can you clarify?
Update:
You can have WebSphere MQ queue manager running on machine and client application on different machine. Application can send and receive messages to/from remote queue manager. This is called as the client mode connection to queue manager and most commonly used type of connection mode.
Please read the WebSphere MQ InfoCenter.
I have queue name, host name, port, channel, queue manager, Get and Put option details of IBM WebSphere MQ queue.
Is it possible to send a message to the queue with the above details? If anyone has an idea, please provide some hints.
If you have a proper install of WMQ then you will have the samples. These will be in the installation directory for your platform as described here. I would direct you to the SimpleRequestor.java code which hard-codes these values. You can alternatively get them from Java properties files, the command line or a JNDI call.
// Set the properties
cf.setStringProperty(WMQConstants.WMQ_HOST_NAME, "localhost");
cf.setIntProperty(WMQConstants.WMQ_PORT, 1414);
cf.setStringProperty(WMQConstants.WMQ_CHANNEL, "SYSTEM.DEF.SVRCONN");
cf.setIntProperty(WMQConstants.WMQ_CONNECTION_MODE, WMQConstants.WMQ_CM_CLIENT);
cf.setStringProperty(WMQConstants.WMQ_QUEUE_MANAGER, "QM1");
Other methods of making the connection are illustrated in the other samples. Look around the directory and one of the programs will have the connection method that you need.
If you do not have the samples, they are distributed with the MQ Client install. For v7 client, this is SupportPac MQC7. Other versions are distributed in their corresponding SuppportPac which you can find from the landing page. Be sure to refer to the Infocenter that corresponds to the version of WMQ client that you are using. Since v6 is end-of-life as of September 2012, hopefully you are already using v7.0 or v7.1 client and your QMgr will also be at one of these versions.
amqsput QueueName QueueManagerName Press Enter.
Enter your message followed by Enter/Return key.
Try the IBM supportpac RFHUtil for development and testing of WebSphere MQ and IBM Integration Bus (IIB) or WebSphere Message Broker (WMB) applications