-
Notifications
You must be signed in to change notification settings - Fork 1
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
implement bindings and un-bindings #19
Conversation
Signed-off-by: Gabriele Santomaggio <[email protected]>
Signed-off-by: Gabriele Santomaggio <[email protected]>
Signed-off-by: Gabriele Santomaggio <[email protected]>
Signed-off-by: Gabriele Santomaggio <[email protected]>
Signed-off-by: Gabriele Santomaggio <[email protected]>
@lukebakken, the PR is ready to review ( if you can). I created a file for testing the bindings trying to cover all the cases with and without bindings arguments. |
…eting the latter and adding `Unbind` to `IBindingSpecification`
…indingSpecification`
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Check out my latest two commits 😸
Thanks @lukebakken var args = new Dictionary<string, object>() { { "k", "v" } };
await management.Binding().SourceExchange(source)
.DestinationQueue(destination)
.Key(key) /
.Arguments(args)
.Bind();
await management.Unbind().SourceExchange(source).DestinationQueue(destination).Key(key).Arguments(args)
.UnBind(); That is similar to java: management.exchange().name("e").type(DIRECT).declare();
management.binding().sourceExchange("e").destinationQueue("q").
key("k").arguments(s).bind();
management.unbind().sourceExchange("e")
.destinationQueue("q").key("k").arguments(s).unbind(); New version with your commit : var arguments = new Dictionary<string, object> { { key1, value1 }, { key2, value2 } };
await management.CreateBindingSpecification().SourceExchange("exchange_bindings_with_arguments")
.DestinationQueue("queue_bindings_with_arguments")
.Key("key")
.Arguments(arguments)
.Bind();
await management.CreateBindingSpecification().SourceExchange("exchange_bindings_with_arguments")
.DestinationQueue("queue_bindings_with_arguments")
.Key("key").Arguments(arguments).Unbind(); That is far from the Java AMQP client. I don't have a strong opinion on it; what matters is having the same API for Java and .NET. We have two ways: Let me know what you think @acogoluegnes |
I'll revert the naming change. I think it's unnecessary to duplicate an interface just for a different method. |
Signed-off-by: Gabriele Santomaggio <[email protected]>
Signed-off-by: Gabriele Santomaggio <[email protected]>
Signed-off-by: Gabriele Santomaggio <[email protected]>
Signed-off-by: Gabriele Santomaggio <[email protected]>
No description provided.