症状是:
TinyTds::Error: Adaptive Server 连接超时:EXEC some_stored_procedure
这是execute_procedure
通过 ActiveRecord over 在慢速 MSSQL Server 上的慢速存储过程tinytds
。如果我EXEC
在 SQL 查询分析器中存储过程,它需要 29 到 30 才能完成。
所以我补充说:
timeout = 60
在/etc/freetds.conf
和:
read_timeout: 60
write_timeout: 60
到database.yml
.
同样的错误仍然出现。还有其他我错过的配置吗?
ps 我确实测量了在按下返回键后超时错误出现的时间,大约是 30 秒。我有一种感觉 30 秒可能不是 or 的默认超时,freetds
并且activerecord
想知道为什么错误显示的时间有点接近 sql 完成的时间......