-
Notifications
You must be signed in to change notification settings - Fork 257
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ASB - allow creating of topics/subscriptions to be optional #1444
Comments
@penderi @iancooper I'll have a PR in for this in ~30 minutes |
@preardon Guessing you have seen the optional creation enum on the V9 publication and subscription? |
@iancooper I have not, I was just adding creation Booleans to AzureServiceBusConfiguration as I figured I would keep this confined to ASB Config. I can have a look to wire it up to the over arching config if you like |
@preardon So on Subscription https://github.com/BrighterCommand/Brighter/blob/master/src/Paramore.Brighter/Subscription.cs and Publication https://github.com/BrighterCommand/Brighter/blob/master/src/Paramore.Brighter/Publication.cs we have an enum OnMissingChannels that indicates what you want us to do:
We assume for create producer creates channel (topic, routing key) but client creates queues etc. That gets passed into your producer or consumer, and the code there has to do the work to determine what to do. When may vary. So with RMQ because it is a no-op if it exists and low-latency the Channel checks when it is called, but in AWS the ChannelFactory does it, not the Channel, because creation is high latency and we need to check if something exists before we create it. So you have to think about where as well. I'm guessing that ASB is a REST API for creation, so it might make sense to look at the ChannelFactory in the same way AWS does |
@iancooper don't worry @preardon is a mate at Flagstone, all good. |
Co-authored-by: Paul Reardon <[email protected]>
Let me know if you happy to close this now @iancooper |
@holytshirt Going to look shortly |
@holytshirt I just wanted to check on the following. Forwarding my comments from the PR: @preardon So the only thing that might be missing is that the consumer doesn't check for the topic and create it if asked to create. I don't know enough about the management wrapper to know if that will automatically check for the topic and create it, if it is missing, but it would probably need that if not. The consumer tends to check for everything - the producer only the topic. |
If it subscription doesn't check for/auto-create the topic, we'll need a PR to fix that before we can close this issue. |
@iancooper I will have a look and report back |
@iancooper Have confirmed, does not AutoCreate Topic, PR Incoming |
Check if Topic Exists before creation Subscription #1444
Was doing some testing and found that I missed plumbing a part, PR incoming |
@iancooper Hey Mate, was looking deeper into this tonight, the error that ends up getting thrown on Channel Failure due to not Topic / Subscription Not existing ends up being "Could not receive message. Note that should return an MT_NONE from an empty queue on timeout" (MessagePump Line 89), Just wanted to get your opinion on this as while the original Error with reason gets swallowed, it'll be logged but there is no hint of the exact reason in the Final exception |
Plumbed Channel Creation Mode into the Factories #1444
@iancooper I think we can close this |
Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
Cloud hosting typically leaves infra concerns (topuic/subscription creation) to be outside of the scope of a component or service. Moreover reduced-rights deployment means attempts to create will fail.
Add the ability to ASB transport to only create topics and subscriptions when specified. Default = allow (as current)
mentioned in #1438
The text was updated successfully, but these errors were encountered: