fluent-plugin-sentry-rubrik 0.0.11 → 0.0.12

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: 48596345eadcbfb3c799951352afdceeb7cd66bb
4
- data.tar.gz: edfdd67c375c82f605d87dd63beec6866db20f92
3
+ metadata.gz: ef870a39dc363601523e7f7a514d351706e4621e
4
+ data.tar.gz: 5b1c11fa9cfb4b0f019664029df18b70c50484fc
5
5
  SHA512:
6
- metadata.gz: b8122b0087738562cb48e3ee95db9a2b3e9c4da322b5609c7f489856dff6bec4fe26c6d8116d154fde9616504b16d81fb69f634223b31cedabf9ba9e84179fef
7
- data.tar.gz: 5bb56923822e1780d16547a9667abdf3a94805784dd7d1ce50574bc118024b29126dabcee4475473bbfdd012a4020ad97824f0d8dbf7533e0e12b45f8f017597
6
+ metadata.gz: f1b923555c5c7d899b52f5bb5e95b0fcf07ded1cb6515ac6d3bbfe7d1f28bcce3a937537bd681bcb5ad29b11f3522776b9606d6d54c72b1dc2fad4ac169090cb
7
+ data.tar.gz: 79c314e65964b2d7826d2ac01f55d0a792e65581968209b4b440c6af328e2a21a73bd17863c6f945d6ceacf915aa714e2816ee270d5cffecb4297452748c3689
data/README.md CHANGED
@@ -104,6 +104,16 @@ example, given the following log:
104
104
  ```
105
105
  The tag key `k8s.app` will add the tag `k8s.app: myapp` to the Sentry event.
106
106
 
107
+ * stacktrace_expand_json_escaping
108
+ [default] true
109
+
110
+ When going trough some JSON formatter stacktraces `\n` and `\t` characters are
111
+ often escaped. Meaning you will see `\n` instead of a visible line return for
112
+ example and `\t` instead of a visual tabulation.
113
+
114
+ When true (the default) this option will expand the escaped character into the
115
+ original control code. This important for successfully parsing stacktraces.
116
+
107
117
  It also support rewriting Tag with SetTagKeyMixin.
108
118
 
109
119
  * remove_tag_prefix
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
4
 
5
5
  Gem::Specification.new do |spec|
6
6
  spec.name = "fluent-plugin-sentry-rubrik"
7
- spec.version = "0.0.11"
7
+ spec.version = "0.0.12"
8
8
  spec.authors = ["Kentaro Yoshida", "François-Xavier Bourlet"]
9
9
  spec.email = ["y.ken.studio@gmail.com", "fx.bourlet@rubrik.com"]
10
10
  spec.summary = %q{Fluentd output plugin that sends aggregated errors/exception events to Sentry. Sentry is a event logging and aggregation platform.}
@@ -20,6 +20,7 @@ module Fluent
20
20
  config_param :endpoint_url, :string
21
21
  config_param :flush_interval, :time, :default => 0
22
22
  config_param :hostname_command, :string, :default => 'hostname'
23
+ config_param :stacktrace_expand_json_escaping, :bool, :default => true
23
24
 
24
25
  def configure(conf)
25
26
  super
@@ -94,6 +95,9 @@ module Fluent
94
95
 
95
96
  stacktrace = record['backtrace'] || record['stacktrace']
96
97
  if stacktrace
98
+ if @stacktrace_expand_json_escaping
99
+ stacktrace = stacktrace.gsub(/\\[nt]/, '\n' => "\n", '\t' => "\t")
100
+ end
97
101
  event.interface(:stacktrace) do |int|
98
102
  int.frames = event.stacktrace_interface_from(stacktrace)
99
103
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluent-plugin-sentry-rubrik
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.11
4
+ version: 0.0.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kentaro Yoshida