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.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/cf_light_api/worker.rb +13 -8
  3. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3cff6a981946b0f933ecf05e61e1b27d710eb286
4
- data.tar.gz: 53dec5c12b6a40f5959cb8f419a3e2877f95a137
3
+ metadata.gz: 67e83e63e7e82401f140877f22ae9b067eb3aa6c
4
+ data.tar.gz: 0db83bdbdb75b7945751553101c8fb8fc3e61cc2
5
5
  SHA512:
6
- metadata.gz: 7ee0a4a4f89bef83e18792ad2ff1d9b0967599b6eea911a56a4b91dea9014c9cff9eeb5953965583b61f732fb2647a5c1d8d27e6701da654f6bc6bfaf13d9c0e
7
- data.tar.gz: 398b8eb74e2e2888aab12197a2eb66b1dcf218de3f5053b08c79181da1cffdbd67223e8e9e103a77db30ddf2db13fdfd98b0d65fcbeb2b65954d95c82f6daf81
6
+ metadata.gz: 3eb96485acac92733e80b92d8cdc787ae9e6e77e7b9d1e976e8db4db1b94e5cce8b40c596ef15c4a110591eebce44689702805ec681ef0a608bcf1311ba37aab
7
+ data.tar.gz: 8c89cabe199701849ed56c045747892eb577090a0bbf62b607f12b0fedce9f167d64c98fc06f0ab9d996c2f29db9afadc01fa5912e9c65057337ed498a13af4b
@@ -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 => app.guid,
132
- :name => app.name,
133
- :org => org_name,
134
- :space => space_name,
135
- :stack => app.stack.name,
136
- :buildpack => app.buildpack,
137
- :routes => app.routes.map {|route| route.name},
138
- :data_from => Time.now.to_i,
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.5
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-01-08 00:00:00.000000000 Z
11
+ date: 2016-02-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: cfoundry