Skip to content

Commit

Permalink
FFS-2175: Installing skylight on dev (#397)
Browse files Browse the repository at this point in the history
Co-authored-by: Tom Dooner <[email protected]>
  • Loading branch information
George Byers and tdooner authored Dec 16, 2024
1 parent 202a6cb commit 66a6949
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 0 deletions.
1 change: 1 addition & 0 deletions app/Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ gem "stackprof"
gem "rexml", "~> 3.3.9"
gem "gpgme", "~> 2.0", ">= 2.0.12"
gem "pdf-reader", "~> 2.12.0"
gem "skylight"

group :development, :test do
gem "brakeman", "~> 5.2"
Expand Down
3 changes: 3 additions & 0 deletions app/Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -449,6 +449,8 @@ GEM
connection_pool (>= 2.2.5, < 3)
rack (~> 2.0)
redis (>= 4.5.0, < 5)
skylight (6.0.4)
activesupport (>= 5.2.0)
smart_properties (1.17.0)
snaky_hash (2.0.1)
hashie
Expand Down Expand Up @@ -570,6 +572,7 @@ DEPENDENCIES
rubocop-rspec
selenium-webdriver
sidekiq (~> 6.4)
skylight
sprockets-rails
stackprof
standard (~> 1.7)
Expand Down
15 changes: 15 additions & 0 deletions app/config/initializers/newrelic_method_tracers.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
require "new_relic/agent/method_tracer"

Rails.application.config.to_prepare do
# Add custom metric tracking for a few possibly slow endpoints
NewRelicEventTracker.class_eval do
class << self
add_method_tracer :track, "Custom/NewRelicEventTracker/track"
end
end

Cbv::BaseController.class_eval do
add_method_tracer :set_cbv_flow
add_method_tracer :capture_page_view
end
end

0 comments on commit 66a6949

Please sign in to comment.