@xh/hoist 69.0.0-SNAPSHOT.1728431598764 → 69.0.0-SNAPSHOT.1728502091807
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/admin/columns/Core.ts +1 -1
- package/admin/tabs/cluster/BaseInstanceModel.ts +1 -1
- package/admin/tabs/cluster/connpool/ConnPoolMonitorPanel.ts +30 -23
- package/admin/tabs/cluster/hzobject/HzObjectModel.ts +9 -2
- package/admin/tabs/cluster/hzobject/HzObjectPanel.ts +3 -3
- package/admin/tabs/cluster/memory/MemoryMonitorPanel.ts +45 -37
- package/build/types/admin/tabs/cluster/hzobject/HzObjectModel.d.ts +2 -0
- package/package.json +1 -1
- package/tsconfig.tsbuildinfo +1 -1
package/admin/columns/Core.ts
CHANGED
|
@@ -44,5 +44,5 @@ export const note: ColumnSpec = {
|
|
|
44
44
|
export const timestampNoYear: ColumnSpec = {
|
|
45
45
|
field: {name: 'timestamp', type: 'date'},
|
|
46
46
|
...dateTimeSec,
|
|
47
|
-
renderer: dateTimeRenderer({fmt: 'MMM DD HH:mm:ss'})
|
|
47
|
+
renderer: dateTimeRenderer({fmt: 'MMM DD HH:mm:ss.SSS'})
|
|
48
48
|
};
|
|
@@ -61,7 +61,7 @@ export class BaseInstanceModel extends HoistModel {
|
|
|
61
61
|
isNumber(v) &&
|
|
62
62
|
v > Date.now() - 365 * DAYS
|
|
63
63
|
) {
|
|
64
|
-
stats[k] = v ? fmtDateTimeSec(v, {fmt: 'MMM DD HH:mm:ss'}) : null;
|
|
64
|
+
stats[k] = v ? fmtDateTimeSec(v, {fmt: 'MMM DD HH:mm:ss.SSS'}) : null;
|
|
65
65
|
}
|
|
66
66
|
if (isPlainObject(v) || isArray(v)) {
|
|
67
67
|
this.processTimestamps(v);
|
|
@@ -14,6 +14,7 @@ import {button, exportButton} from '@xh/hoist/desktop/cmp/button';
|
|
|
14
14
|
import {errorMessage} from '@xh/hoist/desktop/cmp/error';
|
|
15
15
|
import {jsonInput} from '@xh/hoist/desktop/cmp/input';
|
|
16
16
|
import {panel} from '@xh/hoist/desktop/cmp/panel';
|
|
17
|
+
import {toolbar} from '@xh/hoist/desktop/cmp/toolbar';
|
|
17
18
|
import {Icon} from '@xh/hoist/icon';
|
|
18
19
|
|
|
19
20
|
export const connPoolMonitorPanel = hoistCmp.factory({
|
|
@@ -26,28 +27,8 @@ export const connPoolMonitorPanel = hoistCmp.factory({
|
|
|
26
27
|
});
|
|
27
28
|
}
|
|
28
29
|
|
|
29
|
-
const {readonly} = AppModel;
|
|
30
30
|
return panel({
|
|
31
|
-
|
|
32
|
-
button({
|
|
33
|
-
text: 'Take Snapshot',
|
|
34
|
-
icon: Icon.camera(),
|
|
35
|
-
omit: readonly,
|
|
36
|
-
onClick: () => model.takeSnapshotAsync()
|
|
37
|
-
}),
|
|
38
|
-
'-',
|
|
39
|
-
button({
|
|
40
|
-
text: 'Reset Stats',
|
|
41
|
-
icon: Icon.reset(),
|
|
42
|
-
omit: readonly,
|
|
43
|
-
onClick: () => model.resetStatsAsync()
|
|
44
|
-
}),
|
|
45
|
-
filler(),
|
|
46
|
-
gridCountLabel({unit: 'snapshot'}),
|
|
47
|
-
'-',
|
|
48
|
-
exportButton()
|
|
49
|
-
],
|
|
50
|
-
items: hframe(
|
|
31
|
+
item: hframe(
|
|
51
32
|
vframe(
|
|
52
33
|
grid(),
|
|
53
34
|
panel({
|
|
@@ -60,12 +41,38 @@ export const connPoolMonitorPanel = hoistCmp.factory({
|
|
|
60
41
|
),
|
|
61
42
|
poolConfigPanel()
|
|
62
43
|
),
|
|
63
|
-
|
|
64
|
-
ref: model.viewRef
|
|
44
|
+
bbar: bbar(),
|
|
45
|
+
ref: model.viewRef,
|
|
46
|
+
mask: 'onLoad'
|
|
65
47
|
});
|
|
66
48
|
}
|
|
67
49
|
});
|
|
68
50
|
|
|
51
|
+
const bbar = hoistCmp.factory<ConnPoolMonitorModel>({
|
|
52
|
+
render({model}) {
|
|
53
|
+
const {readonly} = AppModel;
|
|
54
|
+
return toolbar(
|
|
55
|
+
button({
|
|
56
|
+
text: 'Take Snapshot',
|
|
57
|
+
icon: Icon.camera(),
|
|
58
|
+
omit: readonly,
|
|
59
|
+
onClick: () => model.takeSnapshotAsync()
|
|
60
|
+
}),
|
|
61
|
+
'-',
|
|
62
|
+
button({
|
|
63
|
+
text: 'Reset Stats',
|
|
64
|
+
icon: Icon.reset(),
|
|
65
|
+
omit: readonly,
|
|
66
|
+
onClick: () => model.resetStatsAsync()
|
|
67
|
+
}),
|
|
68
|
+
filler(),
|
|
69
|
+
gridCountLabel({unit: 'snapshot'}),
|
|
70
|
+
'-',
|
|
71
|
+
exportButton()
|
|
72
|
+
);
|
|
73
|
+
}
|
|
74
|
+
});
|
|
75
|
+
|
|
69
76
|
const poolConfigPanel = hoistCmp.factory<ConnPoolMonitorModel>({
|
|
70
77
|
render({model}) {
|
|
71
78
|
return panel({
|
|
@@ -13,6 +13,7 @@ import * as Col from '@xh/hoist/cmp/grid/columns';
|
|
|
13
13
|
import {br, fragment} from '@xh/hoist/cmp/layout';
|
|
14
14
|
import {LoadSpec, managed, PlainObject, XH} from '@xh/hoist/core';
|
|
15
15
|
import {RecordActionSpec} from '@xh/hoist/data';
|
|
16
|
+
import {PanelModel} from '@xh/hoist/desktop/cmp/panel';
|
|
16
17
|
import {Icon} from '@xh/hoist/icon';
|
|
17
18
|
import {bindable, makeObservable} from '@xh/hoist/mobx';
|
|
18
19
|
import {first, isEmpty, last} from 'lodash';
|
|
@@ -20,6 +21,11 @@ import {first, isEmpty, last} from 'lodash';
|
|
|
20
21
|
export class HzObjectModel extends BaseInstanceModel {
|
|
21
22
|
@bindable groupBy: 'type' | 'owner' = 'owner';
|
|
22
23
|
|
|
24
|
+
@managed detailPanelModel = new PanelModel({
|
|
25
|
+
side: 'right',
|
|
26
|
+
defaultSize: 450
|
|
27
|
+
});
|
|
28
|
+
|
|
23
29
|
clearAction: RecordActionSpec = {
|
|
24
30
|
text: 'Clear Objects',
|
|
25
31
|
icon: Icon.reset(),
|
|
@@ -37,6 +43,7 @@ export class HzObjectModel extends BaseInstanceModel {
|
|
|
37
43
|
gridModel = new GridModel({
|
|
38
44
|
selModel: 'multiple',
|
|
39
45
|
enableExport: true,
|
|
46
|
+
autosizeOptions: {mode: 'managed', includeCollapsedChildren: true},
|
|
40
47
|
exportOptions: {filename: exportFilenameWithDate('distributed-objects'), columns: 'ALL'},
|
|
41
48
|
sortBy: 'displayName',
|
|
42
49
|
groupBy: this.groupBy,
|
|
@@ -54,10 +61,10 @@ export class HzObjectModel extends BaseInstanceModel {
|
|
|
54
61
|
processRawData: o => this.processRawData(o)
|
|
55
62
|
},
|
|
56
63
|
columns: [
|
|
57
|
-
{field: 'displayName'
|
|
64
|
+
{field: 'displayName'},
|
|
58
65
|
{field: 'owner'},
|
|
59
66
|
{field: 'type'},
|
|
60
|
-
{field: 'size', displayName: '
|
|
67
|
+
{field: 'size', displayName: 'Entries', ...Col.number},
|
|
61
68
|
{
|
|
62
69
|
...timestampNoYear,
|
|
63
70
|
field: 'lastUpdateTime',
|
|
@@ -62,8 +62,7 @@ const detailsPanel = hoistCmp.factory({
|
|
|
62
62
|
}
|
|
63
63
|
});
|
|
64
64
|
|
|
65
|
-
const bbar = hoistCmp.factory({
|
|
66
|
-
model: uses(HzObjectModel),
|
|
65
|
+
const bbar = hoistCmp.factory<HzObjectModel>({
|
|
67
66
|
render({model}) {
|
|
68
67
|
return toolbar(
|
|
69
68
|
recordActionBar({
|
|
@@ -89,7 +88,8 @@ const bbar = hoistCmp.factory({
|
|
|
89
88
|
],
|
|
90
89
|
width: 125,
|
|
91
90
|
bind: 'groupBy',
|
|
92
|
-
hideDropdownIndicator: true
|
|
91
|
+
hideDropdownIndicator: true,
|
|
92
|
+
enableFilter: false
|
|
93
93
|
}),
|
|
94
94
|
storeFilterField({matchMode: 'any'}),
|
|
95
95
|
exportButton()
|
|
@@ -8,11 +8,12 @@ import {AppModel} from '@xh/hoist/admin/AppModel';
|
|
|
8
8
|
import {MemoryMonitorModel} from '@xh/hoist/admin/tabs/cluster/memory/MemoryMonitorModel';
|
|
9
9
|
import {chart} from '@xh/hoist/cmp/chart';
|
|
10
10
|
import {grid, gridCountLabel} from '@xh/hoist/cmp/grid';
|
|
11
|
-
import {filler} from '@xh/hoist/cmp/layout';
|
|
11
|
+
import {filler, vframe} from '@xh/hoist/cmp/layout';
|
|
12
12
|
import {creates, hoistCmp} from '@xh/hoist/core';
|
|
13
13
|
import {button, exportButton} from '@xh/hoist/desktop/cmp/button';
|
|
14
14
|
import {errorMessage} from '@xh/hoist/desktop/cmp/error';
|
|
15
15
|
import {panel} from '@xh/hoist/desktop/cmp/panel';
|
|
16
|
+
import {toolbar} from '@xh/hoist/desktop/cmp/toolbar';
|
|
16
17
|
import {Icon} from '@xh/hoist/icon';
|
|
17
18
|
import {isNil} from 'lodash';
|
|
18
19
|
|
|
@@ -26,40 +27,8 @@ export const memoryMonitorPanel = hoistCmp.factory({
|
|
|
26
27
|
});
|
|
27
28
|
}
|
|
28
29
|
|
|
29
|
-
const {readonly} = AppModel,
|
|
30
|
-
dumpDisabled = isNil(model.heapDumpDir);
|
|
31
30
|
return panel({
|
|
32
|
-
|
|
33
|
-
button({
|
|
34
|
-
text: 'Take Snapshot',
|
|
35
|
-
icon: Icon.camera(),
|
|
36
|
-
omit: readonly,
|
|
37
|
-
onClick: () => model.takeSnapshotAsync()
|
|
38
|
-
}),
|
|
39
|
-
'-',
|
|
40
|
-
button({
|
|
41
|
-
text: 'Request GC',
|
|
42
|
-
icon: Icon.trash(),
|
|
43
|
-
omit: readonly,
|
|
44
|
-
onClick: () => model.requestGcAsync()
|
|
45
|
-
}),
|
|
46
|
-
'-',
|
|
47
|
-
button({
|
|
48
|
-
text: 'Dump Heap',
|
|
49
|
-
icon: Icon.fileArchive(),
|
|
50
|
-
omit: readonly,
|
|
51
|
-
disabled: dumpDisabled,
|
|
52
|
-
tooltip: dumpDisabled
|
|
53
|
-
? 'Missing required config xhMemoryMonitoringConfig.heapDumpDir'
|
|
54
|
-
: null,
|
|
55
|
-
onClick: () => model.dumpHeapAsync()
|
|
56
|
-
}),
|
|
57
|
-
filler(),
|
|
58
|
-
gridCountLabel({unit: 'snapshot'}),
|
|
59
|
-
'-',
|
|
60
|
-
exportButton()
|
|
61
|
-
],
|
|
62
|
-
items: [
|
|
31
|
+
item: vframe(
|
|
63
32
|
grid(),
|
|
64
33
|
panel({
|
|
65
34
|
modelConfig: {
|
|
@@ -68,9 +37,48 @@ export const memoryMonitorPanel = hoistCmp.factory({
|
|
|
68
37
|
},
|
|
69
38
|
item: chart()
|
|
70
39
|
})
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
ref: model.viewRef
|
|
40
|
+
),
|
|
41
|
+
bbar: bbar(),
|
|
42
|
+
ref: model.viewRef,
|
|
43
|
+
mask: 'onLoad'
|
|
74
44
|
});
|
|
75
45
|
}
|
|
76
46
|
});
|
|
47
|
+
|
|
48
|
+
const bbar = hoistCmp.factory<MemoryMonitorModel>({
|
|
49
|
+
render({model}) {
|
|
50
|
+
const {readonly} = AppModel,
|
|
51
|
+
dumpDisabled = isNil(model.heapDumpDir);
|
|
52
|
+
|
|
53
|
+
return toolbar(
|
|
54
|
+
button({
|
|
55
|
+
text: 'Take Snapshot',
|
|
56
|
+
icon: Icon.camera(),
|
|
57
|
+
omit: readonly,
|
|
58
|
+
onClick: () => model.takeSnapshotAsync()
|
|
59
|
+
}),
|
|
60
|
+
'-',
|
|
61
|
+
button({
|
|
62
|
+
text: 'Request GC',
|
|
63
|
+
icon: Icon.trash(),
|
|
64
|
+
omit: readonly,
|
|
65
|
+
onClick: () => model.requestGcAsync()
|
|
66
|
+
}),
|
|
67
|
+
'-',
|
|
68
|
+
button({
|
|
69
|
+
text: 'Dump Heap',
|
|
70
|
+
icon: Icon.fileArchive(),
|
|
71
|
+
omit: readonly,
|
|
72
|
+
disabled: dumpDisabled,
|
|
73
|
+
tooltip: dumpDisabled
|
|
74
|
+
? 'Missing required config xhMemoryMonitoringConfig.heapDumpDir'
|
|
75
|
+
: null,
|
|
76
|
+
onClick: () => model.dumpHeapAsync()
|
|
77
|
+
}),
|
|
78
|
+
filler(),
|
|
79
|
+
gridCountLabel({unit: 'snapshot'}),
|
|
80
|
+
'-',
|
|
81
|
+
exportButton()
|
|
82
|
+
);
|
|
83
|
+
}
|
|
84
|
+
});
|
|
@@ -2,8 +2,10 @@ import { BaseInstanceModel } from '@xh/hoist/admin/tabs/cluster/BaseInstanceMode
|
|
|
2
2
|
import { GridModel } from '@xh/hoist/cmp/grid';
|
|
3
3
|
import { LoadSpec } from '@xh/hoist/core';
|
|
4
4
|
import { RecordActionSpec } from '@xh/hoist/data';
|
|
5
|
+
import { PanelModel } from '@xh/hoist/desktop/cmp/panel';
|
|
5
6
|
export declare class HzObjectModel extends BaseInstanceModel {
|
|
6
7
|
groupBy: 'type' | 'owner';
|
|
8
|
+
detailPanelModel: PanelModel;
|
|
7
9
|
clearAction: RecordActionSpec;
|
|
8
10
|
gridModel: GridModel;
|
|
9
11
|
constructor();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xh/hoist",
|
|
3
|
-
"version": "69.0.0-SNAPSHOT.
|
|
3
|
+
"version": "69.0.0-SNAPSHOT.1728502091807",
|
|
4
4
|
"description": "Hoist add-on for building and deploying React Applications.",
|
|
5
5
|
"repository": "github:xh/hoist-react",
|
|
6
6
|
"homepage": "https://xh.io",
|