Skip to content

Commit

Permalink
Ensure isolation_level is set. (#219)
Browse files Browse the repository at this point in the history
  • Loading branch information
ioquatix authored Jan 31, 2024
1 parent 8134b76 commit 112b7a7
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/falcon.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,6 @@
# Copyright, 2017-2023, by Samuel Williams.

require_relative "falcon/server"

# Falcon, running on Rails, requires specific configuration:
require_relative "falcon/railtie" if defined?(Rails::Railtie)
7 changes: 7 additions & 0 deletions lib/falcon/railtie.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# frozen_string_literal: true

module Falcon
class Railtie < Rails::Railtie
config.active_support.isolation_level = :fiber
end
end

0 comments on commit 112b7a7

Please sign in to comment.