iron_dotnet icon indicating copy to clipboard operation
iron_dotnet copied to clipboard

v3 queues return null queueInfo for queues that have not had a message posted to them.

Open ukiahsmith opened this issue 9 years ago • 1 comments

The way that queueInfo() works has changed from v2 to v3. We want v3 to work like v2. We want to be able to create a new queue, and get it's info, without posting a message on the queue.

screen shot 2015-11-27 at 3 24 41 pm-edited

ukiahsmith avatar Nov 27 '15 20:11 ukiahsmith

In the line QueueClient queue = ironMQ.Queue("my_queue"); a new QueueClient instance is initialized but it shouldn't create a new queue. We'll have a Create() method for this purpose (I've already added it, PR is ready and should be merged soon). Finally the script should look like this one:

IronMqRestClient ironMQ = IronSharp.IronMQ.Client.New(...);
QueueClient queue = ironMQ.Queue("my_queue");
queue.Create();
QueueInfo qi = queue.Info();

alex-litvak avatar Nov 30 '15 13:11 alex-litvak