strum 0.0.46 → 0.0.47

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0dff86c480a8f43b04d4895e092a70054147c22220f50680fe955c781b2478ad
4
- data.tar.gz: 753d4347e3900071ce55a9d5f27be89f9f90a5761ca25ff3233a1562fc883e19
3
+ metadata.gz: b10dd96f151424fb690896c751c554d34a7a846d67dc1f6f64a79362f0ebcfee
4
+ data.tar.gz: 1edd401414874ffa9dcfad7c703df50c6eb4a6a831e42c527f76b79c339fb070
5
5
  SHA512:
6
- metadata.gz: 47de68438dbfdd3db056e9d597d588a5273768d0a3faa896e347e1d8e865917dcbe60bb44b58ba2c3e99bb36a960ad80b5af6ea386b4e58144bbedd60b7c320f
7
- data.tar.gz: bec9ac9eab2fc9488131cecbfb7c9bab0d77a9b3d90d44c89ddae077511d98e62f3d69e6045ef613da4e23e9870b1f0316e30aac3fb0fddedcf2e1184b8a374d
6
+ metadata.gz: f6a0651ec30a8fd176fab884b04c88948eee8490fb749363b231a290aa6535b7cccf4e33ce82cc870fe1484f41e3ea7d2f4c017bb543323e3d9350b8ec0f49f9
7
+ data.tar.gz: 7b0c62128d6c9fbdc1706f0c8ab26fd35ad52d93869646b13fa19395cc97528d3b2c4884841191d8dba28c3626f300b5b37d703d111c95e0e79ddfa92a79ede9
@@ -1,16 +1,17 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- strum (0.0.45)
4
+ strum (0.0.47)
5
5
  dry-inflector (~> 0.2.0)
6
6
  dry-struct (~> 1.2)
7
+ sequel (~> 5.29)
7
8
  thor (~> 0.20)
8
9
 
9
10
  GEM
10
11
  remote: https://rubygems.org/
11
12
  specs:
12
13
  ast (2.4.0)
13
- concurrent-ruby (1.1.5)
14
+ concurrent-ruby (1.1.6)
14
15
  diff-lcs (1.3)
15
16
  dry-configurable (0.9.0)
16
17
  concurrent-ruby (~> 1.0)
@@ -22,16 +23,16 @@ GEM
22
23
  concurrent-ruby (~> 1.0)
23
24
  dry-equalizer (0.3.0)
24
25
  dry-inflector (0.2.0)
25
- dry-logic (1.0.5)
26
+ dry-logic (1.0.6)
26
27
  concurrent-ruby (~> 1.0)
27
28
  dry-core (~> 0.2)
28
29
  dry-equalizer (~> 0.2)
29
- dry-struct (1.2.0)
30
- dry-core (~> 0.4, >= 0.4.3)
30
+ dry-struct (1.3.0)
31
+ dry-core (~> 0.4, >= 0.4.4)
31
32
  dry-equalizer (~> 0.3)
32
- dry-types (~> 1.0)
33
+ dry-types (~> 1.3)
33
34
  ice_nine (~> 0.11)
34
- dry-types (1.2.2)
35
+ dry-types (1.3.0)
35
36
  concurrent-ruby (~> 1.0)
36
37
  dry-container (~> 0.3)
37
38
  dry-core (~> 0.4, >= 0.4.4)
@@ -3,6 +3,7 @@
3
3
  require "strum/serializer_class"
4
4
  require "dry/inflector"
5
5
  require "dry/struct"
6
+ require "sequel/model"
6
7
 
7
8
  module Strum
8
9
  module JsonSerializer
@@ -34,7 +35,7 @@ module Strum
34
35
  end
35
36
 
36
37
  def self.call(model, **options)
37
- const_get(model.class.name, false).call(options.merge(model: model))
38
+ const_get(model.class.name.split("::").last, false).call(options.merge(model: model))
38
39
  end
39
40
  end
40
41
  end
@@ -3,6 +3,14 @@
3
3
  threads 4, 16
4
4
  workers ENV.fetch("PUMA_WORKERS", 4)
5
5
 
6
+ before_fork do
7
+ <% if sequel? -%>
8
+ DB.disconnect
9
+ <% end -%>
10
+ end
11
+
12
+
13
+ end
6
14
  on_worker_boot do
7
15
  # initialize worker variables
8
16
  # rabbit connection, as example
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Strum
4
- VERSION = "0.0.46"
4
+ VERSION = "0.0.47"
5
5
  end
@@ -37,6 +37,7 @@ Gem::Specification.new do |spec|
37
37
 
38
38
  spec.add_dependency "dry-inflector", "~> 0.2.0"
39
39
  spec.add_dependency "dry-struct", "~> 1.2"
40
+ spec.add_dependency "sequel", "~> 5.29"
40
41
  spec.add_dependency "thor", "~> 0.20"
41
42
  spec.add_development_dependency "bundler", "~> 1.17"
42
43
  spec.add_development_dependency "irb"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: strum
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.46
4
+ version: 0.0.47
5
5
  platform: ruby
6
6
  authors:
7
7
  - Serhiy Nazarov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-02-10 00:00:00.000000000 Z
11
+ date: 2020-02-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: dry-inflector
@@ -38,6 +38,20 @@ dependencies:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
40
  version: '1.2'
41
+ - !ruby/object:Gem::Dependency
42
+ name: sequel
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '5.29'
48
+ type: :runtime
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '5.29'
41
55
  - !ruby/object:Gem::Dependency
42
56
  name: thor
43
57
  requirement: !ruby/object:Gem::Requirement
@@ -190,7 +204,7 @@ files:
190
204
  - lib/strum/templates/app/blank/config.ru.tt
191
205
  - lib/strum/templates/app/blank/config/app.rb.tt
192
206
  - lib/strum/templates/app/blank/config/env.rb
193
- - lib/strum/templates/app/blank/config/puma.rb
207
+ - lib/strum/templates/app/blank/config/puma.rb.tt
194
208
  - lib/strum/templates/app/blank/lib/.keep
195
209
  - lib/strum/templates/app/blank/routes/.keep
196
210
  - lib/strum/templates/app/blank/services/.keep