Dynatrace Custom Metrics Additional Resources - department-of-veterans-affairs/caseflow GitHub Wiki
Dynatrace Custom Metrics Additional Resources
Open Telemetry Official page
Open Telemetry Official Ruby Github repo
https://github.com/open-telemetry/opentelemetry-ruby/
Example of Custom Metrics implemented in ruby provided:
def create_counter(name, unit: nil, description: nil)
create_instrument(:counter, name, unit, description, nil) { COUNTER }
end
def create_histogram(name, unit: nil, description: nil)
create_instrument(:histogram, name, unit, description, nil) { HISTOGRAM }
end
def create_up_down_counter(name, unit: nil, description: nil)
create_instrument(:up_down_counter, name, unit, description, nil) { UP_DOWN_COUNTER }
end
def create_observable_counter(name, callback:, unit: nil, description: nil)
create_instrument(:observable_counter, name, unit, description, callback) { OBSERVABLE_COUNTER }
end
def create_observable_gauge(name, callback:, unit: nil, description: nil)
create_instrument(:observable_gauge, name, unit, description, callback) { OBSERVABLE_GAUGE }
end
def create_observable_up_down_counter(name, callback:, unit: nil, description: nil)
create_instrument(:observable_up_down_counter, name, unit, description, callback) { OBSERVABLE_UP_DOWN_COUNTER }
end
Instrument your Ruby application with OpenTelemetry
https://www.dynatrace.com/support/help/extend-dynatrace/opentelemetry/walkthroughs/ruby
Verify data ingestion into Dynatrace
https://www.dynatrace.com/support/help/extend-dynatrace/opentelemetry/walkthroughs/ruby#verify