MCPcopy Create free account
hub / github.com/StackStorm/st2 / send_time

Method send_time

st2common/st2common/metrics/base.py:184–194  ·  view source on GitHub ↗

Send current time from start time.

(self, key=None)

Source from the content-addressed store, hash-verified

182 self._start_time = None
183
184 def send_time(self, key=None):
185 """
186 Send current time from start time.
187 """
188 time_delta = self.get_time_delta()
189
190 if key:
191 check_key(key)
192 self._metrics.time(key, time_delta.total_seconds())
193 else:
194 self._metrics.time(self.key, time_delta.total_seconds())
195
196 def get_time_delta(self):
197 """

Callers 1

__exit__Method · 0.95

Calls 3

get_time_deltaMethod · 0.95
check_keyFunction · 0.90
timeMethod · 0.45

Tested by

no test coverage detected