bulk_insert 1.5.0 → 1.8.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/README.md +42 -1
- data/lib/bulk_insert.rb +2 -2
- data/lib/bulk_insert/statement_adapters.rb +22 -0
- data/lib/bulk_insert/statement_adapters/base_adapter.rb +21 -0
- data/lib/bulk_insert/statement_adapters/generic_adapter.rb +19 -0
- data/lib/bulk_insert/statement_adapters/mysql_adapter.rb +24 -0
- data/lib/bulk_insert/statement_adapters/postgresql_adapter.rb +28 -0
- data/lib/bulk_insert/statement_adapters/sqlite_adapter.rb +19 -0
- data/lib/bulk_insert/version.rb +2 -2
- data/lib/bulk_insert/worker.rb +26 -20
- data/test/bulk_insert/worker_test.rb +203 -25
- data/test/bulk_insert_test.rb +15 -1
- data/test/dummy/config/application.rb +1 -3
- data/test/dummy/db/test.sqlite3 +0 -0
- data/test/dummy/log/test.log +658 -4214
- metadata +45 -42
- data/test/dummy/db/development.sqlite3 +0 -0
- data/test/dummy/log/development.log +0 -17
metadata
CHANGED
@@ -1,14 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bulk_insert
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.8.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jamis Buck
|
8
|
+
- Mauro Berlanda
|
8
9
|
autorequire:
|
9
10
|
bindir: bin
|
10
11
|
cert_chain: []
|
11
|
-
date:
|
12
|
+
date: 2021-02-05 00:00:00.000000000 Z
|
12
13
|
dependencies:
|
13
14
|
- !ruby/object:Gem::Dependency
|
14
15
|
name: activerecord
|
@@ -16,14 +17,14 @@ dependencies:
|
|
16
17
|
requirements:
|
17
18
|
- - ">="
|
18
19
|
- !ruby/object:Gem::Version
|
19
|
-
version:
|
20
|
+
version: 3.2.0
|
20
21
|
type: :runtime
|
21
22
|
prerelease: false
|
22
23
|
version_requirements: !ruby/object:Gem::Requirement
|
23
24
|
requirements:
|
24
25
|
- - ">="
|
25
26
|
- !ruby/object:Gem::Version
|
26
|
-
version:
|
27
|
+
version: 3.2.0
|
27
28
|
- !ruby/object:Gem::Dependency
|
28
29
|
name: sqlite3
|
29
30
|
requirement: !ruby/object:Gem::Requirement
|
@@ -44,17 +45,18 @@ dependencies:
|
|
44
45
|
requirements:
|
45
46
|
- - ">="
|
46
47
|
- !ruby/object:Gem::Version
|
47
|
-
version:
|
48
|
+
version: 3.2.0
|
48
49
|
type: :development
|
49
50
|
prerelease: false
|
50
51
|
version_requirements: !ruby/object:Gem::Requirement
|
51
52
|
requirements:
|
52
53
|
- - ">="
|
53
54
|
- !ruby/object:Gem::Version
|
54
|
-
version:
|
55
|
+
version: 3.2.0
|
55
56
|
description: Faster inserts! Insert N records in a single statement.
|
56
57
|
email:
|
57
58
|
- jamis@jamisbuck.org
|
59
|
+
- mauro.berlanda@gmail.com
|
58
60
|
executables: []
|
59
61
|
extensions: []
|
60
62
|
extra_rdoc_files: []
|
@@ -63,6 +65,12 @@ files:
|
|
63
65
|
- README.md
|
64
66
|
- Rakefile
|
65
67
|
- lib/bulk_insert.rb
|
68
|
+
- lib/bulk_insert/statement_adapters.rb
|
69
|
+
- lib/bulk_insert/statement_adapters/base_adapter.rb
|
70
|
+
- lib/bulk_insert/statement_adapters/generic_adapter.rb
|
71
|
+
- lib/bulk_insert/statement_adapters/mysql_adapter.rb
|
72
|
+
- lib/bulk_insert/statement_adapters/postgresql_adapter.rb
|
73
|
+
- lib/bulk_insert/statement_adapters/sqlite_adapter.rb
|
66
74
|
- lib/bulk_insert/version.rb
|
67
75
|
- lib/bulk_insert/worker.rb
|
68
76
|
- test/bulk_insert/worker_test.rb
|
@@ -98,12 +106,10 @@ files:
|
|
98
106
|
- test/dummy/config/locales/en.yml
|
99
107
|
- test/dummy/config/routes.rb
|
100
108
|
- test/dummy/config/secrets.yml
|
101
|
-
- test/dummy/db/development.sqlite3
|
102
109
|
- test/dummy/db/migrate/20151008181535_create_testings.rb
|
103
110
|
- test/dummy/db/migrate/20151028194232_add_default_value.rb
|
104
111
|
- test/dummy/db/schema.rb
|
105
112
|
- test/dummy/db/test.sqlite3
|
106
|
-
- test/dummy/log/development.log
|
107
113
|
- test/dummy/log/test.log
|
108
114
|
- test/dummy/public/404.html
|
109
115
|
- test/dummy/public/422.html
|
@@ -129,54 +135,51 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
129
135
|
- !ruby/object:Gem::Version
|
130
136
|
version: '0'
|
131
137
|
requirements: []
|
132
|
-
|
133
|
-
rubygems_version: 2.4.5.1
|
138
|
+
rubygems_version: 3.0.3
|
134
139
|
signing_key:
|
135
140
|
specification_version: 4
|
136
141
|
summary: An helper for doing batch (single-statement) inserts in ActiveRecord
|
137
142
|
test_files:
|
138
|
-
- test/
|
139
|
-
- test/bulk_insert_test.rb
|
140
|
-
- test/dummy/app/assets/javascripts/application.js
|
141
|
-
- test/dummy/app/assets/stylesheets/application.css
|
142
|
-
- test/dummy/app/controllers/application_controller.rb
|
143
|
-
- test/dummy/app/helpers/application_helper.rb
|
144
|
-
- test/dummy/app/models/testing.rb
|
145
|
-
- test/dummy/app/views/layouts/application.html.erb
|
143
|
+
- test/test_helper.rb
|
146
144
|
- test/dummy/bin/bundle
|
147
145
|
- test/dummy/bin/rails
|
148
146
|
- test/dummy/bin/rake
|
149
147
|
- test/dummy/bin/setup
|
150
|
-
- test/dummy/
|
151
|
-
- test/dummy/
|
152
|
-
- test/dummy/
|
153
|
-
- test/dummy/
|
154
|
-
- test/dummy/
|
155
|
-
- test/dummy/
|
156
|
-
- test/dummy/
|
148
|
+
- test/dummy/app/views/layouts/application.html.erb
|
149
|
+
- test/dummy/app/models/testing.rb
|
150
|
+
- test/dummy/app/helpers/application_helper.rb
|
151
|
+
- test/dummy/app/controllers/application_controller.rb
|
152
|
+
- test/dummy/app/assets/stylesheets/application.css
|
153
|
+
- test/dummy/app/assets/javascripts/application.js
|
154
|
+
- test/dummy/log/test.log
|
155
|
+
- test/dummy/config/initializers/mime_types.rb
|
156
|
+
- test/dummy/config/initializers/inflections.rb
|
157
|
+
- test/dummy/config/initializers/filter_parameter_logging.rb
|
157
158
|
- test/dummy/config/initializers/assets.rb
|
158
|
-
- test/dummy/config/initializers/backtrace_silencers.rb
|
159
159
|
- test/dummy/config/initializers/cookies_serializer.rb
|
160
|
-
- test/dummy/config/initializers/filter_parameter_logging.rb
|
161
|
-
- test/dummy/config/initializers/inflections.rb
|
162
|
-
- test/dummy/config/initializers/mime_types.rb
|
163
|
-
- test/dummy/config/initializers/session_store.rb
|
164
160
|
- test/dummy/config/initializers/wrap_parameters.rb
|
165
|
-
- test/dummy/config/
|
161
|
+
- test/dummy/config/initializers/session_store.rb
|
162
|
+
- test/dummy/config/initializers/backtrace_silencers.rb
|
166
163
|
- test/dummy/config/routes.rb
|
164
|
+
- test/dummy/config/environment.rb
|
165
|
+
- test/dummy/config/locales/en.yml
|
166
|
+
- test/dummy/config/application.rb
|
167
|
+
- test/dummy/config/environments/test.rb
|
168
|
+
- test/dummy/config/environments/development.rb
|
169
|
+
- test/dummy/config/environments/production.rb
|
170
|
+
- test/dummy/config/database.yml
|
171
|
+
- test/dummy/config/boot.rb
|
167
172
|
- test/dummy/config/secrets.yml
|
168
|
-
- test/dummy/
|
169
|
-
- test/dummy/db/development.sqlite3
|
170
|
-
- test/dummy/db/migrate/20151008181535_create_testings.rb
|
171
|
-
- test/dummy/db/migrate/20151028194232_add_default_value.rb
|
172
|
-
- test/dummy/db/schema.rb
|
173
|
-
- test/dummy/db/test.sqlite3
|
174
|
-
- test/dummy/log/development.log
|
175
|
-
- test/dummy/log/test.log
|
176
|
-
- test/dummy/public/404.html
|
173
|
+
- test/dummy/Rakefile
|
177
174
|
- test/dummy/public/422.html
|
178
175
|
- test/dummy/public/500.html
|
176
|
+
- test/dummy/public/404.html
|
179
177
|
- test/dummy/public/favicon.ico
|
180
|
-
- test/dummy/
|
178
|
+
- test/dummy/db/test.sqlite3
|
179
|
+
- test/dummy/db/schema.rb
|
180
|
+
- test/dummy/db/migrate/20151008181535_create_testings.rb
|
181
|
+
- test/dummy/db/migrate/20151028194232_add_default_value.rb
|
182
|
+
- test/dummy/config.ru
|
181
183
|
- test/dummy/README.rdoc
|
182
|
-
- test/
|
184
|
+
- test/bulk_insert/worker_test.rb
|
185
|
+
- test/bulk_insert_test.rb
|
Binary file
|
@@ -1,17 +0,0 @@
|
|
1
|
-
[1m[36m (2.8ms)[0m [1mCREATE TABLE "schema_migrations" ("version" varchar NOT NULL) [0m
|
2
|
-
[1m[35m (0.1ms)[0m select sqlite_version(*)
|
3
|
-
[1m[36m (1.0ms)[0m [1mCREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")[0m
|
4
|
-
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|
5
|
-
Migrating to CreateTestings (20151008181535)
|
6
|
-
[1m[36m (0.1ms)[0m [1mbegin transaction[0m
|
7
|
-
[1m[35m (0.4ms)[0m CREATE TABLE "testings" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "greeting" varchar, "age" integer, "happy" boolean, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)
|
8
|
-
[1m[36mSQL (0.2ms)[0m [1mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "20151008181535"]]
|
9
|
-
[1m[35m (0.8ms)[0m commit transaction
|
10
|
-
[1m[36mActiveRecord::SchemaMigration Load (0.1ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
11
|
-
[1m[36mActiveRecord::SchemaMigration Load (0.7ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
12
|
-
Migrating to AddDefaultValue (20151028194232)
|
13
|
-
[1m[35m (0.1ms)[0m begin transaction
|
14
|
-
[1m[36m (0.4ms)[0m [1mALTER TABLE "testings" ADD "color" varchar DEFAULT 'chartreuse'[0m
|
15
|
-
[1m[35mSQL (0.2ms)[0m INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20151028194232"]]
|
16
|
-
[1m[36m (2.1ms)[0m [1mcommit transaction[0m
|
17
|
-
[1m[35mActiveRecord::SchemaMigration Load (0.1ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|