From ccedc8cfea30d72780e34a0982f830be9034296d Mon Sep 17 00:00:00 2001 From: 17jiong <17jiong@gmail.com> Date: Mon, 29 Jan 2018 04:24:47 +0800 Subject: [PATCH] =?UTF-8?q?=E8=BF=9E=E6=8E=A5=E6=B1=A0=E7=BA=BF=E7=A8=8B?= =?UTF-8?q?=E5=AE=89=E5=85=A8=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/org/maxgamer/QuickShop/Database/MySQLCore.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/org/maxgamer/QuickShop/Database/MySQLCore.java b/src/main/java/org/maxgamer/QuickShop/Database/MySQLCore.java index deebecb..0c65a5e 100644 --- a/src/main/java/org/maxgamer/QuickShop/Database/MySQLCore.java +++ b/src/main/java/org/maxgamer/QuickShop/Database/MySQLCore.java @@ -4,7 +4,7 @@ import java.sql.Connection; import java.sql.DriverManager; import java.sql.PreparedStatement; import java.sql.SQLException; -import java.util.ArrayList; +import java.util.List; import java.util.Properties; public class MySQLCore implements DatabaseCore { @@ -12,7 +12,7 @@ public class MySQLCore implements DatabaseCore { /** The connection properties... user, pass, autoReconnect.. */ private Properties info; private static final int MAX_CONNECTIONS = 8; - private static ArrayList pool = new ArrayList<>(); + private static final List pool = Collections.synchronizedList(new ArrayList()); public MySQLCore(String host, String user, String pass, String database, String port) { info = new Properties();