Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Sep 15 11:04

    megakid on master

    Ensure we dont make more connec… Merge pull request #18 from meg… (compare)

  • Sep 15 11:04
    megakid closed #18
  • Sep 15 11:03
    megakid opened #18
  • Jun 19 09:06
    christopherread commented #39
  • Jun 19 09:05
    christopherread commented #39
  • Jun 19 09:05
    christopherread commented #39
  • Jun 18 15:43
    julealgon commented #39
  • Jun 18 14:33
    christopherread labeled #39
  • Jun 18 14:27

    christopherread on master

    Update README.md Fixed ident o… (compare)

  • Jun 18 14:25
    christopherread commented #39
  • Jun 18 14:24
    christopherread commented #39
  • Jun 18 14:23
    christopherread commented #39
  • Jun 18 13:33
    julealgon opened #39
  • May 24 15:33
    christopherread closed #8
  • May 24 15:33
    christopherread commented #8
  • May 21 07:36
    christopherread commented #8
  • May 21 05:56
    ankorus commented #8
  • May 21 05:53
    ankorus commented #8
  • Apr 14 18:51

    megakid on v5.0.0

    (compare)

  • Apr 14 18:51

    megakid on master

    v5 prep net461 and Obvs 5.x No warn on 4.6.1 restore of AMQ… and 4 more (compare)

ankorus
@ankorus
@christopherread Chris, can obvs rabbitmq queue be configured as non exclusive? Thx,
Christopher Read
@christopherread
@ankorus RabbitMQ uses exchanges and subscriber queues
the queues are unique to each subscription

@ankorus check out the MessageSource code here to better understand how Obvs subscriptions to RabbitMQ are implemented:

https://github.com/christopherread/Obvs.RabbitMQ/blob/master/Obvs.RabbitMQ/MessageSource.cs

Christopher Read
@christopherread

@westonsoftware Hi Andy, welcome!

In answer to your question, no that isn't possible. The reason being that Obvs.NetMQ doesn't implement this (I think I only implemented for Obvs.ActiveMQ).

Christopher Read
@christopherread

@westonsoftware the NetMQ transport does support queues it seems:
https://netmq.readthedocs.io/en/latest/queue/

So it would be a matter of porting + testing the code from Obvs.ActiveMQ to Obvs.NetMQ

ankorus
@ankorus
@christopherread How to resolve AMQP operation issue?
Christopher Read
@christopherread

@ankorus I suspect you have a concurrency issue: the caller of your DLL is making multiple calls to your DLL from within the same process that at times overlap

this causes more than one subscription on the RabbitMQ response subscription queue, thats only supposed to have one subscription, hence the error

the solution is to first ensure your code is only instantiating the Obvs ServiceBus so the response queue is only subscribed to once

Christopher Read
@christopherread
Obvs is designed to have a ServiceBus singleton that is instantiated once at start of process and disposes when process exits
ankorus
@ankorus
@christopherread This is regular single server - multiple clients case. We need multiple clients send requests of the same type and get responses of the same type. Server singleton is fine. Singleton for all clients is a stretch. If each client queue name will be different (there was my earlier question on this subject) would the issue be resolved? Or the issue is fundamental and all clients must seat on the same response queue by design?
ankorus
@ankorus
@christopherread I will convert client bus to singleton. Is there a way to find out that the bus it is closed or disposed and needs to recreated? IServiceBusClient does not expose methods for that. Another thought: after serviceBusClient.GetResponses is there a way to stop getting responses or each client will keep getting responses forever from the singleton bus?
Christopher Read
@christopherread
Singleton within a process
Multiple client processes is fine, one ServiceBus per process
ankorus
@ankorus
Even with one single DLL and service bus - singleton (meaning not re-creating) still getting AMQP operation was interrupted: AMQP close-reason, initiated by Peer, code=405, text="RESOURCE_LOCKED - cannot obtain exclusive access to locked queue.
Christopher Read
@christopherread
Check your RabbitMQ admin console to see if you can see the subscribers listed
ankorus
@ankorus
Using rabbitmq admin I can see exchange named like a bus, and 2 queues: for requests and commands. Don't see queue for responses. When I am invoking our functions using UI I can see the number of connections is constantly growing. We use blocking wait currently to get single reponse:
response = serviceBusClient.GetResponses(request)
.SkipWhile(res => res.RequestId != request.RequestId)
.Take(1)
.Single()
ankorus
@ankorus
Found the bug: our singleton was still recreating client bus. The fact that there is no queue for responses is due to not using subscribe.
Christopher Read
@christopherread
Great!
Christopher Read
@christopherread
@ankorus I should be able to make a change so that Rabbit subscriber queue names are always unique, so you don't get errors when you don't have a singleton bus.
@ankorus you don't need to check the requestId on the response, that's done under the covers, but you do need to complete using Take(1) or dispose of your response subscription
ankorus
@ankorus
Let's start with server side. Do we really need process id in the queue name? What is the use case? Multiple obvs servers, yet still the same rabbitmq server? How to find process id by remote client?
For callbacks, I guess, unique queue name is cool. Especially if non-obvs and non-even-c# clients may get it...
Yes, please, show, how to dispose GetResponses correctly. I don't think there are good examples...
Christopher Read
@christopherread
Take(1) will be fine, it will complete afterwards