Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想知道是否有办法获得向数据库发送查询的时间戳和在ofbiz中获得查询结果的时间戳?例如,一个客户正在访问ofbiz的主页,我想看看数据库处理查询需要多长时间。谢谢。
GenericDAO.java 包含代码(我正在使用的版本中的第 755 行),如果查询超过 150 毫秒,则记录该查询。这可以修改为打印查询和时间,无论它花费的时间或您有兴趣检查的任何限制。