Sha256: 95813b3333f9191dfdc5105d37a39e5a9d51f38eac3ab8d461930261822d6437

Contents?: true

Size: 982 Bytes

Versions: 6

Compression:

Stored size: 982 Bytes

Contents

# frozen_string_literal: true

# Copyright The OpenTelemetry Authors
#
# SPDX-License-Identifier: Apache-2.0

require "rubygems"
require "bundler/setup"
Bundler.require :default

require "action_controller/railtie"

# TraceRequestApp is a minimal Rails application inspired by the Rails
# bug report template for action controller.
# https://github.com/rails/rails/blob/v6.0.0/guides/bug_report_templates/action_controller_gem.rb
# The configuration is compatible with Rails 6.0
class TraceRequestApp < Rails::Application
  config.root = __dir__
  config.hosts << "example.org"
  secrets.secret_key_base = "secret_key_base"
  config.eager_load = false

  config.logger = Logger.new($stdout)
  Rails.logger  = config.logger
end

Rails.application.initialize!

run Rails.application

# To run this example run the `rackup` command with this file
# Example: rackup trace_request_demonstration.ru
# Navigate to http://localhost:9292/
# Spans for the requests will appear in the console

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
splunk-otel-1.3.0 examples/rails-7-barebones/app.ru
splunk-otel-1.1.3 examples/rails-7-barebones/app.ru
splunk-otel-1.1.0 examples/rails-7-barebones/app.ru
splunk-otel-1.0.0 examples/rails-7-barebones/app.ru
splunk-otel-0.2.0 examples/rails-7-barebones/app.ru
splunk-otel-0.1.0 examples/rails-7-barebones/app.ru