zendesk/active_record_shards — pull request #24 by gabetax (2014-07-08 21:46:18+00:00)
Title: patch rails 4 schema.rb generation to include sharded tables

When rails generates db/schema.rb, it previously did not include any sharded tables. This adds an additional `ActiveRecord::Schema.define` block populated with the sharded tables. The sharded database will receive its own `schema_migrations` table when running `rake db:schema:load`.

This behavior currently only occurs on Rails 4+ / Ruby 2+