scout_apm 1.5.1 → 1.5.2
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 63d6bfdf9e557d66a065ff10e5572f7216fa5313
|
4
|
+
data.tar.gz: 8985462f9fe11d8f0c9b1a7e754754b404e1ac72
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5096255086114087eb5ebe349ca32de5fee8ab1c17348bb2cdaa79a6e1307cc7f87cd48e0c1dd136c9b5cbe6943d37c8b7afc0231ecf0b73c4f4d38c3211c72e
|
7
|
+
data.tar.gz: 830663da6a9c1e1a549ae91c89bcb5d78badb9e44b341c30ec9849fc1d94b40ae32003e1b25095974a9128c08cd90b880f10ce74936be1367ba980d089ee20ca
|
data/CHANGELOG.markdown
CHANGED
@@ -2,8 +2,32 @@
|
|
2
2
|
module ScoutApm
|
3
3
|
class LayawayFile
|
4
4
|
def path
|
5
|
-
|
6
|
-
|
5
|
+
return @path if @path
|
6
|
+
|
7
|
+
candidates = [
|
8
|
+
ScoutApm::Agent.instance.config.value("data_file"),
|
9
|
+
"#{ScoutApm::Agent.instance.default_log_path}/scout_apm.db",
|
10
|
+
"#{ScoutApm::Agent.instance.environment.root}/tmp/scout_apm.db"
|
11
|
+
]
|
12
|
+
|
13
|
+
candidates.each do |candidate|
|
14
|
+
next if candidate.nil?
|
15
|
+
|
16
|
+
begin
|
17
|
+
ScoutApm::Agent.instance.logger.debug("Checking Layaway File Location: #{candidate}")
|
18
|
+
File.open(candidate, "w") { |f| } # Open & Close to check that we can
|
19
|
+
|
20
|
+
# No exception, it is valid
|
21
|
+
ScoutApm::Agent.instance.logger.info("Layaway File location found: #{candidate}")
|
22
|
+
@path = candidate
|
23
|
+
return @path
|
24
|
+
rescue Exception
|
25
|
+
ScoutApm::Agent.instance.logger.debug("Couldn't open layaway file for test write at #{candidate}")
|
26
|
+
end
|
27
|
+
end
|
28
|
+
|
29
|
+
ScoutApm::Agent.instance.logger.error("No valid layaway file found, please set a location in the configuration key `data_file`")
|
30
|
+
nil
|
7
31
|
end
|
8
32
|
|
9
33
|
def dump(object)
|
@@ -75,7 +75,7 @@ module ScoutApm
|
|
75
75
|
end
|
76
76
|
|
77
77
|
def scrubbed(str)
|
78
|
-
return '' if !str.is_a?(String) || str.length >
|
78
|
+
return '' if !str.is_a?(String) || str.length > 4000 # safeguard - don't sanitize or scrub large SQL statements
|
79
79
|
return str if !str.respond_to?(:encode) # Ruby <= 1.8 doesn't have string encoding
|
80
80
|
return str if str.valid_encoding? # Whatever encoding it is, it is valid and we can operate on it
|
81
81
|
ScoutApm::Agent.instance.logger.debug "Scrubbing invalid sql encoding."
|
data/lib/scout_apm/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: scout_apm
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.
|
4
|
+
version: 1.5.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Derek Haynes
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2016-05-
|
12
|
+
date: 2016-05-13 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: minitest
|