Method: Datadog::Core::Utils::Time.get_time

Defined in:
lib/datadog/core/utils/time.rb

.get_time(unit = :float_second) ⇒ Numeric

Current monotonic time

Parameters:

  • unit (Symbol) (defaults to: :float_second)

    unit for the resulting value, same as ::Process#clock_gettime, defaults to :float_second

Returns:

  • (Numeric)

    timestamp in the requested unit, since some unspecified starting point



14
15
16
# File 'lib/datadog/core/utils/time.rb', line 14

def get_time(unit = :float_second)
  Process.clock_gettime(Process::CLOCK_MONOTONIC, unit)
end