Skip to content

Commit b3d3181

Browse files
authored
Do not implicitly set up rack-timeout middleware
By requiring `rack-timeout`, `Rack::Timeout` is automatically added to the middleware of a Rails application. See https://github.com/heroku/rack-timeout#rails-apps This leads to unexpected behavior. When a user adds a non-standard `Rack-Timeout` to the middleware stack herself, she ends up with `Rack-Timeout` added twice. Worse, the configuration added automatically is the standard configuration which might differ from the one added manually in user land. Worst case comes to show when a user configures a `service_timeout` greater than the standard one.
1 parent 8e1a23a commit b3d3181

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/raven/integrations/rack-timeout.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# rubocop:disable Style/FileName
22
# We need to do this because of the way integration loading works
3-
require 'rack-timeout'
3+
require "rack/timeout/base"
44

55
# This integration is a good example of how to change how exceptions
66
# get grouped by Sentry's UI. Simply override #raven_context in

0 commit comments

Comments
 (0)