From 0c34d5a5b53cccf11c781ebe2528c9b572d24f51 Mon Sep 17 00:00:00 2001 From: Mike Primm Date: Sat, 5 Feb 2022 02:05:54 -0600 Subject: [PATCH] Shift SQLite to single session in thread pool (it isn't very thread safe) --- .../main/java/org/dynmap/storage/sqllte/SQLiteMapStorage.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DynmapCore/src/main/java/org/dynmap/storage/sqllte/SQLiteMapStorage.java b/DynmapCore/src/main/java/org/dynmap/storage/sqllte/SQLiteMapStorage.java index e3ea11f5..13493ead 100644 --- a/DynmapCore/src/main/java/org/dynmap/storage/sqllte/SQLiteMapStorage.java +++ b/DynmapCore/src/main/java/org/dynmap/storage/sqllte/SQLiteMapStorage.java @@ -31,7 +31,7 @@ import org.dynmap.utils.BufferOutputStream; public class SQLiteMapStorage extends MapStorage { private String connectionString; private String databaseFile; - private static final int POOLSIZE = 5; + private static final int POOLSIZE = 1; // SQLite is really not thread safe... 1 at a time works best private Connection[] cpool = new Connection[POOLSIZE]; private int cpoolCount = 0; private static final Charset UTF8 = Charset.forName("UTF-8");