sidekick-client 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/.document +5 -0
- data/.gitignore +21 -0
- data/LICENSE +20 -0
- data/README.rdoc +17 -0
- data/Rakefile +52 -0
- data/VERSION +1 -0
- data/lib/ext/README +1 -0
- data/lib/ext/bunny-0.6.0/LICENSE +20 -0
- data/lib/ext/bunny-0.6.0/README.rdoc +66 -0
- data/lib/ext/bunny-0.6.0/Rakefile +24 -0
- data/lib/ext/bunny-0.6.0/bunny.gemspec +65 -0
- data/lib/ext/bunny-0.6.0/examples/simple_08.rb +30 -0
- data/lib/ext/bunny-0.6.0/examples/simple_09.rb +30 -0
- data/lib/ext/bunny-0.6.0/examples/simple_ack_08.rb +33 -0
- data/lib/ext/bunny-0.6.0/examples/simple_ack_09.rb +33 -0
- data/lib/ext/bunny-0.6.0/examples/simple_consumer_08.rb +53 -0
- data/lib/ext/bunny-0.6.0/examples/simple_consumer_09.rb +53 -0
- data/lib/ext/bunny-0.6.0/examples/simple_fanout_08.rb +39 -0
- data/lib/ext/bunny-0.6.0/examples/simple_fanout_09.rb +39 -0
- data/lib/ext/bunny-0.6.0/examples/simple_headers_08.rb +40 -0
- data/lib/ext/bunny-0.6.0/examples/simple_headers_09.rb +40 -0
- data/lib/ext/bunny-0.6.0/examples/simple_publisher_08.rb +27 -0
- data/lib/ext/bunny-0.6.0/examples/simple_publisher_09.rb +27 -0
- data/lib/ext/bunny-0.6.0/examples/simple_topic_08.rb +59 -0
- data/lib/ext/bunny-0.6.0/examples/simple_topic_09.rb +59 -0
- data/lib/ext/bunny-0.6.0/lib/bunny/channel08.rb +39 -0
- data/lib/ext/bunny-0.6.0/lib/bunny/channel09.rb +39 -0
- data/lib/ext/bunny-0.6.0/lib/bunny/client08.rb +494 -0
- data/lib/ext/bunny-0.6.0/lib/bunny/client09.rb +460 -0
- data/lib/ext/bunny-0.6.0/lib/bunny/exchange08.rb +175 -0
- data/lib/ext/bunny-0.6.0/lib/bunny/exchange09.rb +177 -0
- data/lib/ext/bunny-0.6.0/lib/bunny/queue08.rb +389 -0
- data/lib/ext/bunny-0.6.0/lib/bunny/queue09.rb +395 -0
- data/lib/ext/bunny-0.6.0/lib/bunny/subscription08.rb +85 -0
- data/lib/ext/bunny-0.6.0/lib/bunny/subscription09.rb +85 -0
- data/lib/ext/bunny-0.6.0/lib/bunny.rb +87 -0
- data/lib/ext/bunny-0.6.0/lib/qrack/channel.rb +18 -0
- data/lib/ext/bunny-0.6.0/lib/qrack/client.rb +204 -0
- data/lib/ext/bunny-0.6.0/lib/qrack/protocol/protocol08.rb +132 -0
- data/lib/ext/bunny-0.6.0/lib/qrack/protocol/protocol09.rb +133 -0
- data/lib/ext/bunny-0.6.0/lib/qrack/protocol/spec08.rb +823 -0
- data/lib/ext/bunny-0.6.0/lib/qrack/protocol/spec09.rb +521 -0
- data/lib/ext/bunny-0.6.0/lib/qrack/qrack08.rb +23 -0
- data/lib/ext/bunny-0.6.0/lib/qrack/qrack09.rb +23 -0
- data/lib/ext/bunny-0.6.0/lib/qrack/queue.rb +53 -0
- data/lib/ext/bunny-0.6.0/lib/qrack/subscription.rb +102 -0
- data/lib/ext/bunny-0.6.0/lib/qrack/transport/buffer08.rb +276 -0
- data/lib/ext/bunny-0.6.0/lib/qrack/transport/buffer09.rb +276 -0
- data/lib/ext/bunny-0.6.0/lib/qrack/transport/frame08.rb +112 -0
- data/lib/ext/bunny-0.6.0/lib/qrack/transport/frame09.rb +94 -0
- data/lib/ext/bunny-0.6.0/spec/spec_08/bunny_spec.rb +65 -0
- data/lib/ext/bunny-0.6.0/spec/spec_08/connection_spec.rb +12 -0
- data/lib/ext/bunny-0.6.0/spec/spec_08/exchange_spec.rb +162 -0
- data/lib/ext/bunny-0.6.0/spec/spec_08/queue_spec.rb +206 -0
- data/lib/ext/bunny-0.6.0/spec/spec_09/bunny_spec.rb +65 -0
- data/lib/ext/bunny-0.6.0/spec/spec_09/connection_spec.rb +12 -0
- data/lib/ext/bunny-0.6.0/spec/spec_09/exchange_spec.rb +162 -0
- data/lib/ext/bunny-0.6.0/spec/spec_09/queue_spec.rb +205 -0
- data/lib/ext/eventmachine-0.12.10/.gitignore +14 -0
- data/lib/ext/eventmachine-0.12.10/README +82 -0
- data/lib/ext/eventmachine-0.12.10/Rakefile +374 -0
- data/lib/ext/eventmachine-0.12.10/docs/COPYING +60 -0
- data/lib/ext/eventmachine-0.12.10/docs/ChangeLog +211 -0
- data/lib/ext/eventmachine-0.12.10/docs/DEFERRABLES +133 -0
- data/lib/ext/eventmachine-0.12.10/docs/EPOLL +141 -0
- data/lib/ext/eventmachine-0.12.10/docs/GNU +281 -0
- data/lib/ext/eventmachine-0.12.10/docs/INSTALL +13 -0
- data/lib/ext/eventmachine-0.12.10/docs/KEYBOARD +38 -0
- data/lib/ext/eventmachine-0.12.10/docs/LEGAL +25 -0
- data/lib/ext/eventmachine-0.12.10/docs/LIGHTWEIGHT_CONCURRENCY +70 -0
- data/lib/ext/eventmachine-0.12.10/docs/PURE_RUBY +75 -0
- data/lib/ext/eventmachine-0.12.10/docs/RELEASE_NOTES +94 -0
- data/lib/ext/eventmachine-0.12.10/docs/SMTP +2 -0
- data/lib/ext/eventmachine-0.12.10/docs/SPAWNED_PROCESSES +89 -0
- data/lib/ext/eventmachine-0.12.10/docs/TODO +8 -0
- data/lib/ext/eventmachine-0.12.10/eventmachine.gemspec +40 -0
- data/lib/ext/eventmachine-0.12.10/examples/ex_channel.rb +43 -0
- data/lib/ext/eventmachine-0.12.10/examples/ex_queue.rb +2 -0
- data/lib/ext/eventmachine-0.12.10/examples/helper.rb +2 -0
- data/lib/ext/eventmachine-0.12.10/ext/binder.cpp +125 -0
- data/lib/ext/eventmachine-0.12.10/ext/binder.h +46 -0
- data/lib/ext/eventmachine-0.12.10/ext/cmain.cpp +827 -0
- data/lib/ext/eventmachine-0.12.10/ext/cplusplus.cpp +202 -0
- data/lib/ext/eventmachine-0.12.10/ext/ed.cpp +1893 -0
- data/lib/ext/eventmachine-0.12.10/ext/ed.h +424 -0
- data/lib/ext/eventmachine-0.12.10/ext/em.cpp +2282 -0
- data/lib/ext/eventmachine-0.12.10/ext/em.h +232 -0
- data/lib/ext/eventmachine-0.12.10/ext/emwin.cpp +300 -0
- data/lib/ext/eventmachine-0.12.10/ext/emwin.h +94 -0
- data/lib/ext/eventmachine-0.12.10/ext/epoll.cpp +26 -0
- data/lib/ext/eventmachine-0.12.10/ext/epoll.h +25 -0
- data/lib/ext/eventmachine-0.12.10/ext/eventmachine.h +122 -0
- data/lib/ext/eventmachine-0.12.10/ext/eventmachine_cpp.h +96 -0
- data/lib/ext/eventmachine-0.12.10/ext/extconf.rb +148 -0
- data/lib/ext/eventmachine-0.12.10/ext/fastfilereader/extconf.rb +83 -0
- data/lib/ext/eventmachine-0.12.10/ext/fastfilereader/mapper.cpp +214 -0
- data/lib/ext/eventmachine-0.12.10/ext/fastfilereader/mapper.h +59 -0
- data/lib/ext/eventmachine-0.12.10/ext/fastfilereader/rubymain.cpp +127 -0
- data/lib/ext/eventmachine-0.12.10/ext/files.cpp +94 -0
- data/lib/ext/eventmachine-0.12.10/ext/files.h +65 -0
- data/lib/ext/eventmachine-0.12.10/ext/kb.cpp +81 -0
- data/lib/ext/eventmachine-0.12.10/ext/page.cpp +107 -0
- data/lib/ext/eventmachine-0.12.10/ext/page.h +51 -0
- data/lib/ext/eventmachine-0.12.10/ext/pipe.cpp +349 -0
- data/lib/ext/eventmachine-0.12.10/ext/project.h +151 -0
- data/lib/ext/eventmachine-0.12.10/ext/rubymain.cpp +1166 -0
- data/lib/ext/eventmachine-0.12.10/ext/sigs.cpp +89 -0
- data/lib/ext/eventmachine-0.12.10/ext/sigs.h +32 -0
- data/lib/ext/eventmachine-0.12.10/ext/ssl.cpp +460 -0
- data/lib/ext/eventmachine-0.12.10/ext/ssl.h +94 -0
- data/lib/ext/eventmachine-0.12.10/java/.classpath +8 -0
- data/lib/ext/eventmachine-0.12.10/java/.project +17 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/EmReactor.java +570 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/EmReactorException.java +40 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/EventableChannel.java +69 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/EventableDatagramChannel.java +189 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/EventableSocketChannel.java +364 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/application/Application.java +194 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/application/Connection.java +74 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/application/ConnectionFactory.java +37 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/application/DefaultConnectionFactory.java +46 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/application/PeriodicTimer.java +38 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/application/Timer.java +54 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/tests/ApplicationTest.java +109 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/tests/ConnectTest.java +148 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/tests/EMTest.java +80 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/tests/TestDatagrams.java +53 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/tests/TestServers.java +75 -0
- data/lib/ext/eventmachine-0.12.10/java/src/com/rubyeventmachine/tests/TestTimers.java +90 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/buftok.rb +138 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/callback.rb +26 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/channel.rb +57 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/connection.rb +564 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/deferrable.rb +192 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/file_watch.rb +54 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/future.rb +61 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/messages.rb +66 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/process_watch.rb +44 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/processes.rb +119 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/protocols/header_and_content.rb +138 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/protocols/httpclient.rb +263 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/protocols/httpclient2.rb +590 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/protocols/line_and_text.rb +125 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/protocols/linetext2.rb +161 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/protocols/memcache.rb +323 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/protocols/object_protocol.rb +45 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/protocols/postgres3.rb +247 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/protocols/saslauth.rb +175 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/protocols/smtpclient.rb +357 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/protocols/smtpserver.rb +547 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/protocols/socks4.rb +66 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/protocols/stomp.rb +200 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/protocols/tcptest.rb +53 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/protocols.rb +36 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/queue.rb +61 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/spawnable.rb +85 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/streamer.rb +130 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/timers.rb +56 -0
- data/lib/ext/eventmachine-0.12.10/lib/em/version.rb +3 -0
- data/lib/ext/eventmachine-0.12.10/lib/eventmachine.rb +1592 -0
- data/lib/ext/eventmachine-0.12.10/lib/evma/callback.rb +32 -0
- data/lib/ext/eventmachine-0.12.10/lib/evma/container.rb +75 -0
- data/lib/ext/eventmachine-0.12.10/lib/evma/factory.rb +77 -0
- data/lib/ext/eventmachine-0.12.10/lib/evma/protocol.rb +87 -0
- data/lib/ext/eventmachine-0.12.10/lib/evma/reactor.rb +48 -0
- data/lib/ext/eventmachine-0.12.10/lib/evma.rb +32 -0
- data/lib/ext/eventmachine-0.12.10/lib/jeventmachine.rb +257 -0
- data/lib/ext/eventmachine-0.12.10/lib/pr_eventmachine.rb +1022 -0
- data/lib/ext/eventmachine-0.12.10/setup.rb +1585 -0
- data/lib/ext/eventmachine-0.12.10/tasks/cpp.rake_example +77 -0
- data/lib/ext/eventmachine-0.12.10/tests/client.crt +31 -0
- data/lib/ext/eventmachine-0.12.10/tests/client.key +51 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_attach.rb +126 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_basic.rb +284 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_channel.rb +63 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_connection_count.rb +35 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_defer.rb +47 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_epoll.rb +160 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_error_handler.rb +35 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_errors.rb +82 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_exc.rb +55 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_file_watch.rb +49 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_futures.rb +198 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_get_sock_opt.rb +30 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_handler_check.rb +37 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_hc.rb +218 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_httpclient.rb +218 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_httpclient2.rb +153 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_inactivity_timeout.rb +50 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_kb.rb +60 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_ltp.rb +182 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_ltp2.rb +317 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_next_tick.rb +133 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_object_protocol.rb +37 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_pause.rb +70 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_pending_connect_timeout.rb +48 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_process_watch.rb +48 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_processes.rb +128 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_proxy_connection.rb +92 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_pure.rb +125 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_queue.rb +44 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_running.rb +42 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_sasl.rb +72 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_send_file.rb +242 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_servers.rb +76 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_smtpclient.rb +83 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_smtpserver.rb +85 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_spawn.rb +322 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_ssl_args.rb +79 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_ssl_methods.rb +50 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_ssl_verify.rb +82 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_timers.rb +162 -0
- data/lib/ext/eventmachine-0.12.10/tests/test_ud.rb +36 -0
- data/lib/ext/eventmachine-0.12.10/tests/testem.rb +31 -0
- data/lib/ext/eventmachine-0.12.10/web/whatis +7 -0
- data/lib/ext/misc/README +1 -0
- data/lib/ext/misc/indifferent_access.rb +131 -0
- data/lib/ext/uuidtools-2.1.1/CHANGELOG +56 -0
- data/lib/ext/uuidtools-2.1.1/LICENSE +20 -0
- data/lib/ext/uuidtools-2.1.1/README +13 -0
- data/lib/ext/uuidtools-2.1.1/Rakefile +48 -0
- data/lib/ext/uuidtools-2.1.1/lib/compat/securerandom.rb +202 -0
- data/lib/ext/uuidtools-2.1.1/lib/uuidtools/version.rb +35 -0
- data/lib/ext/uuidtools-2.1.1/lib/uuidtools.rb +618 -0
- data/lib/ext/uuidtools-2.1.1/spec/spec.opts +1 -0
- data/lib/ext/uuidtools-2.1.1/spec/spec_helper.rb +7 -0
- data/lib/ext/uuidtools-2.1.1/spec/uuidtools/mac_address_spec.rb +15 -0
- data/lib/ext/uuidtools-2.1.1/spec/uuidtools/utility_spec.rb +21 -0
- data/lib/ext/uuidtools-2.1.1/spec/uuidtools/uuid_creation_spec.rb +121 -0
- data/lib/ext/uuidtools-2.1.1/spec/uuidtools/uuid_parsing_spec.rb +127 -0
- data/lib/ext/uuidtools-2.1.1/tasks/benchmark.rake +38 -0
- data/lib/ext/uuidtools-2.1.1/tasks/clobber.rake +2 -0
- data/lib/ext/uuidtools-2.1.1/tasks/gem.rake +68 -0
- data/lib/ext/uuidtools-2.1.1/tasks/git.rake +40 -0
- data/lib/ext/uuidtools-2.1.1/tasks/metrics.rake +22 -0
- data/lib/ext/uuidtools-2.1.1/tasks/rdoc.rake +29 -0
- data/lib/ext/uuidtools-2.1.1/tasks/rubyforge.rake +89 -0
- data/lib/ext/uuidtools-2.1.1/tasks/spec.rake +64 -0
- data/lib/ext/uuidtools-2.1.1/website/index.html +95 -0
- data/lib/sidekick/client/sidekick_client.rb +46 -0
- data/lib/sidekick/shared/sidekick_logger.rb +14 -0
- data/lib/sidekick/shared/sidekick_queue_publisher.rb +91 -0
- data/lib/sidekick-client.rb +7 -0
- data/sidekick-client.gemspec +289 -0
- data/test/helper.rb +10 -0
- data/test/test_sidekick-client.rb +7 -0
- metadata +311 -0
data/.document
ADDED
data/.gitignore
ADDED
data/LICENSE
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
Copyright (c) 2009 CohesiveFT
|
|
2
|
+
|
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
|
4
|
+
a copy of this software and associated documentation files (the
|
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
|
9
|
+
the following conditions:
|
|
10
|
+
|
|
11
|
+
The above copyright notice and this permission notice shall be
|
|
12
|
+
included in all copies or substantial portions of the Software.
|
|
13
|
+
|
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
|
18
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
|
19
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.rdoc
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
= sidekick-client
|
|
2
|
+
|
|
3
|
+
Description goes here.
|
|
4
|
+
|
|
5
|
+
== Note on Patches/Pull Requests
|
|
6
|
+
|
|
7
|
+
* Fork the project.
|
|
8
|
+
* Make your feature addition or bug fix.
|
|
9
|
+
* Add tests for it. This is important so I don't break it in a
|
|
10
|
+
future version unintentionally.
|
|
11
|
+
* Commit, do not mess with rakefile, version, or history.
|
|
12
|
+
(if you want to have your own version, that is fine but bump version in a commit by itself I can ignore when I pull)
|
|
13
|
+
* Send me a pull request. Bonus points for topic branches.
|
|
14
|
+
|
|
15
|
+
== Copyright
|
|
16
|
+
|
|
17
|
+
Copyright (c) 2010 CohesiveFT. See LICENSE for details.
|
data/Rakefile
ADDED
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
require 'rubygems'
|
|
2
|
+
require 'rake'
|
|
3
|
+
|
|
4
|
+
begin
|
|
5
|
+
require 'jeweler'
|
|
6
|
+
Jeweler::Tasks.new do |gem|
|
|
7
|
+
gem.name = "sidekick-client"
|
|
8
|
+
gem.summary = %Q{RabbitMQ client specific to ESOD's Sidekick server}
|
|
9
|
+
gem.email = "yan@pritzker.ws"
|
|
10
|
+
gem.homepage = "http://github.com/cohesive/sidekick-client"
|
|
11
|
+
gem.authors = ["yan"]
|
|
12
|
+
gem.add_development_dependency "shoulda"
|
|
13
|
+
# gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
|
|
14
|
+
end
|
|
15
|
+
Jeweler::GemcutterTasks.new
|
|
16
|
+
rescue LoadError
|
|
17
|
+
puts "Jeweler (or a dependency) not available. Install it with: gem install jeweler"
|
|
18
|
+
end
|
|
19
|
+
|
|
20
|
+
require 'rake/testtask'
|
|
21
|
+
Rake::TestTask.new(:test) do |test|
|
|
22
|
+
test.libs << 'lib' << 'test'
|
|
23
|
+
test.pattern = 'test/**/test_*.rb'
|
|
24
|
+
test.verbose = true
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
begin
|
|
28
|
+
require 'rcov/rcovtask'
|
|
29
|
+
Rcov::RcovTask.new do |test|
|
|
30
|
+
test.libs << 'test'
|
|
31
|
+
test.pattern = 'test/**/test_*.rb'
|
|
32
|
+
test.verbose = true
|
|
33
|
+
end
|
|
34
|
+
rescue LoadError
|
|
35
|
+
task :rcov do
|
|
36
|
+
abort "RCov is not available. In order to run rcov, you must: sudo gem install spicycode-rcov"
|
|
37
|
+
end
|
|
38
|
+
end
|
|
39
|
+
|
|
40
|
+
task :test => :check_dependencies
|
|
41
|
+
|
|
42
|
+
task :default => :test
|
|
43
|
+
|
|
44
|
+
require 'rake/rdoctask'
|
|
45
|
+
Rake::RDocTask.new do |rdoc|
|
|
46
|
+
version = File.exist?('VERSION') ? File.read('VERSION') : ""
|
|
47
|
+
|
|
48
|
+
rdoc.rdoc_dir = 'rdoc'
|
|
49
|
+
rdoc.title = "sidekick-client #{version}"
|
|
50
|
+
rdoc.rdoc_files.include('README*')
|
|
51
|
+
rdoc.rdoc_files.include('lib/**/*.rb')
|
|
52
|
+
end
|
data/VERSION
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
0.1.0
|
data/lib/ext/README
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
External dependencies. These gems are put here using "gem unpack [gemname]"
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
Copyright (c) 2009 Chris Duncan
|
|
2
|
+
|
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
|
4
|
+
a copy of this software and associated documentation files (the
|
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
|
9
|
+
the following conditions:
|
|
10
|
+
|
|
11
|
+
The above copyright notice and this permission notice shall be
|
|
12
|
+
included in all copies or substantial portions of the Software.
|
|
13
|
+
|
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
|
18
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
|
19
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
= Bunny: A synchronous Ruby AMQP client
|
|
2
|
+
|
|
3
|
+
*GitHub* *repo*: http://github.com/celldee/bunny
|
|
4
|
+
|
|
5
|
+
*Rubyforge*: http://rubyforge.org/projects/bunny-amqp
|
|
6
|
+
|
|
7
|
+
*Twitter*: http://twitter.com/bunny_amqp
|
|
8
|
+
|
|
9
|
+
*Google* *Group*: http://groups.google.com/group/bunny-amqp
|
|
10
|
+
|
|
11
|
+
*Blog*: http://bunnyamqp.wordpress.com
|
|
12
|
+
|
|
13
|
+
=== DESCRIPTION:
|
|
14
|
+
|
|
15
|
+
Bunny is an AMQP[http://www.amqp.org] (Advanced Message Queuing Protocol) client, written in Ruby, that is intended to allow you to interact with AMQP-compliant message brokers/servers such as RabbitMQ[http://www.rabbitmq.com] in a synchronous fashion.
|
|
16
|
+
|
|
17
|
+
It is based on a great deal of useful code from amqp[http://github.com/tmm1/amqp] by Aman Gupta and Carrot[http://github.com/famoseagle/carrot] by Amos Elliston.
|
|
18
|
+
|
|
19
|
+
You can use Bunny to -
|
|
20
|
+
|
|
21
|
+
* Create and delete exchanges
|
|
22
|
+
* Create and delete queues
|
|
23
|
+
* Publish and consume messages
|
|
24
|
+
|
|
25
|
+
Bunny is known to work with RabbitMQ versions 1.5.4, 1.5.5, 1.6.0 and version 0-8 of the AMQP specification.
|
|
26
|
+
|
|
27
|
+
=== INSTALL:
|
|
28
|
+
|
|
29
|
+
*Rubyforge*: <tt>gem install bunny</tt>
|
|
30
|
+
|
|
31
|
+
*Gemcutter*: <tt>gem install bunny</tt>
|
|
32
|
+
|
|
33
|
+
*GitHub*: Current gem is not available.
|
|
34
|
+
|
|
35
|
+
=== QUICK START:
|
|
36
|
+
|
|
37
|
+
require 'bunny'
|
|
38
|
+
|
|
39
|
+
b = Bunny.new(:logging => true)
|
|
40
|
+
|
|
41
|
+
# start a communication session with the amqp server
|
|
42
|
+
b.start
|
|
43
|
+
|
|
44
|
+
# declare a queue
|
|
45
|
+
q = b.queue('test1')
|
|
46
|
+
|
|
47
|
+
# publish a message to the queue
|
|
48
|
+
q.publish('Hello everybody!')
|
|
49
|
+
|
|
50
|
+
# get message from the queue
|
|
51
|
+
msg = q.pop[:payload]
|
|
52
|
+
|
|
53
|
+
puts 'This is the message: ' + msg + "\n\n"
|
|
54
|
+
|
|
55
|
+
# close the connection
|
|
56
|
+
b.stop
|
|
57
|
+
|
|
58
|
+
=== EVEN QUICKER START
|
|
59
|
+
|
|
60
|
+
require 'bunny'
|
|
61
|
+
|
|
62
|
+
# Create a direct queue named 'my_testq'
|
|
63
|
+
Bunny.run { |c| c.queue('my_testq') }
|
|
64
|
+
|
|
65
|
+
=== OTHER:
|
|
66
|
+
Please see the _examples_ directory for additional usage information.
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
desc "Run AMQP 0-8 rspec tests"
|
|
2
|
+
task :spec08 do
|
|
3
|
+
require 'spec/rake/spectask'
|
|
4
|
+
puts "===== Running 0-8 tests ====="
|
|
5
|
+
Spec::Rake::SpecTask.new("spec08") do |t|
|
|
6
|
+
t.spec_files = FileList["spec/spec_08/*_spec.rb"]
|
|
7
|
+
t.spec_opts = ['--color']
|
|
8
|
+
end
|
|
9
|
+
end
|
|
10
|
+
|
|
11
|
+
desc "Run AMQP 0-9 rspec tests"
|
|
12
|
+
task :spec09 do
|
|
13
|
+
require 'spec/rake/spectask'
|
|
14
|
+
puts "===== Running 0-9 tests ====="
|
|
15
|
+
Spec::Rake::SpecTask.new("spec09") do |t|
|
|
16
|
+
t.spec_files = FileList["spec/spec_09/*_spec.rb"]
|
|
17
|
+
t.spec_opts = ['--color']
|
|
18
|
+
end
|
|
19
|
+
end
|
|
20
|
+
|
|
21
|
+
task :default => [ :spec08 ]
|
|
22
|
+
|
|
23
|
+
desc "Run all rspec tests"
|
|
24
|
+
task :all => [:spec08, :spec09]
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
Gem::Specification.new do |s|
|
|
2
|
+
s.name = %q{bunny}
|
|
3
|
+
s.version = "0.6.0"
|
|
4
|
+
s.authors = ["Chris Duncan"]
|
|
5
|
+
s.date = %q{2009-10-05}
|
|
6
|
+
s.description = %q{Another synchronous Ruby AMQP client}
|
|
7
|
+
s.email = %q{celldee@gmail.com}
|
|
8
|
+
s.rubyforge_project = %q{bunny-amqp}
|
|
9
|
+
s.has_rdoc = true
|
|
10
|
+
s.extra_rdoc_files = [ "README.rdoc" ]
|
|
11
|
+
s.rdoc_options = [ "--main", "README.rdoc" ]
|
|
12
|
+
s.homepage = %q{http://github.com/celldee/bunny/tree/master}
|
|
13
|
+
s.summary = %q{A synchronous Ruby AMQP client that enables interaction with AMQP-compliant brokers/servers.}
|
|
14
|
+
s.files = ["LICENSE",
|
|
15
|
+
"README.rdoc",
|
|
16
|
+
"Rakefile",
|
|
17
|
+
"bunny.gemspec",
|
|
18
|
+
"examples/simple_08.rb",
|
|
19
|
+
"examples/simple_ack_08.rb",
|
|
20
|
+
"examples/simple_consumer_08.rb",
|
|
21
|
+
"examples/simple_fanout_08.rb",
|
|
22
|
+
"examples/simple_publisher_08.rb",
|
|
23
|
+
"examples/simple_topic_08.rb",
|
|
24
|
+
"examples/simple_headers_08.rb",
|
|
25
|
+
"examples/simple_09.rb",
|
|
26
|
+
"examples/simple_ack_09.rb",
|
|
27
|
+
"examples/simple_consumer_09.rb",
|
|
28
|
+
"examples/simple_fanout_09.rb",
|
|
29
|
+
"examples/simple_publisher_09.rb",
|
|
30
|
+
"examples/simple_topic_09.rb",
|
|
31
|
+
"examples/simple_headers_09.rb",
|
|
32
|
+
"lib/bunny.rb",
|
|
33
|
+
"lib/bunny/channel08.rb",
|
|
34
|
+
"lib/bunny/channel09.rb",
|
|
35
|
+
"lib/bunny/client08.rb",
|
|
36
|
+
"lib/bunny/client09.rb",
|
|
37
|
+
"lib/bunny/exchange08.rb",
|
|
38
|
+
"lib/bunny/exchange09.rb",
|
|
39
|
+
"lib/bunny/queue08.rb",
|
|
40
|
+
"lib/bunny/queue09.rb",
|
|
41
|
+
"lib/bunny/subscription08.rb",
|
|
42
|
+
"lib/bunny/subscription09.rb",
|
|
43
|
+
"lib/qrack/client.rb",
|
|
44
|
+
"lib/qrack/channel.rb",
|
|
45
|
+
"lib/qrack/queue.rb",
|
|
46
|
+
"lib/qrack/subscription.rb",
|
|
47
|
+
"lib/qrack/protocol/protocol08.rb",
|
|
48
|
+
"lib/qrack/protocol/protocol09.rb",
|
|
49
|
+
"lib/qrack/protocol/spec08.rb",
|
|
50
|
+
"lib/qrack/protocol/spec09.rb",
|
|
51
|
+
"lib/qrack/qrack08.rb",
|
|
52
|
+
"lib/qrack/qrack09.rb",
|
|
53
|
+
"lib/qrack/transport/buffer08.rb",
|
|
54
|
+
"lib/qrack/transport/buffer09.rb",
|
|
55
|
+
"lib/qrack/transport/frame08.rb",
|
|
56
|
+
"lib/qrack/transport/frame09.rb",
|
|
57
|
+
"spec/spec_08/bunny_spec.rb",
|
|
58
|
+
"spec/spec_08/exchange_spec.rb",
|
|
59
|
+
"spec/spec_08/queue_spec.rb",
|
|
60
|
+
"spec/spec_08/connection_spec.rb",
|
|
61
|
+
"spec/spec_09/bunny_spec.rb",
|
|
62
|
+
"spec/spec_09/exchange_spec.rb",
|
|
63
|
+
"spec/spec_09/queue_spec.rb",
|
|
64
|
+
"spec/spec_09/connection_spec.rb"]
|
|
65
|
+
end
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# simple_08.rb
|
|
2
|
+
|
|
3
|
+
# Assumes that target message broker/server has a user called 'guest' with a password 'guest'
|
|
4
|
+
# and that it is running on 'localhost'.
|
|
5
|
+
|
|
6
|
+
# If this is not the case, please change the 'Bunny.new' call below to include
|
|
7
|
+
# the relevant arguments e.g. b = Bunny.new(:user => 'john', :pass => 'doe', :host => 'foobar')
|
|
8
|
+
|
|
9
|
+
$:.unshift File.dirname(__FILE__) + '/../lib'
|
|
10
|
+
|
|
11
|
+
require 'bunny'
|
|
12
|
+
|
|
13
|
+
b = Bunny.new(:logging => true)
|
|
14
|
+
|
|
15
|
+
# start a communication session with the amqp server
|
|
16
|
+
b.start
|
|
17
|
+
|
|
18
|
+
# declare a queue
|
|
19
|
+
q = b.queue('test1')
|
|
20
|
+
|
|
21
|
+
# publish a message to the queue
|
|
22
|
+
q.publish('Hello everybody!')
|
|
23
|
+
|
|
24
|
+
# get message from the queue
|
|
25
|
+
msg = q.pop[:payload]
|
|
26
|
+
|
|
27
|
+
puts 'This is the message: ' + msg + "\n\n"
|
|
28
|
+
|
|
29
|
+
# close the client connection
|
|
30
|
+
b.stop
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# simple_09.rb
|
|
2
|
+
|
|
3
|
+
# Assumes that target message broker/server has a user called 'guest' with a password 'guest'
|
|
4
|
+
# and that it is running on 'localhost'.
|
|
5
|
+
|
|
6
|
+
# If this is not the case, please change the 'Bunny.new' call below to include
|
|
7
|
+
# the relevant arguments e.g. b = Bunny.new(:user => 'john', :pass => 'doe', :host => 'foobar')
|
|
8
|
+
|
|
9
|
+
$:.unshift File.dirname(__FILE__) + '/../lib'
|
|
10
|
+
|
|
11
|
+
require 'bunny'
|
|
12
|
+
|
|
13
|
+
b = Bunny.new(:logging => true, :spec => '09')
|
|
14
|
+
|
|
15
|
+
# start a communication session with the amqp server
|
|
16
|
+
b.start
|
|
17
|
+
|
|
18
|
+
# declare a queue
|
|
19
|
+
q = b.queue('test1')
|
|
20
|
+
|
|
21
|
+
# publish a message to the queue
|
|
22
|
+
q.publish('Hello everybody!')
|
|
23
|
+
|
|
24
|
+
# get message from the queue
|
|
25
|
+
msg = q.pop[:payload]
|
|
26
|
+
|
|
27
|
+
puts 'This is the message: ' + msg + "\n\n"
|
|
28
|
+
|
|
29
|
+
# close the client connection
|
|
30
|
+
b.stop
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# simple_ack_08.rb
|
|
2
|
+
|
|
3
|
+
# Assumes that target message broker/server has a user called 'guest' with a password 'guest'
|
|
4
|
+
# and that it is running on 'localhost'.
|
|
5
|
+
|
|
6
|
+
# If this is not the case, please change the 'Bunny.new' call below to include
|
|
7
|
+
# the relevant arguments e.g. b = Bunny.new(:user => 'john', :pass => 'doe', :host => 'foobar')
|
|
8
|
+
|
|
9
|
+
$:.unshift File.dirname(__FILE__) + '/../lib'
|
|
10
|
+
|
|
11
|
+
require 'bunny'
|
|
12
|
+
|
|
13
|
+
b = Bunny.new(:logging => true)
|
|
14
|
+
|
|
15
|
+
# start a communication session with the amqp server
|
|
16
|
+
b.start
|
|
17
|
+
|
|
18
|
+
# declare a queue
|
|
19
|
+
q = b.queue('test1')
|
|
20
|
+
|
|
21
|
+
# publish a message to the queue
|
|
22
|
+
q.publish('Testing acknowledgements')
|
|
23
|
+
|
|
24
|
+
# get message from the queue
|
|
25
|
+
msg = q.pop(:ack => true)[:payload]
|
|
26
|
+
|
|
27
|
+
# acknowledge receipt of message
|
|
28
|
+
q.ack
|
|
29
|
+
|
|
30
|
+
puts 'This is the message: ' + msg + "\n\n"
|
|
31
|
+
|
|
32
|
+
# close the client connection
|
|
33
|
+
b.stop
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# simple_ack_09.rb
|
|
2
|
+
|
|
3
|
+
# Assumes that target message broker/server has a user called 'guest' with a password 'guest'
|
|
4
|
+
# and that it is running on 'localhost'.
|
|
5
|
+
|
|
6
|
+
# If this is not the case, please change the 'Bunny.new' call below to include
|
|
7
|
+
# the relevant arguments e.g. b = Bunny.new(:user => 'john', :pass => 'doe', :host => 'foobar')
|
|
8
|
+
|
|
9
|
+
$:.unshift File.dirname(__FILE__) + '/../lib'
|
|
10
|
+
|
|
11
|
+
require 'bunny'
|
|
12
|
+
|
|
13
|
+
b = Bunny.new(:logging => true, :spec => '09')
|
|
14
|
+
|
|
15
|
+
# start a communication session with the amqp server
|
|
16
|
+
b.start
|
|
17
|
+
|
|
18
|
+
# declare a queue
|
|
19
|
+
q = b.queue('test1')
|
|
20
|
+
|
|
21
|
+
# publish a message to the queue
|
|
22
|
+
q.publish('Testing acknowledgements')
|
|
23
|
+
|
|
24
|
+
# get message from the queue
|
|
25
|
+
msg = q.pop(:ack => true)[:payload]
|
|
26
|
+
|
|
27
|
+
# acknowledge receipt of message
|
|
28
|
+
q.ack
|
|
29
|
+
|
|
30
|
+
puts 'This is the message: ' + msg + "\n\n"
|
|
31
|
+
|
|
32
|
+
# close the client connection
|
|
33
|
+
b.stop
|