提交 7f25ccf3 编写于 作者: J José Valim

Remove allow_concurrency and verification_timeout from ActiveRecord::Base (deprecated since 2.2).

上级 c464271e
......@@ -88,26 +88,6 @@ def self.establish_connection(spec = nil)
end
class << self
# Deprecated and no longer has any effect.
def allow_concurrency
ActiveSupport::Deprecation.warn("ActiveRecord::Base.allow_concurrency has been deprecated and no longer has any effect. Please remove all references to allow_concurrency.")
end
# Deprecated and no longer has any effect.
def allow_concurrency=(flag)
ActiveSupport::Deprecation.warn("ActiveRecord::Base.allow_concurrency= has been deprecated and no longer has any effect. Please remove all references to allow_concurrency=.")
end
# Deprecated and no longer has any effect.
def verification_timeout
ActiveSupport::Deprecation.warn("ActiveRecord::Base.verification_timeout has been deprecated and no longer has any effect. Please remove all references to verification_timeout.")
end
# Deprecated and no longer has any effect.
def verification_timeout=(flag)
ActiveSupport::Deprecation.warn("ActiveRecord::Base.verification_timeout= has been deprecated and no longer has any effect. Please remove all references to verification_timeout=.")
end
# Returns the connection currently associated with the class. This can
# also be used to "borrow" the connection to do database work unrelated
# to any of the specific Active Records.
......
......@@ -39,7 +39,6 @@ class AbstractAdapter
def initialize(connection, logger = nil) #:nodoc:
@connection, @logger = connection, logger
@runtime = 0
@last_verification = 0
@query_cache_enabled = false
end
......@@ -208,10 +207,6 @@ def log(sql, name)
end
result
rescue Exception => e
# Log message and raise exception.
# Set last_verification to 0, so that connection gets verified
# upon reentering the request loop
@last_verification = 0
message = "#{e.class.name}: #{e.message}: #{sql}"
log_info(message, name, 0)
raise translate_exception(e, message)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册