Permalink
Browse files

required patched for blather/dsl and mysql2/em_fiber and em-synchrony…

…/connection_pool to run together
  • Loading branch information...
1 parent 42d341a commit 3d28544dda63d16ac1804578d53894fa0115fab6 @jnak jnak committed Jul 4, 2011
Showing with 12 additions and 0 deletions.
  1. +12 −0 lib/em-synchrony/connection_pool.rb
@@ -25,6 +25,18 @@ def execute(async)
release(f) if not async
end
end
+
+ # Patch for Blather XMPP DSL
+ #
+ # #Query being a mehod registered in the global namespace of Blather,
+ # it needs to be defined explicitly (vs in #method_missing) to be
+ # correctly called
+
+ def query(*args, &blk)
+ execute(false) do |conn|
+ conn.send(:query, *args, &blk)
+ end
+ end
private

0 comments on commit 3d28544

Please sign in to comment.