fix(POSTV1-01): 让Worker使用便携包SQLite原生绑定
Dada P0-A isolated Windows CI / validate-and-package (push) Waiting to run

This commit is contained in:
suyx
2026-08-05 11:25:02 +08:00
parent 1155a81c3b
commit 90f812fae5
+2 -1
View File
@@ -91,7 +91,8 @@ export class GenerationProcessor {
this.clock = input.clock ?? Date.now; this.clock = input.clock ?? Date.now;
this.dataRoot = resolve(input.dataRoot); this.dataRoot = resolve(input.dataRoot);
this.workerId = input.workerId; this.workerId = input.workerId;
this.database = new Database(input.databasePath); const nativeBinding = process.env.DADA_SQLITE_NATIVE_BINDING;
this.database = new Database(input.databasePath, nativeBinding ? { nativeBinding } : undefined);
configureWorkerDatabase(this.database); configureWorkerDatabase(this.database);
this.migrate(); this.migrate();
this.gatewayBalance = new GatewayBalanceRuntime({ clock: this.clock, database: this.database }); this.gatewayBalance = new GatewayBalanceRuntime({ clock: this.clock, database: this.database });