diff --git a/Gemfile.lock b/Gemfile.lock index e9d89868..af003d6b 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -91,7 +91,6 @@ PATH travis-api (0.0.1) backports (~> 2.5) hubble (~> 0.1) - newrelic_rpm (~> 3.5.5.0) pg (~> 0.13.2) rack-contrib (~> 1.1) rack-ssl (~> 1.3, >= 1.3.3) @@ -185,7 +184,6 @@ GEM multipart-post (1.1.5) net-http-persistent (2.8) net-http-pipeline (1.0.1) - newrelic_rpm (3.5.5.38) pg (0.13.2) polyglot (0.3.3) postmark (0.9.18) diff --git a/config.ru b/config.ru index a570b9e2..8fb5947a 100644 --- a/config.ru +++ b/config.ru @@ -8,9 +8,11 @@ require 'travis/api/app' require 'core_ext/module/load_constants' models = Travis::Model.constants.map(&:to_s) -only = [/^(ActiveRecord|ActiveModel|Travis|GH|#{models.join('|')})/] +only = [/^(ActiveRecord|ActiveModel|Travis|GH|#{models.join('|')})/] +skip = ['Travis::Memory', 'GH::ResponseWrapper', 'Travis::NewRelic'] + [Travis::Api, Travis, GH].each do |target| - target.load_constants! :only => only, :skip => ['Travis::Memory', 'GH::ResponseWrapper'], :debug => false + target.load_constants! :only => only, :skip => skip, :debug => false end run Travis::Api::App.new diff --git a/lib/travis/api/app/base.rb b/lib/travis/api/app/base.rb index 92031836..a100398a 100644 --- a/lib/travis/api/app/base.rb +++ b/lib/travis/api/app/base.rb @@ -1,6 +1,6 @@ require 'travis/api/app' require 'sinatra/base' -require 'new_relic/agent/instrumentation/rack' +#require 'new_relic/agent/instrumentation/rack' class Travis::Api::App # Superclass for any endpoint and middleware. @@ -8,9 +8,9 @@ class Travis::Api::App class Base < Sinatra::Base register Extensions::SmartConstants - configure :production do - require 'newrelic_rpm' - end + # configure :production do + # require 'newrelic_rpm' + # end error NotImplementedError do content_type :txt diff --git a/travis-api.gemspec b/travis-api.gemspec index a4b7755b..6c2ffd10 100644 --- a/travis-api.gemspec +++ b/travis-api.gemspec @@ -166,7 +166,7 @@ Gem::Specification.new do |s| s.add_dependency 'hubble', '~> 0.1' s.add_dependency 'backports', '~> 2.5' s.add_dependency 'pg', '~> 0.13.2' - s.add_dependency 'newrelic_rpm', '~> 3.5.5.0' + #s.add_dependency 'newrelic_rpm', '~> 3.5.5.0' s.add_dependency 'thin', '~> 1.4' s.add_dependency 'sinatra', '~> 1.3' s.add_dependency 'sinatra-contrib', '~> 1.3'