logsformyfamily 0.2.1 → 0.3.0

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: dfaec509facf534d9217519cf942c917fd076d830fc5366103d426a9a879a399
4
- data.tar.gz: c5c65620f5549e91069859873818c29c7599c124d7ceeaa794cb556b0027be14
3
+ metadata.gz: 95868f1ec31e17276824034aa1221c678f1c2a3d2c5cbec5306dbbb044490b7f
4
+ data.tar.gz: c245935195974db8b8ee5fcaa229f2dd8255b9bc92b653f0cbcc2273319bdf25
5
5
  SHA512:
6
- metadata.gz: 21bfe3aa0e124ce2e6307d28d0797300bf7997d2cac9474f6bf9b262077501a6bb4a5d496609e30d2b7e665bdc25771f1bc81353aa5995f54cf17778145a48af
7
- data.tar.gz: 809d8c420eae2cf1b4a29099f8eb8ee9e2450bb5631c65dc0c0c3f03e918c2a8cc94ae39b3c8c84aee87408570d6cde1eb3fda917dd11b224bd43bbba7f42f0e
6
+ metadata.gz: 36fb44a112f25679139a570b07bf07736a3408d53d20d06a014529caa51b77cdae9ee6da6c70176fd0430bd25e68bd952ba6b72a69ea2930722a03c7c8b64ce8
7
+ data.tar.gz: 00c91549ebd6edbd6d8442335d72f25910990431ffc222b5c16d0bc8c8c2a998a43bd530b9b635912876d960b3cb13eccba9862ea288d8c97039bd1345b95014
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- logsformyfamily (0.2.1)
4
+ logsformyfamily (0.2.3)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -22,9 +22,9 @@ module LogsForMyFamily
22
22
  @backends = LogsForMyFamily.configuration.backends
23
23
  @configuration = LogsForMyFamily.configuration.to_h
24
24
  @request_id = LogsForMyFamily.configuration.request_id
25
+ filter_level(LogsForMyFamily.configuration.level)
25
26
  @request_config = {}
26
27
  @event_id = 0
27
- @filter_level = 0
28
28
  @filter_percent = 1.0
29
29
  @filter_percent_on = nil
30
30
  @filter_percent_below_level = 0
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module LogsForMyFamily
4
- VERSION = '0.2.1'
4
+ VERSION = '0.3.0'
5
5
  end
@@ -31,14 +31,20 @@ module LogsForMyFamily
31
31
  end
32
32
 
33
33
  class Configuration
34
- attr_accessor :version, :hostname, :app_name, :backends, :request_id
34
+ attr_accessor :version, :hostname, :app_name, :backends, :request_id, :level
35
35
 
36
36
  def initialize
37
- @version = `git rev-parse --short HEAD`.chomp
37
+ @version =
38
+ begin
39
+ `git rev-parse --short HEAD`.chomp
40
+ rescue Errno::ENOENT
41
+ ''
42
+ end
38
43
  @hostname = `hostname`.strip
39
44
  @app_name = ENV['NEWRELIC_APP']
40
45
  @backends = []
41
46
  @request_id = proc { |env| env['core_app.request_id'] }
47
+ @level = :debug
42
48
  end
43
49
 
44
50
  def to_h
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: logsformyfamily
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pat Wilson
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-11-11 00:00:00.000000000 Z
11
+ date: 2022-02-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gem-release