Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7022875
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T23:38:19+00:00 2026-05-27T23:38:19+00:00

I am using Rails 3.0.9. (With ruby 1.9.3) I have been looking into some

  • 0

I am using Rails 3.0.9. (With ruby 1.9.3)
I have been looking into some replication gems (data_fabric, octopus, multi_db).

Been wondering what is the best solution.
Production ready, fast, AR3 compatible…

I thought it was octopus till I saw this issue:
https://github.com/tchandy/octopus/issues/60

I don’t need sharding at this point, all I needs is the ability to send Reads to the slaves, and writes to the master.

What is the best solution for the above needs?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T23:38:20+00:00Added an answer on May 27, 2026 at 11:38 pm

    Octopus is still the one to pick, despite that issue. We use it at Square for the use case you describe.

    Commits to relax the dependency went in directly after v0.4.0, so it’s safe to lock to a git revision:

    gem 'octopus',
      :git => 'https://github.com/tchandy/octopus.git',
      :ref => '7e585ecd35d3caf9b5d23a0265e709716740a3ce'
    

    Other changes in master look mostly 3.1 and spec related, plus a single performance commit (my commit), so it’s probably fine also.

    For reference, we’re running a fork of v0.4.0 amended to allow AR 2.3, plus a performance related commit which is now on master (not critical if you’re not doing heaps of traffic, but nice.)

    git diff v0.4.0..7e585ecd35d3caf9b5d23a0265e709716740a3ce

    diff --git a/Gemfile b/Gemfile
    index e82375d..c3bcf77 100644
    --- a/Gemfile
    +++ b/Gemfile
    @@ -1,7 +1,7 @@
     source :rubygems
    
    -gem 'activerecord', '3.0.6'
    -gem 'actionpack', '3.0.6'
    +gem 'activerecord', '~> 3.0'
    +gem 'actionpack', '~> 3.0'
    
     group :test do
       gem "rake", ">= 0.8.7"
    diff --git a/Gemfile.lock b/Gemfile.lock
    index a80476c..a82c18f 100644
    --- a/Gemfile.lock
    +++ b/Gemfile.lock
    @@ -58,8 +58,8 @@ PLATFORMS
       ruby
    
     DEPENDENCIES
    -  actionpack (= 3.0.6)
    -  activerecord (= 3.0.6)
    +  actionpack (~> 3.0)
    +  activerecord (~> 3.0)
       jeweler (>= 1.4)
       mysql2
       pg (>= 0.9.0)
    diff --git a/ar-octopus.gemspec b/ar-octopus.gemspec
    index 9e5f73e..2b06df4 100644
    --- a/ar-octopus.gemspec
    +++ b/ar-octopus.gemspec
    @@ -171,8 +171,8 @@ Gem::Specification.new do |s|
         s.specification_version = 3
    
         if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
    -      s.add_runtime_dependency(%q<activerecord>, ["= 3.0.6"])
    -      s.add_runtime_dependency(%q<actionpack>, ["= 3.0.6"])
    +      s.add_runtime_dependency(%q<activerecord>, ["~> 3.0"])
    +      s.add_runtime_dependency(%q<actionpack>, ["~> 3.0"])
           s.add_development_dependency(%q<rspec>, [">= 2.0.0.beta.19"])
           s.add_development_dependency(%q<mysql2>, [">= 0"])
           s.add_development_dependency(%q<pg>, [">= 0.9.0"])
    @@ -181,8 +181,8 @@ Gem::Specification.new do |s|
           s.add_development_dependency(%q<actionpack>, [">= 2.3"])
           s.add_runtime_dependency(%q<activerecord>, [">= 2.3"])
         else
    -      s.add_dependency(%q<activerecord>, ["= 3.0.6"])
    -      s.add_dependency(%q<actionpack>, ["= 3.0.6"])
    +      s.add_dependency(%q<activerecord>, ["~> 3.0"])
    +      s.add_dependency(%q<actionpack>, ["~> 3.0"])
           s.add_dependency(%q<rspec>, [">= 2.0.0.beta.19"])
           s.add_dependency(%q<mysql2>, [">= 0"])
           s.add_dependency(%q<pg>, [">= 0.9.0"])
    @@ -192,8 +192,8 @@ Gem::Specification.new do |s|
           s.add_dependency(%q<activerecord>, [">= 2.3"])
         end
       else
    -    s.add_dependency(%q<activerecord>, ["= 3.0.6"])
    -    s.add_dependency(%q<actionpack>, ["= 3.0.6"])
    +    s.add_dependency(%q<activerecord>, ["~> 3.0"])
    +    s.add_dependency(%q<actionpack>, ["~> 3.0"])
         s.add_dependency(%q<rspec>, [">= 2.0.0.beta.19"])
         s.add_dependency(%q<mysql2>, [">= 0"])
         s.add_dependency(%q<pg>, [">= 0.9.0"])
    diff --git a/lib/octopus/association_collection.rb b/lib/octopus/association_collection.rb
    index 2dbff87..44d0f7a 100644
    --- a/lib/octopus/association_collection.rb
    +++ b/lib/octopus/association_collection.rb
    @@ -12,4 +12,8 @@ module Octopus::AssociationCollection
       end
     end
    
    -ActiveRecord::Associations::AssociationCollection.send(:include, Octopus::AssociationCollection)
    \ No newline at end of file
    +if ActiveRecord::VERSION::MAJOR >= 3 && ActiveRecord::VERSION::MINOR >=1
    +  ActiveRecord::Associations::CollectionAssociation.send(:include, Octopus::AssociationCollection)
    +else
    +  ActiveRecord::Associations::AssociationCollection.send(:include, Octopus::AssociationCollection)
    +end
    diff --git a/lib/octopus/migration.rb b/lib/octopus/migration.rb
    index 70bd8bd..7d9fd90 100644
    --- a/lib/octopus/migration.rb
    +++ b/lib/octopus/migration.rb
    @@ -70,4 +70,8 @@ module Octopus::Migration
       end
     end
    
    -ActiveRecord::Migration.extend(Octopus::Migration)
    +if ActiveRecord::VERSION::MAJOR >= 3 && ActiveRecord::VERSION::MINOR >=1
    +  ActiveRecord::Migration.send :include, Octopus::Migration
    +else
    +  ActiveRecord::Migration.extend(Octopus::Migration)
    +end
    ```
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have been using ActiveResource in my Ruby on Rails applications for some time,
I am using the authlogic gem with Ruby on Rails, and I have been
I have made an application using Ruby. Some gems are being used in it(approx.
I am using ruby on rails with a MySQL backend. I have a table
I have created a blog application using Ruby on Rails which includes the ability
I have built a very simple blog application using Ruby on Rails. New to
we have a mixed development environment using ASP.NET MVC and Ruby on Rails. We
I have built a blog application using Ruby on Rails. In the application I
I have recently been getting my feet wet in MongoDB using Mongoid w/ Rails
I have had some difficulties in using extended classes in rails, in particular extending

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.