@iobroker/db-objects-jsonl
Advanced tools
Comparing version 4.0.0-alpha.18-20211130-4386c795 to 4.0.0-alpha.19-20211201-44089655
@@ -24,18 +24,3 @@ /** | ||
settings.autoConnect = false; // delay Client connection to when we need it | ||
// hack around testing problem where subscribe was called before connect | ||
// Should be removed for a later release | ||
const origConnected = settings.connected; | ||
settings.connected = () => { | ||
this.clientConnected = true; | ||
if (Array.isArray(this.storedSubscribes) && this.storedSubscribes.length) { | ||
this.log.warn(`${this.namespace} Replay ${this.storedSubscribes.length} subscription calls for Objects Server that were done before the client was connected initially`); | ||
this.storedSubscribes.forEach((s => this.subscribe(s.pattern, s.options, s.callback))); | ||
this.storedSubscribes = []; | ||
} | ||
origConnected(); | ||
}; | ||
super(settings); | ||
this.clientConnected = false; | ||
this.storedSubscribes = []; | ||
@@ -70,11 +55,3 @@ const serverSettings = { | ||
} | ||
subscribe(pattern, options, callback) { | ||
if (!this.clientConnected) { | ||
this.storedSubscribes.push({pattern, options, callback}); // we ignore the promise return because not used for this testing issue we work around here | ||
} else { | ||
return super.subscribe(pattern, options, callback); | ||
} | ||
} | ||
} | ||
module.exports = ObjectsInMemoryServerClass; |
{ | ||
"name": "@iobroker/db-objects-jsonl", | ||
"version": "4.0.0-alpha.18-20211130-4386c795", | ||
"version": "4.0.0-alpha.19-20211201-44089655", | ||
"engines": { | ||
@@ -9,5 +9,5 @@ "node": ">=12.0.0" | ||
"@alcalzone/jsonl-db": "^2.2.0", | ||
"@iobroker/db-base": "4.0.0-alpha.18-20211130-4386c795", | ||
"@iobroker/db-objects-file": "4.0.0-alpha.18-20211130-4386c795", | ||
"@iobroker/db-objects-redis": "4.0.0-alpha.18-20211130-4386c795", | ||
"@iobroker/db-base": "4.0.0-alpha.19-20211201-44089655", | ||
"@iobroker/db-objects-file": "4.0.0-alpha.19-20211201-44089655", | ||
"@iobroker/db-objects-redis": "4.0.0-alpha.19-20211201-44089655", | ||
"deep-clone": "^3.0.3", | ||
@@ -42,3 +42,3 @@ "fs-extra": "^10.0.0", | ||
], | ||
"gitHead": "f262c82c7cb53004b1af415ff975b076226973ca" | ||
"gitHead": "237b7fc86660db587538e97b20c468bedacbb461" | ||
} |
51470
910
+ Added@iobroker/db-base@4.0.0-alpha.19-20211201-44089655(transitive)
+ Added@iobroker/db-objects-file@4.0.0-alpha.19-20211201-44089655(transitive)
+ Added@iobroker/db-objects-redis@4.0.0-alpha.19-20211201-44089655(transitive)
+ Added@iobroker/js-controller-common@4.0.0-alpha.19-20211201-44089655(transitive)
- Removed@iobroker/db-base@4.0.0-alpha.18-20211130-4386c795(transitive)
- Removed@iobroker/db-objects-file@4.0.0-alpha.18-20211130-4386c795(transitive)
- Removed@iobroker/db-objects-redis@4.0.0-alpha.18-20211130-4386c795(transitive)
- Removed@iobroker/js-controller-common@4.0.0-alpha.18-20211130-4386c795(transitive)
Updated@iobroker/db-objects-file@4.0.0-alpha.19-20211201-44089655
Updated@iobroker/db-objects-redis@4.0.0-alpha.19-20211201-44089655