I am relatively new to IBM MQ.
My requirement is to connect to a Remote IBM MQ Server Queue through IBM MQ Client. And then, access the queue through MQ Client using IBM MQ Java API.
Is this the right approach?
I have already setup IBM MQ Server, IBM MQ Explorer on my local machine, created a Queue Manager, Queue. I have also written a Java program to connect to MQ using IBM MQ API.
This Java program has the following parameters:
String queueManagerName = "QUEUE.MANAGER.1";
String userID = "";
String password = "";
String queueName = "QUEUE1";
String hostName = "localhost";
String channel = "CHANNEL1";
int port = 1414;
You will need to point connection parameters for your application to connect to queue manager on remote machine. For example:
String queueManagerName = "<Remote queue manager name>"; String userID = "<valid user existing on remote machine>"; String password = "<password for user>"; String hostName = "<remote host name>"; String channel = "<Channel name on remote queue manager>"; int port = <port number where queue manager is listening>;
But you will need to configure authentication and authorization on remote queue manager for application to connect. If that is not configured, then you will get MQRC 2035 - NOT_AUTHORIZED errors.