cross-tab-worker-databus 0.20.19 → 0.20.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/dist/centrifuge.js +1 -1
- package/dist/{chunk-TC7XXOVN.js → chunk-UMMKMXOT.js} +10 -2
- package/dist/{chunk-TC7XXOVN.js.map → chunk-UMMKMXOT.js.map} +2 -2
- package/dist/cjs/centrifuge.cjs +9 -1
- package/dist/cjs/centrifuge.cjs.map +2 -2
- package/dist/cjs/index.cjs +9 -1
- package/dist/cjs/index.cjs.map +2 -2
- package/dist/core/data-bus.d.ts +1 -0
- package/dist/core/data-bus.d.ts.map +1 -1
- package/dist/core/trace.d.ts +1 -1
- package/dist/core/trace.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/docs/roadmap.md +9 -1
- package/docs/zh/roadmap.md +9 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,18 @@
|
|
|
2
2
|
|
|
3
3
|
本项目遵循 [Semantic Versioning](https://semver.org/);变更记录格式参考 [Keep a Changelog](https://keepachangelog.com/)。
|
|
4
4
|
|
|
5
|
+
## [0.20.21] - 2026-09-03
|
|
6
|
+
|
|
7
|
+
### Fixed
|
|
8
|
+
|
|
9
|
+
- Recovery exhaustion diagnostics are now emitted at most once per failed recovery sequence and reset after a successful reopen.
|
|
10
|
+
|
|
11
|
+
## [0.20.20] - 2026-09-03
|
|
12
|
+
|
|
13
|
+
### Added
|
|
14
|
+
|
|
15
|
+
- Automatic recovery now emits an `exhausted` reliability event when `recovery.maxAttempts` is reached, instead of stopping silently.
|
|
16
|
+
|
|
5
17
|
## [0.20.19] - 2026-09-03
|
|
6
18
|
|
|
7
19
|
### Added
|
package/dist/centrifuge.js
CHANGED
|
@@ -1275,6 +1275,7 @@ var CrossTabDataBus = class {
|
|
|
1275
1275
|
// Monotonic attempt number within one runtime recovery sequence; reset once
|
|
1276
1276
|
// a transport reopen succeeds so traces can correlate repeated failures.
|
|
1277
1277
|
recoveryAttempt = 0;
|
|
1278
|
+
recoveryExhausted = false;
|
|
1278
1279
|
// True while the tab is hidden so an in-flight transport start does not mark
|
|
1279
1280
|
// the transport ready after suspendTransport() has stopped it.
|
|
1280
1281
|
suspended = false;
|
|
@@ -1882,7 +1883,13 @@ var CrossTabDataBus = class {
|
|
|
1882
1883
|
if (now - this.lastRecoveryAt >= this.recoveryCooldownMs) {
|
|
1883
1884
|
this.lastRecoveryAt = now;
|
|
1884
1885
|
const attempt = ++this.recoveryAttempt;
|
|
1885
|
-
if (attempt > this.recoveryMaxAttempts)
|
|
1886
|
+
if (attempt > this.recoveryMaxAttempts) {
|
|
1887
|
+
if (!this.recoveryExhausted) {
|
|
1888
|
+
this.recoveryExhausted = true;
|
|
1889
|
+
this.trace.event({ type: "reliability", operation: "transport_recovery", attempt: this.recoveryMaxAttempts, outcome: "exhausted" });
|
|
1890
|
+
}
|
|
1891
|
+
return;
|
|
1892
|
+
}
|
|
1886
1893
|
this.trace.event({ type: "reliability", operation: "transport_recovery", attempt, outcome: "scheduled" });
|
|
1887
1894
|
setTimeout(() => {
|
|
1888
1895
|
if (this.stopping || !this.started || this.suspended) return;
|
|
@@ -1994,6 +2001,7 @@ var CrossTabDataBus = class {
|
|
|
1994
2001
|
if (traceAttempt !== void 0) {
|
|
1995
2002
|
this.trace.event({ type: "reliability", operation: "transport_recovery", attempt: traceAttempt, outcome: "succeeded" });
|
|
1996
2003
|
this.recoveryAttempt = 0;
|
|
2004
|
+
this.recoveryExhausted = false;
|
|
1997
2005
|
}
|
|
1998
2006
|
if (this.startPromise === opening) this.startPromise = null;
|
|
1999
2007
|
},
|
|
@@ -2101,4 +2109,4 @@ export {
|
|
|
2101
2109
|
parseDataBusPublication,
|
|
2102
2110
|
selectWorkerBackend
|
|
2103
2111
|
};
|
|
2104
|
-
//# sourceMappingURL=chunk-
|
|
2112
|
+
//# sourceMappingURL=chunk-UMMKMXOT.js.map
|