ws

[ci skip]
Make pseudo-synchronous code more resilient to race conditions with channel.close

In workloads that aggressively open and close channels (e.g. a WebSockets/RabbitMQ proxy)
delayed operations may end up being executed after a channel is closed. For example:

ch.queue("", :exclusive => true).bind(x).subscribe do |meta, payload|
  # ...
end

will delay queue.bind and basic.consume method delivery until after the server-generated
queue name is known. If the channel is closed in the middle of this sequence of operations,
it would cause a connection-level exception.

This commit delays all queue operations until the queue name is known in a unified
way and guards delayed operations to be discarded when by the time they are
executed the channel is already closed.

For normal workloads, there will be no change of behavior.

Conflicts:

	spec/integration/basic_get_spec.rb
Use RabbitMQ Tracer port if environment indicates so
Adapt this test to amq-protocol 1.2
Adapt to amq-client's support for authentication mechanisms
0.9.10
Now working on 0.9.11.pre