Fix `SchemaCacheWithRenamedTable` does not work with many databases
Instead of getting the connection from ActiveRecord::Base, we use the connection from ActiveRecord::ConnectionAdapters::SchemaCache. Schema cache will return the proper connection based on the database context. Related to https://gitlab.com/gitlab-org/gitlab/-/issues/336899
Showing
Please register or sign in to comment