outland-tag_runes 1.1.2 → 1.1.3

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
  SHA1:
3
- metadata.gz: 445843596fa7825809378ffc0413530091692528
4
- data.tar.gz: 6aa7134714808f1d86f603773c4167edb384ff4a
3
+ metadata.gz: 4db0b3df4e6492c651345a1042a3585da16a44b8
4
+ data.tar.gz: 0432d144b908ae4dff106cdd3725db6b11705009
5
5
  SHA512:
6
- metadata.gz: e6840bf35574815f70288456f6d7f55d38ac30d83cce661078bdf87ac0406b8f710b9a4532717386e4fb1a836baeb87d0990fad153345d35589fe2fecd91987b
7
- data.tar.gz: 556f493fe7525a03fa85a321161fbae36b9b7bddcc357a58241d53d68a4d0c0dec80b06a6f3ed10f2df7bda470071c8d4419dd7a3ef4a43cb0a5768363623550
6
+ metadata.gz: a1ed8f18b2c1f9138b00359526a2dc10ed4667b125e309ce322e9dff4265f7f89dda85a89828777d9121dd9afedc902b36d2b1dc2190ac8d6a5029bace4c14f1
7
+ data.tar.gz: 7510c7066b7a87804c9001540340efb9fa676acb129428fa58230e56b6bab432c64f5353788caeb065c6ca06c12e71a9f94438ad56f3116a6f1aa381ba009b5c
data/CHANGELOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ **1.1.3** (March 5, 2017)
2
+
3
+ * More robust method of space-separating requests in non-development environments.
4
+
1
5
  **1.1.2** (February 27, 2017)
2
6
 
3
7
  * Same linefeeds in deployed environments as in development.
@@ -1,7 +1,7 @@
1
1
  module Outland
2
2
  module TagRunes
3
3
 
4
- VERSION = "1.1.2"
4
+ VERSION = "1.1.3"
5
5
 
6
6
  end
7
7
  end
@@ -52,8 +52,15 @@ module TagRunes
52
52
  # ensure tags appear on each line of a multiline log statement.
53
53
  module MultilineFormatter
54
54
 
55
+ # Completed 200 OK in 244ms (Views: 78.9ms | ActiveRecord: 52.1ms)
56
+ COMPLETED_RE = /\ACompleted \d\d\d \w/
57
+
55
58
  def call(severity, timestamp, progname, msg)
56
- if msg && msg.index("\n")
59
+ if msg && COMPLETED_RE.match(msg) && !Rails.env.development?
60
+ # keep requests separated when deployed for sanity's sake
61
+ [super, super(severity, timestamp, progname, '')].join
62
+ elsif msg && msg.index("\n")
63
+ # apply the tags to each line via the underlying log tagger
57
64
  msg.lines.map{|l| super(severity, timestamp, progname, l.chomp)}.join
58
65
  else
59
66
  super
@@ -66,16 +73,7 @@ module TagRunes
66
73
  # Hook Rails init process
67
74
  class Railtie < Rails::Railtie
68
75
  initializer 'outland-tag_runes' do |app|
69
-
70
76
  Rails.logger.formatter.extend MultilineFormatter
71
-
72
- # Keep requests separated when deployed for sanity's sake
73
- unless Rails.env.development?
74
- ActiveSupport::Notifications.subscribe('process_action.action_controller') do |_|
75
- Rails.logger.info "\n"
76
- end
77
- end
78
-
79
77
  end
80
78
  end
81
79
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: outland-tag_runes
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.2
4
+ version: 1.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bill Lipa
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-02-28 00:00:00.000000000 Z
11
+ date: 2017-03-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails