bpm_manager 1.0.29 → 1.0.30
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/bpm_manager/red_hat.rb +6 -2
- data/lib/bpm_manager/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 397dfcfaf984c432d8b6c0cdc70d461591d40ed5
|
4
|
+
data.tar.gz: 578199a91e5ed92c56c6f53a81794118d0f49434
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 167f04cb06f092b19f12d887aa3216e52e7b2697863265be1ceffbcdca1750f2e0b8e95397580ab39e81532ee1c912393e7b1a1d40e31bd38d891373d53a3d09
|
7
|
+
data.tar.gz: 0df001449e6c4605e23ba8aded532afa9a3771f75eb8b852c065ad00f45cc1ccd0b80a48f33489133ccd25297032c59a525db88108fbe3da62648b679d323383
|
data/lib/bpm_manager/red_hat.rb
CHANGED
@@ -204,6 +204,8 @@ module BpmManager
|
|
204
204
|
|
205
205
|
# Private class methods
|
206
206
|
def self.calculate_sla(start_time, end_time = Time.now, sla_hours = 0.0, offset = 20)
|
207
|
+
logger.info '---> End_time: ' + end_time.to_s
|
208
|
+
|
207
209
|
hours = sla_hours.to_f * 3600 # Converts to seconds and calculates warning offset
|
208
210
|
warn = start_time.utc + hours * ((100.0 - offset) / 100)
|
209
211
|
total = start_time.utc + hours
|
@@ -211,9 +213,11 @@ module BpmManager
|
|
211
213
|
# Returns the status
|
212
214
|
end_time.utc <= warn ? 0 : ( warn < end_time.utc && end_time.utc <= total ? 1 : 2 )
|
213
215
|
end
|
214
|
-
private_class_method :calculate_sla
|
216
|
+
#private_class_method :calculate_sla
|
215
217
|
|
216
218
|
def self.calculate_sla_percent(start_time, end_time = Time.now, sla_hours = 0.0, offset = 20)
|
219
|
+
logger.info '---> End_time: ' + end_time.to_s
|
220
|
+
|
217
221
|
sla_hours = sla_hours * 3600.0 # converts to seconds
|
218
222
|
offset_pcg = (100.0 - offset) / 100.0
|
219
223
|
percent = OpenStruct.new
|
@@ -243,7 +247,7 @@ module BpmManager
|
|
243
247
|
|
244
248
|
return percent
|
245
249
|
end
|
246
|
-
private_class_method :calculate_sla_percent
|
250
|
+
#private_class_method :calculate_sla_percent
|
247
251
|
|
248
252
|
private
|
249
253
|
def self.structure_task_data(input)
|
data/lib/bpm_manager/version.rb
CHANGED