Shift SQLite to single session in thread pool (it isn't very thread
safe)
This commit is contained in:
parent
3169359ece
commit
ed2f009156
1 changed files with 1 additions and 1 deletions
|
|
@ -31,7 +31,7 @@ import org.dynmap.utils.BufferOutputStream;
|
||||||
public class SQLiteMapStorage extends MapStorage {
|
public class SQLiteMapStorage extends MapStorage {
|
||||||
private String connectionString;
|
private String connectionString;
|
||||||
private String databaseFile;
|
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 Connection[] cpool = new Connection[POOLSIZE];
|
||||||
private int cpoolCount = 0;
|
private int cpoolCount = 0;
|
||||||
private static final Charset UTF8 = Charset.forName("UTF-8");
|
private static final Charset UTF8 = Charset.forName("UTF-8");
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue