What is default isolation level hibernate uses if not explicitly set?

眉间皱痕 提交于 2019-12-02 19:01:07

looks like meta.getDefaultTransactionIsolation()); is hardcoded in the implementation of DatabaseMetaData in the mysql driver

public class DatabaseMetaData implements java.sql.DatabaseMetaData lines....


1475    public int getDefaultTransactionIsolation() throws java.sql.SQLException JavaDoc {
1476        if (this.conn.supportsIsolationLevel()) {
1477            return java.sql.Connection.TRANSACTION_READ_COMMITTED;
1478        } else {
1479            return java.sql.Connection.TRANSACTION_NONE;
1480        }
1481    }

so i'd bet and trust getSession().connection().getTransactionIsolation()

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!