提交 ba0fb548 authored 作者: Thomas Mueller's avatar Thomas Mueller

A bug in the server-less multi-connection mode has been fixed.

上级 b28e03e4
...@@ -322,6 +322,7 @@ public class Database implements DataHandler { ...@@ -322,6 +322,7 @@ public class Database implements DataHandler {
lock.setProperty("modificationMetaId", Long.toString(modificationMetaId)); lock.setProperty("modificationMetaId", Long.toString(modificationMetaId));
lock.setProperty("changePending", pending ? "true" : null); lock.setProperty("changePending", pending ? "true" : null);
lock.save(); lock.save();
reconnectLastLock = lock.load();
reconnectChangePending = pending; reconnectChangePending = pending;
} catch (Exception e) { } catch (Exception e) {
getTrace().error("pending:"+ pending, e); getTrace().error("pending:"+ pending, e);
......
...@@ -1118,6 +1118,7 @@ public class Session extends SessionWithState { ...@@ -1118,6 +1118,7 @@ public class Session extends SessionWithState {
public SessionInterface reconnect() throws SQLException { public SessionInterface reconnect() throws SQLException {
readSessionState(); readSessionState();
close();
Session newSession = Engine.getInstance().getSession(connectionInfo); Session newSession = Engine.getInstance().getSession(connectionInfo);
newSession.sessionState = sessionState; newSession.sessionState = sessionState;
newSession.recreateSessionState(); newSession.recreateSessionState();
......
...@@ -457,7 +457,11 @@ public class LogFile { ...@@ -457,7 +457,11 @@ public class LogFile {
file.close(); file.close();
file = null; file = null;
if (delete) { if (delete) {
database.deleteLogFileLater(fileName); try {
database.deleteLogFileLater(fileName);
} catch (SQLException e) {
// can not delete the file now - ignore
}
} }
} catch (IOException e) { } catch (IOException e) {
if (closeException == null) { if (closeException == null) {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论