Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

这个项目中的监听器listener如何才能调用delegateMapper进行数据库的操作,我一直无法在listener监听器里调用mapper操作数据库 #12

Open
jcq69 opened this issue Aug 1, 2019 · 2 comments

Comments

@jcq69
Copy link

jcq69 commented Aug 1, 2019

No description provided.

@jcq69
Copy link
Author

jcq69 commented Aug 1, 2019

我尝试了很多方法还是调用不了mapper来操作sql

@micyo202
Copy link
Owner

micyo202 commented Aug 1, 2019

listener无法直接调用delegateMapper进行数据库操作,因为web.xml初始化listener时还不能获取数据库配置相关信息,在listener中弱要对数据库操作需要自定义JDBC操作。不知道为什么要设计在listener中与DB交互?可以放在filter中实现吗?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants