Hi all,
I'm new with MQ Series and its functionalities.
I write a program that interface with MQ by a java client interface (package com.ibm.mq.*).
My little program runs with no problems when I use a local queue, but have problem (NullPointerException) when trying to use a remote queue.
Such remote queue is defined on the same QueueManager of the right running program.
Have I to specify a different code for remote queue???
Here is some code parts:
// - Inizializzare il Queue Manager e la coda di MQ
String qManager = "QMFX";
MQQueueManager m_qMgr = null;
MQQueue mq_queue = null;
MQMessage sendMsg = null;
try
{
java.util.Hashtable properties = new java.util.Hashtable();
properties.put(MQC.TRANSPORT_PROPERTY, MQC.TRANSPORT_MQSERIES_CLIENT);
properties.put(MQC.HOST_NAME_PROPERTY, "10.100.184.140"
properties.put(MQC.CHANNEL_PROPERTY, "JAVA.CHANNEL"
m_qMgr = new MQQueueManager(qManager, properties);
int openOptions = MQC.MQOO_INPUT_AS_Q_DEF | MQC.MQOO_OUTPUT ;
mq_queue = m_qMgr.accessQueue("UPLOAD", openOptions, "QMFX" , null, null);
}
catch (MQException ex)
{
System.out.println("An MQ error occurred : Completion code " + ex.completionCode + " Reason code " + ex.reasonCode);
out.print("Errore: istanziazione Queue Manager."
}
....
Could somebody tell me why?
Thank's in advance.
I'm new with MQ Series and its functionalities.
I write a program that interface with MQ by a java client interface (package com.ibm.mq.*).
My little program runs with no problems when I use a local queue, but have problem (NullPointerException) when trying to use a remote queue.
Such remote queue is defined on the same QueueManager of the right running program.
Have I to specify a different code for remote queue???
Here is some code parts:
// - Inizializzare il Queue Manager e la coda di MQ
String qManager = "QMFX";
MQQueueManager m_qMgr = null;
MQQueue mq_queue = null;
MQMessage sendMsg = null;
try
{
java.util.Hashtable properties = new java.util.Hashtable();
properties.put(MQC.TRANSPORT_PROPERTY, MQC.TRANSPORT_MQSERIES_CLIENT);
properties.put(MQC.HOST_NAME_PROPERTY, "10.100.184.140"
properties.put(MQC.CHANNEL_PROPERTY, "JAVA.CHANNEL"
m_qMgr = new MQQueueManager(qManager, properties);
int openOptions = MQC.MQOO_INPUT_AS_Q_DEF | MQC.MQOO_OUTPUT ;
mq_queue = m_qMgr.accessQueue("UPLOAD", openOptions, "QMFX" , null, null);
}
catch (MQException ex)
{
System.out.println("An MQ error occurred : Completion code " + ex.completionCode + " Reason code " + ex.reasonCode);
out.print("Errore: istanziazione Queue Manager."
}
....
Could somebody tell me why?
Thank's in advance.