@yarkivaev/scada 2.3.81 → 2.3.82
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/README.md +1 -1
- package/package.json +1 -1
- package/src/domain/segment/splitFamily.js +2 -7
package/README.md
CHANGED
|
@@ -89,7 +89,7 @@ One `off` phase can be replaced by contiguous pieces. There is no parent row and
|
|
|
89
89
|
|
|
90
90
|
A later edit sends the whole family again. `timeline.respond` / `PATCH /segments` take `{ splits: [{ start, end, tag, open }] }` addressed by the original start. The supervisor publishes one STOMP body, `type: split-family`, with `origin` in epoch millis and the pieces. The sink deletes family starts the new cut does not use, then upserts the pieces, in one transaction.
|
|
91
91
|
|
|
92
|
-
The replacement must keep the original start and, for a closed off, the latest end of the stored family. Removing every piece but one therefore restores those bounds. `splits: []` is refused before any delete, and the stored family stays. A
|
|
92
|
+
The replacement must keep the original start and, for a closed off, the latest end of the stored family. Removing every piece but one therefore restores those bounds. `splits: []` is refused before any delete, and the stored family stays. A piece may be any positive length. Only the tail of a still-open off may have `duration = 0`. A duration-0 heartbeat does not extend a closed piece that already has `split_of`.
|
|
93
93
|
|
|
94
94
|
`C0007` grants `DELETE` on `segments` to `supervisor_sink` on the privileged admin path. The sink role does not run that grant itself. Central previously revoked this privilege (`C0002`).
|
|
95
95
|
|
package/package.json
CHANGED
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
const MIN_MS = 60000;
|
|
2
|
-
|
|
3
1
|
function dated(piece) {
|
|
4
2
|
return {
|
|
5
3
|
start: new Date(piece.start),
|
|
@@ -29,11 +27,8 @@ function refuseGap(ordered, piece, index) {
|
|
|
29
27
|
|
|
30
28
|
function refuseSpan(piece) {
|
|
31
29
|
const span = piece.end.getTime() - piece.start.getTime();
|
|
32
|
-
if (
|
|
33
|
-
throw new RangeError('piece
|
|
34
|
-
}
|
|
35
|
-
if (piece.open && span < 0) {
|
|
36
|
-
throw new RangeError('open tail ends before it starts');
|
|
30
|
+
if (span < 0) {
|
|
31
|
+
throw new RangeError('piece ends before it starts');
|
|
37
32
|
}
|
|
38
33
|
}
|
|
39
34
|
|