presto-metrics 0.2.5 → 0.2.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/presto/metrics/version.rb +1 -1
- data/lib/presto/metrics.rb +5 -4
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c8592a3b20c830df773dd674d2788d97a1efcb2f
|
4
|
+
data.tar.gz: a52c98446f0a94b05802382aa89c41369521feb8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 77428d020bf697818cee9b087315dd75c02a7e65dd5ad1aed61b647c78477488eb674a4c626d9f0971c152f7c398d53b3f3f2278761935877766c831bd7f322e
|
7
|
+
data.tar.gz: b8229d7b34a91245292651408a40d62b050618cd7c0f2eb8260abcc3d564c4b5d4ec09c06f4b2c6c1cd86b495482338fd2138c9c5d359c4144d287abc65243a8
|
data/lib/presto/metrics.rb
CHANGED
@@ -31,7 +31,8 @@ module Presto
|
|
31
31
|
end
|
32
32
|
|
33
33
|
def metrics
|
34
|
-
query_list
|
34
|
+
ql = query_list
|
35
|
+
ql.map{|qi|
|
35
36
|
h = {}
|
36
37
|
h['query_id'] = qi['queryId'] || ""
|
37
38
|
h['state'] = qi['state'] || ""
|
@@ -45,9 +46,9 @@ module Presto
|
|
45
46
|
h['elapsed_time'] = qi['elapsedTime'] || "0.0m"
|
46
47
|
h['create_time'] = qi['createTime']
|
47
48
|
h['running_time'] = qi['endTime'] || Time.now.utc.iso8601(3)
|
48
|
-
if(h['state'] == "FAILED")
|
49
|
-
|
50
|
-
end
|
49
|
+
#if(h['state'] == "FAILED")
|
50
|
+
# h['errorCode'] = find(h['query_id'])['errorCode'] || {}
|
51
|
+
#end
|
51
52
|
h
|
52
53
|
}
|
53
54
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: presto-metrics
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Taro L. Saito
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-09-
|
11
|
+
date: 2014-09-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|