@nxtedition/lib 28.0.24 → 28.0.25
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/app.js +10 -20
- package/package.json +2 -2
package/app.js
CHANGED
|
@@ -823,13 +823,12 @@ export function makeApp(appConfig, onTerminateOrMeta, metaOrNull) {
|
|
|
823
823
|
}
|
|
824
824
|
}
|
|
825
825
|
}
|
|
826
|
-
return
|
|
826
|
+
return messages
|
|
827
827
|
}),
|
|
828
828
|
),
|
|
829
829
|
status$.pipe(
|
|
830
|
-
rxjs.
|
|
831
|
-
|
|
832
|
-
makeStatusPipe('stats'),
|
|
830
|
+
rxjs.map((xs) => [xs, xs?.messages].find(Array.isArray) ?? []),
|
|
831
|
+
makeStatusPipe('status'),
|
|
833
832
|
),
|
|
834
833
|
monitorProviders.stats$?.pipe(
|
|
835
834
|
rxjs.map(({ memory, heap, utilization, undici, http }) => {
|
|
@@ -1021,17 +1020,8 @@ export function makeApp(appConfig, onTerminateOrMeta, metaOrNull) {
|
|
|
1021
1020
|
])
|
|
1022
1021
|
.pipe(
|
|
1023
1022
|
rxjs.auditTime(1e3),
|
|
1024
|
-
rxjs.map((
|
|
1025
|
-
const messages =
|
|
1026
|
-
lag,
|
|
1027
|
-
couch,
|
|
1028
|
-
ds,
|
|
1029
|
-
[
|
|
1030
|
-
status?.messages,
|
|
1031
|
-
fp.map((x) => (fp.isString(x) ? { msg: x, level: 40 } : x), status?.warnings),
|
|
1032
|
-
status,
|
|
1033
|
-
].find((x) => fp.isArray(x) && !fp.isEmpty(x)) ?? [],
|
|
1034
|
-
]
|
|
1023
|
+
rxjs.map((xs) => {
|
|
1024
|
+
const messages = xs
|
|
1035
1025
|
.flat()
|
|
1036
1026
|
.filter((x) => fp.isPlainObject(x) && !fp.isEmpty(x))
|
|
1037
1027
|
.map((message) =>
|
|
@@ -1054,18 +1044,18 @@ export function makeApp(appConfig, onTerminateOrMeta, metaOrNull) {
|
|
|
1054
1044
|
},
|
|
1055
1045
|
)
|
|
1056
1046
|
|
|
1057
|
-
return {
|
|
1047
|
+
return { messages, timestamp: Date.now() }
|
|
1058
1048
|
}),
|
|
1059
1049
|
makeStatusPipe('status'),
|
|
1060
1050
|
)
|
|
1061
1051
|
.subscribe(monitorProviders.status$),
|
|
1062
1052
|
)
|
|
1063
1053
|
|
|
1064
|
-
const
|
|
1054
|
+
const statusBC = new BroadcastChannel('nxt:app:stats').unref()
|
|
1065
1055
|
|
|
1066
1056
|
if (isMainThread) {
|
|
1067
1057
|
statusMap = new Map()
|
|
1068
|
-
|
|
1058
|
+
statusBC.onmessage = ({ data: { data, id } }) => {
|
|
1069
1059
|
if (data != null) {
|
|
1070
1060
|
statusMap.set(id, data)
|
|
1071
1061
|
} else {
|
|
@@ -1077,10 +1067,10 @@ export function makeApp(appConfig, onTerminateOrMeta, metaOrNull) {
|
|
|
1077
1067
|
appDestroyers.unshift(
|
|
1078
1068
|
monitorProviders.status$
|
|
1079
1069
|
.subscribe((stats) => {
|
|
1080
|
-
|
|
1070
|
+
statusBC.postMessage({ id: threadId, data: stats })
|
|
1081
1071
|
})
|
|
1082
1072
|
.add(() => {
|
|
1083
|
-
|
|
1073
|
+
statusBC.postMessage({ id: threadId, data: undefined })
|
|
1084
1074
|
}),
|
|
1085
1075
|
)
|
|
1086
1076
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nxtedition/lib",
|
|
3
|
-
"version": "28.0.
|
|
3
|
+
"version": "28.0.25",
|
|
4
4
|
"license": "UNLICENSED",
|
|
5
5
|
"author": "Robert Nagy <robert.nagy@boffins.se>",
|
|
6
6
|
"type": "module",
|
|
@@ -92,5 +92,5 @@
|
|
|
92
92
|
"canvas": "^3.1.0",
|
|
93
93
|
"rxjs": "^7.0.0"
|
|
94
94
|
},
|
|
95
|
-
"gitHead": "
|
|
95
|
+
"gitHead": "48c8835b26082e9c7f427a1dca71c4f9fa3e2091"
|
|
96
96
|
}
|