为了账号安全,请及时绑定邮箱和手机立即绑定

我根据老师的代码配置,用getCurrentSession()的时候报错:No CurrentSessionContext configured。用openSession()没问题

报下面这个错

No CurrentSessionContext configured

正在回答

2 回答

他设置的时间是4天内的,超出四天的会显示错误

spd10000ljiesmgeboksrbmtozrmj

0 回复 有任何疑惑可以回复我~

配置文件中添加试试

<property name="current_session_context_class">thread</property>



0 回复 有任何疑惑可以回复我~

举报

0/150
提交
取消

我根据老师的代码配置,用getCurrentSession()的时候报错:No CurrentSessionContext configured。用openSession()没问题

我要回答 关注问题
意见反馈 帮助中心 APP下载
官方微信