cf_light_api 1.6.5 → 1.6.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/cf_light_api/worker.rb +13 -8
- 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: 67e83e63e7e82401f140877f22ae9b067eb3aa6c
|
4
|
+
data.tar.gz: 0db83bdbdb75b7945751553101c8fb8fc3e61cc2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3eb96485acac92733e80b92d8cdc787ae9e6e77e7b9d1e976e8db4db1b94e5cce8b40c596ef15c4a110591eebce44689702805ec681ef0a608bcf1311ba37aab
|
7
|
+
data.tar.gz: 8c89cabe199701849ed56c045747892eb577090a0bbf62b607f12b0fedce9f167d64c98fc06f0ab9d996c2f29db9afadc01fa5912e9c65057337ed498a13af4b
|
data/lib/cf_light_api/worker.rb
CHANGED
@@ -5,6 +5,7 @@ require 'parallel'
|
|
5
5
|
require 'redlock'
|
6
6
|
require 'logger'
|
7
7
|
require 'graphite-api'
|
8
|
+
require 'time'
|
8
9
|
|
9
10
|
@logger = Logger.new(STDOUT)
|
10
11
|
@logger.formatter = proc do |severity, datetime, progname, msg|
|
@@ -127,15 +128,19 @@ def get_org_data(cf_client)
|
|
127
128
|
end
|
128
129
|
|
129
130
|
def format_app_data(app, org_name, space_name)
|
131
|
+
|
132
|
+
last_uploaded = DateTime.parse app.manifest[:entity][:package_updated_at]
|
133
|
+
|
130
134
|
base_data = {
|
131
|
-
:guid
|
132
|
-
:name
|
133
|
-
:org
|
134
|
-
:space
|
135
|
-
:stack
|
136
|
-
:buildpack
|
137
|
-
:routes
|
138
|
-
:data_from
|
135
|
+
:guid => app.guid,
|
136
|
+
:name => app.name,
|
137
|
+
:org => org_name,
|
138
|
+
:space => space_name,
|
139
|
+
:stack => app.stack.name,
|
140
|
+
:buildpack => app.buildpack,
|
141
|
+
:routes => app.routes.map {|route| route.name},
|
142
|
+
:data_from => Time.now.to_i,
|
143
|
+
:last_uploaded => last_uploaded.strftime('%Y-%m-%d %T %z')
|
139
144
|
}
|
140
145
|
|
141
146
|
additional_data = {}
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cf_light_api
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.6.
|
4
|
+
version: 1.6.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Springer Platform Engineering
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-02-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: cfoundry
|