aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib
diff options
context:
space:
mode:
authorRyuta Kamizono <kamipo@gmail.com>2018-09-06 08:04:06 +0900
committerGitHub <noreply@github.com>2018-09-06 08:04:06 +0900
commit54a9dbf5f19e128a2da851707fdaf34868b50078 (patch)
tree6e37d78412a0e87fd3032ce6dd7c56b4f5610b89 /activerecord/lib
parentf80722c0ebacaaee5d61bfa3359a9ec43d04ac78 (diff)
parente0a1235f7df0fa193c7e299a5adee88db246b44f (diff)
downloadrails-54a9dbf5f19e128a2da851707fdaf34868b50078.tar.gz
rails-54a9dbf5f19e128a2da851707fdaf34868b50078.tar.bz2
rails-54a9dbf5f19e128a2da851707fdaf34868b50078.zip
Merge pull request #33799 from kamipo/deprecate_unused_methods_in_database_limits
Deprecate most methods which were never used in `DatabaseLimits`
Diffstat (limited to 'activerecord/lib')
-rw-r--r--activerecord/lib/active_record/connection_adapters/abstract/database_limits.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/abstract/database_limits.rb b/activerecord/lib/active_record/connection_adapters/abstract/database_limits.rb
index 7a9e7add24..ad148efcfe 100644
--- a/activerecord/lib/active_record/connection_adapters/abstract/database_limits.rb
+++ b/activerecord/lib/active_record/connection_adapters/abstract/database_limits.rb
@@ -1,5 +1,7 @@
# frozen_string_literal: true
+require "active_support/deprecation"
+
module ActiveRecord
module ConnectionAdapters # :nodoc:
module DatabaseLimits
@@ -12,11 +14,13 @@ module ActiveRecord
def column_name_length
64
end
+ deprecate :column_name_length
# Returns the maximum length of a table name.
def table_name_length
64
end
+ deprecate :table_name_length
# Returns the maximum allowed length for an index name. This
# limit is enforced by \Rails and is less than or equal to
@@ -36,16 +40,19 @@ module ActiveRecord
def columns_per_table
1024
end
+ deprecate :columns_per_table
# Returns the maximum number of indexes per table.
def indexes_per_table
16
end
+ deprecate :indexes_per_table
# Returns the maximum number of columns in a multicolumn index.
def columns_per_multicolumn_index
16
end
+ deprecate :columns_per_multicolumn_index
# Returns the maximum number of elements in an IN (x,y,z) clause.
# +nil+ means no limit.
@@ -57,11 +64,13 @@ module ActiveRecord
def sql_query_length
1048575
end
+ deprecate :sql_query_length
# Returns maximum number of joins in a single query.
def joins_per_query
256
end
+ deprecate :joins_per_query
end
end
end