2019-09-21 17:00

@shanmine 我这里也出现加入过滤器,但是不起作用,查看addFilter(new TestFilter()); 后 filterList 中是存在 testFilter 的,但是在sql 执行时 ,就是不执行拦截器中方法。
具体filter 如下,麻烦看一下有什么问题吗?
public class TestFilter extends FilterEventAdapter {
protected final Log log = Log.getLog(getClass());
@Override
protected void statementExecuteAfter(StatementProxy statement, String sql, boolean result) {
log.info("init TestFilter after");
super.statementExecuteAfter(statement, sql, result);
}
@Override
protected void statementExecuteBefore(StatementProxy statement, String sql) {
log.info("init TestFilter befor");
super.statementExecuteBefore(statement, sql);
}
}