mirror of
https://github.com/alibaba/druid.git
synced 2023-03-04 19:17:16 +00:00
bug fixed for thread-safe init
This commit is contained in:
@@ -59,7 +59,7 @@ public class WallFilter extends FilterAdapter implements WallFilterMBean {
|
||||
public final static String ATTR_SQL_STAT = "wall.sqlStat";
|
||||
|
||||
@Override
|
||||
public void init(DataSourceProxy dataSource) {
|
||||
public synchronized void init(DataSourceProxy dataSource) {
|
||||
if (this.dbType == null || this.dbType.trim().length() == 0) {
|
||||
if (dataSource != null && dataSource.getDbType() != null) {
|
||||
this.dbType = dataSource.getDbType();
|
||||
|
||||
Reference in New Issue
Block a user