Skip to content

Commit a15e887

Browse files
committed
Fixed telemetry last sync timestamp
1 parent dca98b7 commit a15e887

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

splitio/api/commons.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
"""Commons module."""
2-
2+
import time
33

44
_CACHE_CONTROL = 'Cache-Control'
55
_CACHE_CONTROL_NO_CACHE = 'no-cache'
@@ -50,7 +50,7 @@ def record_telemetry(status_code, elapsed, metric_name, telemetry_runtime_produc
5050
"""
5151
telemetry_runtime_producer.record_sync_latency(metric_name, elapsed)
5252
if 200 <= status_code < 300:
53-
telemetry_runtime_producer.record_suceessful_sync(metric_name, elapsed)
53+
telemetry_runtime_producer.record_suceessful_sync(metric_name, int(round(time.time() * 1000)))
5454
else:
5555
telemetry_runtime_producer.record_sync_error(metric_name, status_code)
5656

0 commit comments

Comments
 (0)