waterdrop 0.1.12 → 0.1.13

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: eaaa93109e4512ca5227b24d5d07b440c5abca97
4
- data.tar.gz: f6beefb7fccb3c5dd7a0bbacfc6aa949fd8a215b
3
+ metadata.gz: 47faf12d9fbcb7cebc0b764ecace5eb3de8bb0c1
4
+ data.tar.gz: 2bd185c502c8b3103c900c116dc0f0534fcd4ba9
5
5
  SHA512:
6
- metadata.gz: e6bfa48ad2e2de05ab0ab93afcd3583634d83b050f11fa850cab0b574614fab67c86a66f4436df9a5ee75f62337f49c3557e16860b8b9ca639a83e433837c4d0
7
- data.tar.gz: 979a187dd49c9ac2993d67b59349a0c7131b3aa96bd2563595ff78f8e1cc9634b734c84437e0478f9d541e79e91a26c6a451446e0f6a950fcffb25cfb8bfed9d
6
+ metadata.gz: d42b8147179daf3c6b767334ffee0f46ed30d852c74a6b85e7e8af36fe8b4802c34f57d046dada12ce0786fe697ca7b075ece78c9439bd2162933b9c71a83bf3
7
+ data.tar.gz: a2ec57ba800cf3fc8f8bc7c2e48b5287b4c198b7e82d72efa6655403366f15d94c61754dbeece5eb1a4e86dc255be40eef233000f7d4d1038d8e50b94193220a
data/CHANGELOG.md CHANGED
@@ -1,5 +1,8 @@
1
1
  # WaterDrop changelog
2
2
 
3
+ ## 0.1.13
4
+ - Resolved bug #15. When you use waterdrop in aspect way, message will be automatically parse to JSON.
5
+
3
6
  ## 0.1.12
4
7
  - Removed default to_json casting because of binary/other data types incompatibility. This is an incompatibility. If you use WaterDrop, please add a proper casting method to places where you use it.
5
8
  - Gem dump
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- waterdrop (0.1.12)
4
+ waterdrop (0.1.13)
5
5
  aspector
6
6
  bundler
7
7
  connection_pool
@@ -33,20 +33,22 @@ GEM
33
33
  descendants_tracker (~> 0.0.4)
34
34
  ice_nine (~> 0.11.0)
35
35
  thread_safe (~> 0.3, >= 0.3.1)
36
- brakeman (3.1.2)
36
+ brakeman (3.1.3)
37
37
  erubis (~> 2.6)
38
38
  fastercsv (~> 1.5)
39
39
  haml (>= 3.0, < 5.0)
40
- highline (~> 1.6)
40
+ highline (>= 1.6.20, < 2.0)
41
41
  multi_json (~> 1.2)
42
42
  ruby2ruby (>= 2.1.1, < 2.3.0)
43
43
  ruby_parser (~> 3.7.0)
44
- safe_yaml
44
+ safe_yaml (>= 1.0)
45
45
  sass (~> 3.0)
46
46
  slim (>= 1.3.6, < 4.0)
47
47
  terminal-table (~> 1.4)
48
- bson (3.2.6)
48
+ bson (4.0.0)
49
49
  builder (3.2.2)
50
+ codeclimate-engine-rb (0.1.0)
51
+ virtus (~> 1.0)
50
52
  coderay (1.1.0)
51
53
  coercible (1.0.0)
52
54
  descendants_tracker (~> 0.0.1)
@@ -83,8 +85,8 @@ GEM
83
85
  thread_safe (~> 0.3, >= 0.3.1)
84
86
  method_source (0.8.2)
85
87
  minitest (5.8.3)
86
- mongo (2.1.2)
87
- bson (~> 3.0)
88
+ mongo (2.2.0)
89
+ bson (~> 4.0)
88
90
  mongoid (5.0.1)
89
91
  activemodel (~> 4.0)
90
92
  mongo (~> 2.1)
@@ -122,7 +124,8 @@ GEM
122
124
  slop (~> 3.4)
123
125
  rainbow (2.0.0)
124
126
  rake (10.4.2)
125
- reek (3.6.0)
127
+ reek (3.7.1)
128
+ codeclimate-engine-rb (~> 0.1.0)
126
129
  parser (~> 2.2, >= 2.2.2.5)
127
130
  private_attr (~> 1.1)
128
131
  rainbow (~> 2.0)
@@ -153,14 +156,14 @@ GEM
153
156
  sexp_processor (~> 4.0)
154
157
  ruby_parser (3.7.2)
155
158
  sexp_processor (~> 4.1)
156
- rubycritic (2.2.0)
159
+ rubycritic (2.3.0)
157
160
  flay (= 2.6.1)
158
161
  flog (= 4.3.2)
159
162
  parser (>= 2.2.0, < 3.0)
160
- reek (= 3.6.0)
163
+ reek (= 3.7.1)
161
164
  virtus (~> 1.0)
162
165
  safe_yaml (1.0.4)
163
- sass (3.4.19)
166
+ sass (3.4.20)
164
167
  sexp_processor (4.6.0)
165
168
  shoulda (3.5.0)
166
169
  shoulda-context (~> 1.0, >= 1.0.1)
@@ -168,7 +171,7 @@ GEM
168
171
  shoulda-context (1.2.1)
169
172
  shoulda-matchers (2.8.0)
170
173
  activesupport (>= 3.0.0)
171
- simplecov (0.10.0)
174
+ simplecov (0.11.1)
172
175
  docile (~> 1.1.0)
173
176
  json (~> 1.8)
174
177
  simplecov-html (~> 0.10.0)
data/README.md CHANGED
@@ -92,6 +92,7 @@ All the WaterDrop aspects accept following parameters:
92
92
 
93
93
  There also a *message*, *after_message* and *before_message* proc parameter that will be evaluated in the methods object context.
94
94
 
95
+ **Note**: If you use waterdrop in aspect way, the message will be parsed to JSON as default. If you want to change this behaviour, you must override WaterDrop::Aspects::Formatter class.
95
96
  #### Before aspects hookup
96
97
 
97
98
  ```ruby
@@ -11,14 +11,14 @@ module WaterDrop
11
11
  @result = result
12
12
  end
13
13
 
14
- # @return [Hash] hash with formatted message that can be send
14
+ # @return [JSON] with formatted message that can be send
15
15
  def message
16
16
  {
17
17
  topic: @options[:topic],
18
18
  method: @options[:method],
19
19
  message: @result,
20
20
  args: @args
21
- }
21
+ }.to_json
22
22
  end
23
23
  end
24
24
  end
@@ -1,5 +1,5 @@
1
1
  # WaterDrop library
2
2
  module WaterDrop
3
3
  # Current WaterDrop version
4
- VERSION = '0.1.12'.freeze
4
+ VERSION = '0.1.13'.freeze
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: waterdrop
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.12
4
+ version: 0.1.13
5
5
  platform: ruby
6
6
  authors:
7
7
  - Maciej Mensfeld
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-11-26 00:00:00.000000000 Z
12
+ date: 2015-12-14 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler