remove obsolete file

This commit is contained in:
Konstantin Haase 2015-01-14 13:43:55 +01:00
parent ea4a1c5bc4
commit 690c598205
2 changed files with 0 additions and 51 deletions

View File

@ -20,7 +20,6 @@ require 'metriks/librato_metrics_reporter'
require 'travis/support/log_subscriber/active_record_metrics'
require 'fileutils'
require 'travis/api/v2/http'
require 'travis/api/conditional_skylight'
# Rack class implementing the HTTP API.
# Instances respond to #call.

View File

@ -1,50 +0,0 @@
# if ENV['SKYLIGHT_AUTHENTICATION']
#
# # require 'skylight/sinatra'
# # require 'tool/thread_local'
# # Skylight.start!
# #
# # module Travis
# # module Api
# # module ConditionalSkylight
# # FEATURES = Tool::ThreadLocal.new
# # CHECK_FREQUENCY = 120
# # NOT_JSON = %r(\.(xml|png|txt|atom|svg)$)
# #
# # module Middleware
# # ::Skylight::Middleware.send(:prepend, self)
# # def call(env)
# # if ConditionalSkylight.track?(env)
# # super(env)
# # else
# # t { "skipping middleware (condition not met)".freeze }
# # @app.call(env)
# # end
# # end
# # end
# #
# # extend self
# #
# # def track?(env)
# # return false unless feature_active? :skylight
# # return false if feature_active? :skylight_json_only and env['PATH_INFO'.freeze] =~ NOT_JSON
# # true
# # end
# #
# # def feature_active?(feature)
# # last_clear = Time.now.to_i - FEATURES[:last_clear].to_i
# #
# # if last_clear > CHECK_FREQUENCY
# # FEATURES.clear
# # FEATURES[:last_clear] = Time.now.to_i
# # end
# #
# # FEATURES.fetch(feature) { FEATURES[feature] = Travis::Features.feature_active?(feature) }
# # end
# # end
# # end
# # end
#
# else
# Travis.logger.info('SKYLIGHT_AUTHENTICATION not set, skipping Skylight.')
# end