Posted: Mon Dec 29, 2014 5:37 am Post subject: creating temporary queues
Newbie
Joined: 29 Dec 2014 Posts: 3
Hi I am using activeMq dynamic queues in my broker application.
I want to switch to WMQ temporary queues and want to know if there is an analogy beetween the two.
Firstly I have got my bindings file as JNDI provider. In this file I set my connectionfactory to use model queue made to generate temporary queues with some prefix.
The prefix is ex. dynamicQueues/*.
Then I set in first application flow
destinationQueueName to
dynamicQueues/queue1 and
sourceQueueName in second flow to the same
dynamicQueues/queue1.
The problem is there is no dynamicQueues/queue1 in the bindings file.
I would like it to be created on the fly by connection factory from the bindings file when I will be requesting it using dynamicQueues prefix.
Is it possible or we have to create dynamic queues manually by using an api?
Can the jndi object be created when not present in bindings file but requested using only proper connectionfactory configuration?
You seem to be gravely mistaken as to the naming conventions.
A dynamic queue created off the model queue will always look something like this:
Code:
queue://qmgrname/prefixname.somenumber
So unless your queue manager name is (case sensitive) dynamicQueues your set up is totally wrong.
Also dynamic queues are being created by the program. I.E. if you are not passing the name of the queue from the creator to the user piece of code you have no way of knowing the queue name.
If the queue manager name if not filled in ("queue:///QNAME") the queue manager you are connected to is assumed, unless name resolution points to a cluster queue.
Ok thanks for clarification.
But I wonder if there is a way to force qm to create dynamicQueue without explicitly calling Session.CreateTemporaryQueue() ?
I mean to only have destinationQueueName set and if not present in JNDI let the qm create it for you using some template.
Ok thanks for clarification.
But I wonder if there is a way to force qm to create dynamicQueue without explicitly calling Session.CreateTemporaryQueue() ?
I mean to only have destinationQueueName set and if not present in JNDI let the qm create it for you using some template.
Your problem seems to be manyfold here.
Defining a destination that is not in JNDI => I already told you to use the URI form...
Defining / creating a destination that does not exist on the qmgr => This should really be an administrative task and there are programs / interfaces to do that.
To create such a queue dynamically you might need to have a qcf with a model queue that does create a permanent queue .... But again as I said this should be an administrative set up and the user program should not do anything with the setup of queues.
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