reidmorrison / rubywmq

Ruby interface into WebSphere MQ
https://github.com/reidmorrison/rubywmq
Apache License 2.0
32 stars 24 forks source link

Open queue in browse and input mode simultaneously #8

Closed abrahamb closed 10 years ago

abrahamb commented 10 years ago

Is there any way to open a queue in both modes, browse and input? I need to browse all messages in the queue and process and delete one especific message, for example in java it's possible to do this:

int openOptions = MQC.MQOO_FAIL_IF_QUIESCING | MQC.MQOO_INPUT_SHARED | MQC.MQOO_BROWSE; outputQueue=mQMgr.accessQueue(remoteQueue, openInputOptions);

Thanks for your reply

reidmorrison commented 10 years ago

Yes, instead of supplying :mode when you open the queue, supply the open options you want use :options.

  :options => WMQ::MQOO_INPUT_SHARED | WMQ::MQOO_BROWSE | WMQ::MQOO_FAIL_IF_QUIESCING
abrahamb commented 10 years ago

NICE....... THANKS A LOT!!!

abrahamb commented 10 years ago

it was :open_options

Regards