release: v0.1.14 生产加固 — IDB事务原子性/多标签页感知/幂等init
CI / test (18.x) (push) Successful in 9m54s
CI / test (20.x) (push) Successful in 9m52s
CI / test (22.x) (push) Successful in 9m52s
CI / test (24.x) (push) Successful in 9m48s

This commit is contained in:
thzxx
2026-07-26 17:20:31 +08:00
parent 71e238a5cc
commit 014e92884c
16 changed files with 165 additions and 52 deletions
+7 -1
View File
@@ -24,7 +24,13 @@ export class MemoryEngine implements IStorageEngine {
} | null = null;
// ---- 生命周期 ----
async open(_dbName: string, _version: number): Promise<void> { this.opened = true; }
async open(_dbName: string, _version: number): Promise<void> {
if (this.opened) {
// 幂等:已打开则忽略
return;
}
this.opened = true;
}
async close(): Promise<void> {
this.tables.clear(); this.schemas.clear(); this.indexes.clear(); this.opened = false;
}