|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
MQRC_DATA_LENGTH_ERROR |
« View previous topic :: View next topic » |
Author |
Message
|
adritownsend |
Posted: Mon May 16, 2011 12:35 am Post subject: |
|
|
Novice
Joined: 13 May 2011 Posts: 10
|
I have found this on another thread:
"When the MQSERVER environment variable is used to define a client channel a maximum message length (MAXMSGL) of 4 MB is used, so larger messages cannot flow across this channel. For larger messages a client-connection channel must be defined using DEFINE CHANNEL, on the server, with MAXMSGL set to a larger figure, or using an MQCONNX call with MaxMsgLength set in the MQCD referred to in the MQCNO structure."
Can anyone tell me how this DEFINE CHANNEL is used (google is my friend in the meantime...as you can see I'm still a newbie) |
|
Back to top |
|
 |
exerk |
Posted: Mon May 16, 2011 12:48 am Post subject: |
|
|
 Jedi Council
Joined: 02 Nov 2006 Posts: 6339
|
The 4MB limit to the MQSERVER variable was removed in WMQ V7.0 and is now 100MB. The default MAXMSGL for the channel you are trying to use may be the default 4MB however, and you should define a new SVRCONN channel with an appropriately larger MAXMSGL. How to do so is in the Info Centre - hint: search search on 'Define Channel'. _________________ It's puzzling, I don't think I've ever seen anything quite like this before...and it's hard to soar like an eagle when you're surrounded by turkeys. |
|
Back to top |
|
 |
adritownsend |
Posted: Mon May 16, 2011 1:12 am Post subject: |
|
|
Novice
Joined: 13 May 2011 Posts: 10
|
Usefull info thanks. And for the great hint, thanks, don't know what I would have done without you! |
|
Back to top |
|
 |
adritownsend |
Posted: Thu May 19, 2011 10:42 pm Post subject: |
|
|
Novice
Joined: 13 May 2011 Posts: 10
|
Along with all the advice of creating my own svrconn and clientconn this piece of code solved my problem:
import pymqi
import CMQC, CMQXC
queue_manager = "QM01"
channel = "SVRCONN.1"
host = "192.168.1.139"
port = "1434"
queue_name = "TEST.1"
message = "Hello from Python!" * 10000
conn_info = "%s(%s)" % (host, port)
cd = pymqi.CD()
cd.MaxMsgLength = 9595093
cd.ChannelName = channel
cd.ConnectionName = conn_info
cd.ChannelType = CMQC.MQCHT_CLNTCONN
cd.TransportType = CMQC.MQXPT_TCP
qmgr = pymqi.QueueManager(None)
qmgr.connect_with_options(queue_manager, cd=cd)
queue = pymqi.Queue(qmgr, queue_name)
queue.put(message)
queue.close()
qmgr.disconnect() |
|
Back to top |
|
 |
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|