pools 0.1.2 → 0.1.3

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.
Files changed (2) hide show
  1. data/lib/cassandra-cql/pooled.rb +28 -0
  2. metadata +6 -5
@@ -0,0 +1,28 @@
1
+ require 'pools'
2
+
3
+ module CassandraCQL; end
4
+ unless CassandraCQL.respond_to?(:VERSION)
5
+ require 'cassandra-cql'
6
+ end
7
+
8
+ module CassandraCQL
9
+ class Pooled
10
+ include ::Pools::Pooled
11
+
12
+ def initialize(*args)
13
+ @cassandra_args = args.dup
14
+ super
15
+ end
16
+
17
+ def __connection
18
+ CassandraCQL::Database.new(*@cassandra_args)
19
+ end
20
+
21
+ def __disconnect(client)
22
+ client.disconnect! if client
23
+ end
24
+
25
+ preparation_methods :login!, :keyspace=
26
+ connection_methods :execute, :prepare, :keyspaces, :schema
27
+ end
28
+ end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pools
3
3
  version: !ruby/object:Gem::Version
4
- hash: 31
4
+ hash: 29
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 2
10
- version: 0.1.2
9
+ - 3
10
+ version: 0.1.3
11
11
  platform: ruby
12
12
  authors:
13
13
  - Michael Rykov
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-09-22 00:00:00 Z
18
+ date: 2012-01-09 00:00:00 Z
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
21
21
  name: activesupport
@@ -55,6 +55,7 @@ files:
55
55
  - Rakefile
56
56
  - LICENSE
57
57
  - lib/cassandra/pooled.rb
58
+ - lib/cassandra-cql/pooled.rb
58
59
  - lib/pools/connection_pool.rb
59
60
  - lib/pools/handler.rb
60
61
  - lib/pools/middleware.rb
@@ -91,7 +92,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
91
92
  requirements: []
92
93
 
93
94
  rubyforge_project:
94
- rubygems_version: 1.8.10
95
+ rubygems_version: 1.8.11
95
96
  signing_key:
96
97
  specification_version: 3
97
98
  summary: Generalized connection pooling