taps 0.3.10 → 0.3.11

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. data/Rakefile +1 -1
  2. data/VERSION.yml +1 -1
  3. data/lib/taps/data_stream.rb +4 -0
  4. metadata +4 -5
data/Rakefile CHANGED
@@ -14,7 +14,7 @@ begin
14
14
  s.add_dependency 'sinatra', '~> 1.0.0'
15
15
  s.add_dependency 'rest-client', '~> 1.4.0'
16
16
  s.add_dependency 'sequel', '~> 3.13.0'
17
- s.add_dependency 'sqlite3-ruby', '~> 1.2.0'
17
+ s.add_dependency 'sqlite3-ruby', '~> 1.2'
18
18
  s.add_dependency 'rack', '>= 1.0.1'
19
19
 
20
20
  s.rubyforge_project = "taps"
@@ -1,5 +1,5 @@
1
1
  ---
2
2
  :build:
3
3
  :minor: 3
4
- :patch: 10
4
+ :patch: 11
5
5
  :major: 0
@@ -9,6 +9,8 @@ module Taps
9
9
  class DataStream
10
10
  class CorruptedData < Exception; end
11
11
 
12
+ DEFAULT_CHUNKSIZE = 1000
13
+
12
14
  attr_reader :db, :state
13
15
 
14
16
  def initialize(db, state)
@@ -19,6 +21,7 @@ class DataStream
19
21
  :num_chunksize => 0,
20
22
  :total_chunksize => 0,
21
23
  }.merge(state)
24
+ @state[:chunksize] ||= DEFAULT_CHUNKSIZE
22
25
  @complete = false
23
26
  end
24
27
 
@@ -223,6 +226,7 @@ class DataStreamKeyed < DataStream
223
226
  def initialize(db, state)
224
227
  super(db, state)
225
228
  @state = { :primary_key => order_by(state[:table_name]).first, :filter => 0 }.merge(state)
229
+ @state[:chunksize] ||= DEFAULT_CHUNKSIZE
226
230
  @buffer = []
227
231
  end
228
232
 
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 3
8
- - 10
9
- version: 0.3.10
8
+ - 11
9
+ version: 0.3.11
10
10
  platform: ruby
11
11
  authors:
12
12
  - Ricardo Chimal, Jr.
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2010-07-02 00:00:00 -07:00
17
+ date: 2010-07-16 00:00:00 -07:00
18
18
  default_executable:
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
@@ -90,8 +90,7 @@ dependencies:
90
90
  segments:
91
91
  - 1
92
92
  - 2
93
- - 0
94
- version: 1.2.0
93
+ version: "1.2"
95
94
  type: :runtime
96
95
  version_requirements: *id005
97
96
  - !ruby/object:Gem::Dependency