Sha256: 0d28b415c983960172e263fd7667e88d444c32bfd85bea033053e5f0dba9d1c2

Contents?: true

Size: 592 Bytes

Versions: 46

Compression:

Stored size: 592 Bytes

Contents

# typed: false
# frozen_string_literal: true

class ApplicationController < ActionController::Base
  include ActionController::MimeResponds

  include Hephaestus::Responses

  rescue_from ActionController::UnknownFormat, with: :not_acceptable

  before_action :set_request_span_context
  def set_request_span_context
  end

  after_action :set_response_span_context
  def set_response_span_context
    OpenTelemetry::Trace.current_span.add_attributes({
      OpenTelemetry::SemanticConventions::Trace::HTTP_RESPONSE_CONTENT_LENGTH => response.headers["content-length"] || 0,
    })
  end
end

Version data entries

46 entries across 46 versions & 1 rubygems

Version Path
hephaestus-0.8.11 templates/app/controllers/application_controller.rb
hephaestus-0.8.10 templates/app/controllers/application_controller.rb
hephaestus-0.8.9.2 templates/app/controllers/application_controller.rb
hephaestus-0.8.9.1 templates/app/controllers/application_controller.rb
hephaestus-0.8.9 templates/app/controllers/application_controller.rb
hephaestus-0.8.8 templates/app/controllers/application_controller.rb
hephaestus-0.8.7.5 templates/app/controllers/application_controller.rb
hephaestus-0.8.7.4 templates/app/controllers/application_controller.rb
hephaestus-0.8.7.3 templates/app/controllers/application_controller.rb
hephaestus-0.8.7.2 templates/app/controllers/application_controller.rb
hephaestus-0.8.7.1 templates/app/controllers/application_controller.rb
hephaestus-0.8.7 templates/app/controllers/application_controller.rb
hephaestus-0.8.6 templates/app/controllers/application_controller.rb
hephaestus-0.8.5 templates/app/controllers/application_controller.rb
hephaestus-0.8.4.1 templates/app/controllers/application_controller.rb
hephaestus-0.8.4 templates/app/controllers/application_controller.rb
hephaestus-0.8.3.4 templates/app/controllers/application_controller.rb
hephaestus-0.8.3.3 templates/app/controllers/application_controller.rb
hephaestus-0.8.3.2 templates/app/controllers/application_controller.rb
hephaestus-0.8.3.1 templates/app/controllers/application_controller.rb