Open LGLO opened 8 years ago
1st problem - cannot have two overloaded functions with default parameter value.
So this change will break compilation.
What do you think about renaming one version of publish
?
In fact I'd like to have publish
which just wraps channel and takes messages with additional Exchange envelope.
@mkiedys could you comment, please?
I would rather see it being provided only once per connection: preferebly in settings. Worth noticing is that we already use one thread pool: amqp-client creates two threads that await on connections and execute handlers. This is what would work best IHMO: thread pool provided via settings that is used by amqp-client and everywhere else.
Reactive streams (JVM) specification mandates some part of code to be executed synchronously (but quickly) and some other asynchronously. I think it is good idea to allow to pass
ExecutionContext
in eachpublish
andconsume
method (as implicit with defaultExecutionContext.Implicits.global
).