From 63d24caf10b2fc22f48264b45b824f04dc546491 Mon Sep 17 00:00:00 2001 From: Vladimir Dementyev Date: Mon, 3 Feb 2025 11:20:21 -0800 Subject: [PATCH] * updgrade deps (Rails 8, Next 0.2) --- .anycable-rails-revision | 1 - Gemfile | 2 +- bento | 2 +- lib/application.rb | 4 ++++ 4 files changed, 6 insertions(+), 3 deletions(-) delete mode 100644 .anycable-rails-revision diff --git a/.anycable-rails-revision b/.anycable-rails-revision deleted file mode 100644 index d1b440c..0000000 --- a/.anycable-rails-revision +++ /dev/null @@ -1 +0,0 @@ -https://github.com/anycable/anycable-rails.git#feat/actioncable-v8 diff --git a/Gemfile b/Gemfile index 865413c..ae71649 100644 --- a/Gemfile +++ b/Gemfile @@ -19,7 +19,7 @@ elsif File.file?(File.join(__dir__, ".rails-revision")) git, branch = *File.read(File.join(__dir__, ".rails-revision")).strip.split("#", 2) gem "rails", git:, branch: else - gem "rails", ENV.fetch("RAILS_VERSION", "~> 7.0") + gem "rails", ENV.fetch("RAILS_VERSION", "~> 8.0") end # Baseline setup: Puma + Redis pub/sub diff --git a/bento b/bento index f0d4868..b8d7da6 100755 --- a/bento +++ b/bento @@ -30,7 +30,7 @@ end.parse! require_relative "lib/application" -desc = defined?(ActionCableNext) ? "Action Cable Next #{ActionCableNext::VERSION} on Rails #{Rails::VERSION::STRING}" : "Action Cable #{Rails::VERSION::STRING}" +desc = defined?(ActionCableNext) ? "Action Cable Next #{ActionCableNext::VERSION} (fastlane broadcasts: #{ActionCable.server.config.fastlane_broadcasts_enabled}) on Rails #{Rails::VERSION::STRING}" : "Action Cable #{Rails::VERSION::STRING}" $stdout.puts "⚡️ Running #{desc} via #{$benchmark_server}" diff --git a/lib/application.rb b/lib/application.rb index 9aa7319..ad0f66d 100644 --- a/lib/application.rb +++ b/lib/application.rb @@ -35,6 +35,10 @@ class App < Rails::Application ActionCable.server.config.disable_request_forgery_protection = true ActionCable.server.config.logger = Rails.logger +if ENV["FASTLANE"] == "true" + ActionCable.server.config.fastlane_broadcasts_enabled = true +end + # Load server configuration require_relative "servers/#{$benchmark_server}" if defined?($benchmark_server)