baza 0.0.37 → 0.0.38
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/dependabot.yml +13 -0
- data/.ruby-version +1 -1
- data/Gemfile.lock +40 -36
- data/VERSION +1 -1
- data/baza.gemspec +28 -49
- data/lib/baza/driver/mysql/databases.rb +3 -3
- data/peak_flow.yml +21 -3
- data/spec/info_active_record_mysql2_peak_flow.rb +3 -2
- data/spec/info_active_record_mysql_peak_flow.rb +3 -2
- data/spec/info_active_record_pg_peak_flow.rb +3 -1
- data/spec/info_mysql2_peak_flow.rb +2 -1
- data/spec/info_mysql_peak_flow.rb +2 -1
- data/spec/info_pg_peak_flow.rb +3 -1
- metadata +4 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a023d1752c079d9018cb06a5bdeaac2e86ecfc0734983a81db8e0212eae3e781
|
4
|
+
data.tar.gz: 1435ebdda514818695aff2314609a8a05e0bc021cff3cd5650c3bb69fe9bbeb2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 100e78cf3b0f1c84e45049260190e2d3e134a4f47b62b50df2955a6aa0fb85adde9fcf4a36c797480359473a81b3845a97c99e26f07432f8901a6b045622d581
|
7
|
+
data.tar.gz: 330e48088ea16f46d78f685e0238882b2b7acf4497e18d80b020790fcc01b78fd62168cf53364f01f149d6befdcf5f6ee5796100aae8884a7c1ccec4e88410aa
|
data/.ruby-version
CHANGED
@@ -1 +1 @@
|
|
1
|
-
2.
|
1
|
+
2.7.4
|
data/Gemfile.lock
CHANGED
@@ -1,19 +1,19 @@
|
|
1
1
|
GEM
|
2
2
|
remote: http://rubygems.org/
|
3
3
|
specs:
|
4
|
-
activemodel (6.
|
5
|
-
activesupport (= 6.
|
6
|
-
activerecord (6.
|
7
|
-
activemodel (= 6.
|
8
|
-
activesupport (= 6.
|
9
|
-
activerecord-jdbc-adapter (
|
10
|
-
activerecord (~> 6.
|
11
|
-
activesupport (6.
|
4
|
+
activemodel (6.1.4.1)
|
5
|
+
activesupport (= 6.1.4.1)
|
6
|
+
activerecord (6.1.4.1)
|
7
|
+
activemodel (= 6.1.4.1)
|
8
|
+
activesupport (= 6.1.4.1)
|
9
|
+
activerecord-jdbc-adapter (61.1-java)
|
10
|
+
activerecord (~> 6.1.0)
|
11
|
+
activesupport (6.1.4.1)
|
12
12
|
concurrent-ruby (~> 1.0, >= 1.0.2)
|
13
|
-
i18n (>=
|
14
|
-
minitest (
|
15
|
-
tzinfo (~>
|
16
|
-
zeitwerk (~> 2.
|
13
|
+
i18n (>= 1.6, < 2)
|
14
|
+
minitest (>= 5.1)
|
15
|
+
tzinfo (~> 2.0)
|
16
|
+
zeitwerk (~> 2.3)
|
17
17
|
addressable (2.4.0)
|
18
18
|
array_enumerator (0.0.10)
|
19
19
|
ast (2.4.0)
|
@@ -22,8 +22,8 @@ GEM
|
|
22
22
|
best_practice_project (0.0.9)
|
23
23
|
auto_autoloader
|
24
24
|
builder (3.2.3)
|
25
|
-
coderay (1.1.
|
26
|
-
concurrent-ruby (1.1.
|
25
|
+
coderay (1.1.3)
|
26
|
+
concurrent-ruby (1.1.9)
|
27
27
|
datet (0.0.25)
|
28
28
|
descendants_tracker (0.0.4)
|
29
29
|
thread_safe (~> 0.3, >= 0.3.1)
|
@@ -31,7 +31,7 @@ GEM
|
|
31
31
|
event_handler (0.0.0)
|
32
32
|
faraday (0.9.2)
|
33
33
|
multipart-post (>= 1.2, < 3)
|
34
|
-
ffi (1.
|
34
|
+
ffi (1.15.0-java)
|
35
35
|
git (1.3.0)
|
36
36
|
github_api (0.16.0)
|
37
37
|
addressable (~> 2.4.0)
|
@@ -42,10 +42,10 @@ GEM
|
|
42
42
|
oauth2 (~> 1.0)
|
43
43
|
hashie (3.5.7)
|
44
44
|
highline (1.7.10)
|
45
|
-
i18n (1.
|
45
|
+
i18n (1.8.10)
|
46
46
|
concurrent-ruby (~> 1.0)
|
47
47
|
jar-dependencies (0.3.12)
|
48
|
-
jdbc-mysql (
|
48
|
+
jdbc-mysql (8.0.17)
|
49
49
|
jdbc-sqlite3 (3.28.0)
|
50
50
|
jeweler (2.3.9)
|
51
51
|
builder
|
@@ -59,17 +59,19 @@ GEM
|
|
59
59
|
rdoc
|
60
60
|
semver2
|
61
61
|
jwt (1.5.6)
|
62
|
-
method_source (0.
|
62
|
+
method_source (1.0.0)
|
63
63
|
mime-types (2.99.3)
|
64
|
-
mini_portile2 (2.
|
65
|
-
minitest (5.
|
64
|
+
mini_portile2 (2.6.1)
|
65
|
+
minitest (5.14.4)
|
66
66
|
multi_json (1.13.1)
|
67
67
|
multi_xml (0.6.0)
|
68
68
|
multipart-post (2.0.0)
|
69
69
|
mysql2 (0.4.10)
|
70
|
-
nokogiri (1.
|
71
|
-
mini_portile2 (~> 2.
|
72
|
-
|
70
|
+
nokogiri (1.12.5)
|
71
|
+
mini_portile2 (~> 2.6.1)
|
72
|
+
racc (~> 1.4)
|
73
|
+
nokogiri (1.12.5-java)
|
74
|
+
racc (~> 1.4)
|
73
75
|
oauth2 (1.4.0)
|
74
76
|
faraday (>= 0.8, < 0.13)
|
75
77
|
jwt (~> 1.0)
|
@@ -80,21 +82,23 @@ GEM
|
|
80
82
|
ast (~> 2.4.0)
|
81
83
|
pg (0.21.0)
|
82
84
|
powerpack (0.1.1)
|
83
|
-
pry (0.
|
84
|
-
coderay (~> 1.1
|
85
|
-
method_source (~>
|
86
|
-
pry (0.
|
87
|
-
coderay (~> 1.1
|
88
|
-
method_source (~>
|
85
|
+
pry (0.14.1)
|
86
|
+
coderay (~> 1.1)
|
87
|
+
method_source (~> 1.0)
|
88
|
+
pry (0.14.1-java)
|
89
|
+
coderay (~> 1.1)
|
90
|
+
method_source (~> 1.0)
|
89
91
|
spoon (~> 0.0)
|
90
92
|
psych (3.0.2)
|
91
93
|
psych (3.0.2-java)
|
92
94
|
jar-dependencies (>= 0.1.7)
|
93
|
-
|
95
|
+
racc (1.5.2)
|
96
|
+
racc (1.5.2-java)
|
97
|
+
rack (2.2.3)
|
94
98
|
rainbow (2.2.2)
|
95
99
|
rake
|
96
|
-
rake (
|
97
|
-
rdoc (6.2
|
100
|
+
rake (13.0.1)
|
101
|
+
rdoc (6.3.2)
|
98
102
|
rspec (3.4.0)
|
99
103
|
rspec-core (~> 3.4.0)
|
100
104
|
rspec-expectations (~> 3.4.0)
|
@@ -123,11 +127,11 @@ GEM
|
|
123
127
|
string-cases (0.0.4)
|
124
128
|
thread_safe (0.3.6)
|
125
129
|
thread_safe (0.3.6-java)
|
126
|
-
tzinfo (
|
127
|
-
|
130
|
+
tzinfo (2.0.4)
|
131
|
+
concurrent-ruby (~> 1.0)
|
128
132
|
unicode-display_width (1.3.0)
|
129
133
|
wref (0.0.8)
|
130
|
-
zeitwerk (2.
|
134
|
+
zeitwerk (2.4.2)
|
131
135
|
|
132
136
|
PLATFORMS
|
133
137
|
java
|
@@ -157,4 +161,4 @@ DEPENDENCIES
|
|
157
161
|
wref (~> 0.0.8)
|
158
162
|
|
159
163
|
BUNDLED WITH
|
160
|
-
|
164
|
+
2.2.28
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.38
|
data/baza.gemspec
CHANGED
@@ -2,16 +2,16 @@
|
|
2
2
|
# DO NOT EDIT THIS FILE DIRECTLY
|
3
3
|
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
4
4
|
# -*- encoding: utf-8 -*-
|
5
|
-
# stub: baza 0.0.
|
5
|
+
# stub: baza 0.0.38 ruby lib
|
6
6
|
|
7
7
|
Gem::Specification.new do |s|
|
8
8
|
s.name = "baza".freeze
|
9
|
-
s.version = "0.0.
|
9
|
+
s.version = "0.0.38"
|
10
10
|
|
11
11
|
s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version=
|
12
12
|
s.require_paths = ["lib".freeze]
|
13
13
|
s.authors = ["Kasper Johansen".freeze]
|
14
|
-
s.date = "
|
14
|
+
s.date = "2021-10-04"
|
15
15
|
s.description = "A database abstraction layer, model framework and database framework.".freeze
|
16
16
|
s.email = "kj@gfish.com".freeze
|
17
17
|
s.extra_rdoc_files = [
|
@@ -20,6 +20,7 @@ Gem::Specification.new do |s|
|
|
20
20
|
]
|
21
21
|
s.files = [
|
22
22
|
".document",
|
23
|
+
".github/dependabot.yml",
|
23
24
|
".rspec",
|
24
25
|
".rubocop.yml",
|
25
26
|
".rubocop_todo.yml",
|
@@ -207,57 +208,35 @@ Gem::Specification.new do |s|
|
|
207
208
|
]
|
208
209
|
s.homepage = "http://github.com/kaspernj/baza".freeze
|
209
210
|
s.licenses = ["MIT".freeze]
|
210
|
-
s.rubygems_version = "3.
|
211
|
+
s.rubygems_version = "3.1.6".freeze
|
211
212
|
s.summary = "A database abstraction layer, model framework and database framework.".freeze
|
212
213
|
|
213
214
|
if s.respond_to? :specification_version then
|
214
215
|
s.specification_version = 4
|
216
|
+
end
|
215
217
|
|
216
|
-
|
217
|
-
|
218
|
-
|
219
|
-
|
220
|
-
|
221
|
-
|
222
|
-
|
223
|
-
|
224
|
-
|
225
|
-
|
226
|
-
|
227
|
-
|
228
|
-
|
229
|
-
|
230
|
-
|
231
|
-
|
232
|
-
|
233
|
-
|
234
|
-
|
235
|
-
|
236
|
-
|
237
|
-
|
238
|
-
else
|
239
|
-
s.add_dependency(%q<array_enumerator>.freeze, ["~> 0.0.10"])
|
240
|
-
s.add_dependency(%q<auto_autoloader>.freeze, ["~> 0.0.5"])
|
241
|
-
s.add_dependency(%q<datet>.freeze, ["~> 0.0.25"])
|
242
|
-
s.add_dependency(%q<event_handler>.freeze, ["~> 0.0.0"])
|
243
|
-
s.add_dependency(%q<simple_delegate>.freeze, ["~> 0.0.2"])
|
244
|
-
s.add_dependency(%q<string-cases>.freeze, ["~> 0.0.4"])
|
245
|
-
s.add_dependency(%q<wref>.freeze, ["~> 0.0.8"])
|
246
|
-
s.add_dependency(%q<activerecord>.freeze, [">= 0"])
|
247
|
-
s.add_dependency(%q<activerecord-jdbc-adapter>.freeze, [">= 0"])
|
248
|
-
s.add_dependency(%q<best_practice_project>.freeze, ["= 0.0.9"])
|
249
|
-
s.add_dependency(%q<bundler>.freeze, [">= 0"])
|
250
|
-
s.add_dependency(%q<jdbc-mysql>.freeze, [">= 0"])
|
251
|
-
s.add_dependency(%q<jdbc-sqlite3>.freeze, [">= 0"])
|
252
|
-
s.add_dependency(%q<jeweler>.freeze, ["= 2.3.9"])
|
253
|
-
s.add_dependency(%q<mysql2>.freeze, ["= 0.4.10"])
|
254
|
-
s.add_dependency(%q<pg>.freeze, ["= 0.21.0"])
|
255
|
-
s.add_dependency(%q<pry>.freeze, [">= 0"])
|
256
|
-
s.add_dependency(%q<rdoc>.freeze, [">= 0"])
|
257
|
-
s.add_dependency(%q<rspec>.freeze, ["= 3.4.0"])
|
258
|
-
s.add_dependency(%q<rubocop>.freeze, ["= 0.39.0"])
|
259
|
-
s.add_dependency(%q<sqlite3>.freeze, ["< 1.5"])
|
260
|
-
end
|
218
|
+
if s.respond_to? :add_runtime_dependency then
|
219
|
+
s.add_runtime_dependency(%q<array_enumerator>.freeze, ["~> 0.0.10"])
|
220
|
+
s.add_runtime_dependency(%q<auto_autoloader>.freeze, ["~> 0.0.5"])
|
221
|
+
s.add_runtime_dependency(%q<datet>.freeze, ["~> 0.0.25"])
|
222
|
+
s.add_runtime_dependency(%q<event_handler>.freeze, ["~> 0.0.0"])
|
223
|
+
s.add_runtime_dependency(%q<simple_delegate>.freeze, ["~> 0.0.2"])
|
224
|
+
s.add_runtime_dependency(%q<string-cases>.freeze, ["~> 0.0.4"])
|
225
|
+
s.add_runtime_dependency(%q<wref>.freeze, ["~> 0.0.8"])
|
226
|
+
s.add_development_dependency(%q<activerecord>.freeze, [">= 0"])
|
227
|
+
s.add_development_dependency(%q<activerecord-jdbc-adapter>.freeze, [">= 0"])
|
228
|
+
s.add_development_dependency(%q<best_practice_project>.freeze, ["= 0.0.9"])
|
229
|
+
s.add_development_dependency(%q<bundler>.freeze, [">= 0"])
|
230
|
+
s.add_development_dependency(%q<jdbc-mysql>.freeze, [">= 0"])
|
231
|
+
s.add_development_dependency(%q<jdbc-sqlite3>.freeze, [">= 0"])
|
232
|
+
s.add_development_dependency(%q<jeweler>.freeze, ["= 2.3.9"])
|
233
|
+
s.add_development_dependency(%q<mysql2>.freeze, ["= 0.4.10"])
|
234
|
+
s.add_development_dependency(%q<pg>.freeze, ["= 0.21.0"])
|
235
|
+
s.add_development_dependency(%q<pry>.freeze, [">= 0"])
|
236
|
+
s.add_development_dependency(%q<rdoc>.freeze, [">= 0"])
|
237
|
+
s.add_development_dependency(%q<rspec>.freeze, ["= 3.4.0"])
|
238
|
+
s.add_development_dependency(%q<rubocop>.freeze, ["= 0.39.0"])
|
239
|
+
s.add_development_dependency(%q<sqlite3>.freeze, ["< 1.5"])
|
261
240
|
else
|
262
241
|
s.add_dependency(%q<array_enumerator>.freeze, ["~> 0.0.10"])
|
263
242
|
s.add_dependency(%q<auto_autoloader>.freeze, ["~> 0.0.5"])
|
@@ -3,10 +3,10 @@ class Baza::Driver::Mysql::Databases
|
|
3
3
|
@db = args.fetch(:db)
|
4
4
|
end
|
5
5
|
|
6
|
-
def create(
|
6
|
+
def create(if_not_exists: false, name:)
|
7
7
|
sql = "CREATE DATABASE"
|
8
|
-
sql << " IF NOT EXISTS" if
|
9
|
-
sql << " #{@db.quote_table(
|
8
|
+
sql << " IF NOT EXISTS" if if_not_exists
|
9
|
+
sql << " #{@db.quote_table(name)}"
|
10
10
|
|
11
11
|
@db.query(sql)
|
12
12
|
true
|
data/peak_flow.yml
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
before_install:
|
2
|
+
- sudo apt-get install -y libmysqlclient-dev
|
1
3
|
before_script:
|
2
4
|
- cp spec/info_mysql_peak_flow.rb spec/info_mysql.rb
|
3
5
|
- cp spec/info_mysql2_peak_flow.rb spec/info_mysql2.rb
|
@@ -5,9 +7,25 @@ before_script:
|
|
5
7
|
- cp spec/info_active_record_mysql_peak_flow.rb spec/info_active_record_mysql.rb
|
6
8
|
- cp spec/info_active_record_mysql2_peak_flow.rb spec/info_active_record_mysql2.rb
|
7
9
|
- cp spec/info_active_record_pg_peak_flow.rb spec/info_active_record_pg.rb
|
8
|
-
|
9
|
-
|
10
|
-
|
10
|
+
rvm: true
|
11
|
+
services:
|
12
|
+
postgres:
|
13
|
+
environment:
|
14
|
+
POSTGRES_USER: "build"
|
15
|
+
POSTGRES_PASSWORD: "password"
|
16
|
+
POSTGRES_DB: "baza"
|
17
|
+
expose:
|
18
|
+
- 5432
|
19
|
+
image: postgres:11.4
|
20
|
+
mysql:
|
21
|
+
environment:
|
22
|
+
- MYSQL_USER=build
|
23
|
+
- MYSQL_PASSWORD=password
|
24
|
+
- MYSQL_ROOT_PASSWORD=password
|
25
|
+
- MYSQL_DATABASE=baza
|
26
|
+
image: mysql:5.7.29
|
27
|
+
expose:
|
28
|
+
- 3306
|
11
29
|
script:
|
12
30
|
- bundle exec rspec --tag ~@mysql
|
13
31
|
- bundle exec rake best_practice_project:run
|
@@ -7,9 +7,10 @@ class Baza::InfoActiveRecordMysql2
|
|
7
7
|
|
8
8
|
@conn_pool ||= ::ActiveRecord::Base.establish_connection(
|
9
9
|
adapter: "mysql2",
|
10
|
-
host: "
|
10
|
+
host: "mysql",
|
11
11
|
database: "baza",
|
12
|
-
username: "build"
|
12
|
+
username: "build",
|
13
|
+
password: "password"
|
13
14
|
)
|
14
15
|
@conn = @conn_pool.connection
|
15
16
|
|
@@ -7,9 +7,10 @@ class Baza::InfoActiveRecordMysql
|
|
7
7
|
|
8
8
|
@conn_pool ||= ::ActiveRecord::Base.establish_connection(
|
9
9
|
adapter: "mysql",
|
10
|
-
host: "
|
10
|
+
host: "mysql",
|
11
11
|
database: "baza",
|
12
|
-
username: "build"
|
12
|
+
username: "build",
|
13
|
+
password: "password"
|
13
14
|
)
|
14
15
|
@conn ||= @conn_pool.connection
|
15
16
|
|
@@ -8,7 +8,9 @@ class Baza::InfoActiveRecordPg
|
|
8
8
|
@conn_pool = ::ActiveRecord::Base.establish_connection(
|
9
9
|
adapter: "postgresql",
|
10
10
|
database: "baza",
|
11
|
-
|
11
|
+
host: "postgres",
|
12
|
+
username: "build",
|
13
|
+
password: "password"
|
12
14
|
)
|
13
15
|
@conn = @conn_pool.connection
|
14
16
|
|
data/spec/info_pg_peak_flow.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: baza
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.38
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kasper Johansen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-10-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: array_enumerator
|
@@ -313,6 +313,7 @@ extra_rdoc_files:
|
|
313
313
|
- README.md
|
314
314
|
files:
|
315
315
|
- ".document"
|
316
|
+
- ".github/dependabot.yml"
|
316
317
|
- ".rspec"
|
317
318
|
- ".rubocop.yml"
|
318
319
|
- ".rubocop_todo.yml"
|
@@ -516,7 +517,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
516
517
|
- !ruby/object:Gem::Version
|
517
518
|
version: '0'
|
518
519
|
requirements: []
|
519
|
-
rubygems_version: 3.
|
520
|
+
rubygems_version: 3.1.6
|
520
521
|
signing_key:
|
521
522
|
specification_version: 4
|
522
523
|
summary: A database abstraction layer, model framework and database framework.
|