@hpcc-js/eclwatch 3.2.20 → 3.3.1

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/dist/index.js CHANGED
@@ -1,7 +1,5 @@
1
1
  var __defProp = Object.defineProperty;
2
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3
2
  var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
4
- var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
5
3
  import { Editor } from "@hpcc-js/codemirror";
6
4
  import { Workunit, BaseScope, Result, WUStateID } from "@hpcc-js/comms";
7
5
  import { SplitPanel } from "@hpcc-js/phosphor";
@@ -16,12 +14,12 @@ const PKG_NAME = "@hpcc-js/eclwatch";
16
14
  const PKG_VERSION = "3.1.1";
17
15
  const BUILD_VERSION = "3.2.1";
18
16
  const _ECLArchiveViewer = class _ECLArchiveViewer extends SplitPanel {
17
+ _prevHash;
18
+ _contentStr;
19
+ _directoryPane = new DirectoryTree();
20
+ _fileEditorPane = new Editor().text("");
19
21
  constructor() {
20
22
  super("horizontal");
21
- __publicField(this, "_prevHash");
22
- __publicField(this, "_contentStr");
23
- __publicField(this, "_directoryPane", new DirectoryTree());
24
- __publicField(this, "_fileEditorPane", new Editor().text(""));
25
23
  this._directoryPane.rowClick = (text) => {
26
24
  this._fileEditorPane.text(text).render();
27
25
  };
@@ -129,18 +127,15 @@ const _LegendVertex = class _LegendVertex extends Vertex {
129
127
  __name(_LegendVertex, "LegendVertex");
130
128
  let LegendVertex = _LegendVertex;
131
129
  const _WUGraphLegend = class _WUGraphLegend extends Legend {
132
- constructor() {
133
- super(...arguments);
134
- __publicField(this, "icon", local());
135
- __publicField(this, "_disabled2", {
136
- /* TODO: Default some to disabled?
137
- 43: true,
138
- 71: true,
139
- 82: true,
140
- 88: true
141
- */
142
- });
143
- }
130
+ icon = local();
131
+ _disabled2 = {
132
+ /* TODO: Default some to disabled?
133
+ 43: true,
134
+ 71: true,
135
+ 82: true,
136
+ 88: true
137
+ */
138
+ };
144
139
  disabled(_) {
145
140
  if (!arguments.length) {
146
141
  const retVal = [];
@@ -200,74 +195,109 @@ function faCharFactory(kind) {
200
195
  switch (kind) {
201
196
  case "2":
202
197
  return "";
198
+ // Disk Write
203
199
  case "3":
204
200
  return "";
201
+ // sort
205
202
  case "5":
206
203
  return "";
204
+ // Filter
207
205
  case "6":
208
206
  return "";
207
+ // Split
209
208
  case "12":
210
209
  return "";
210
+ // First N
211
211
  case "15":
212
212
  return "";
213
+ // Lightweight Join
213
214
  case "17":
214
215
  return "";
216
+ // Lookup Join
215
217
  case "22":
216
218
  return "";
219
+ // Pipe Output
217
220
  case "23":
218
221
  return "";
222
+ // Funnel
219
223
  case "25":
220
224
  return "";
225
+ // Inline Dataset
221
226
  case "26":
222
227
  return "";
228
+ // distribute
223
229
  case "29":
224
230
  return "";
231
+ // Store Internal Result
225
232
  case "36":
226
233
  return "";
234
+ // If
227
235
  case "44":
228
236
  return "";
237
+ // write csv
229
238
  case "47":
230
239
  return "";
240
+ // write
231
241
  case "54":
232
242
  return "";
243
+ // Workunit Read
233
244
  case "56":
234
245
  return "";
246
+ // Spill
235
247
  case "59":
236
248
  return "";
249
+ // Merge
237
250
  case "61":
238
251
  return "";
252
+ // write xml
239
253
  case "82":
240
254
  return "";
255
+ // Projected Disk Read Spill
241
256
  case "88":
242
257
  return "";
258
+ // Projected Disk Read Spill
243
259
  case "92":
244
260
  return "";
261
+ // Limted Index Read
245
262
  case "93":
246
263
  return "";
264
+ // Limted Index Read
247
265
  case "99":
248
266
  return "";
267
+ // CSV Read
249
268
  case "105":
250
269
  return "";
270
+ // CSV Read
251
271
  case "7":
252
272
  return "";
273
+ // Project
253
274
  case "9":
254
275
  return "";
276
+ // Local Iterate
255
277
  case "16":
256
278
  return "";
279
+ // Output Internal
257
280
  case "19":
258
281
  return "";
282
+ // Hash Distribute
259
283
  case "21":
260
284
  return "";
285
+ // Normalize
261
286
  case "35":
262
287
  return "";
288
+ // CSV Write
263
289
  case "37":
264
290
  return "";
291
+ // Index Write
265
292
  case "71":
266
293
  return "";
294
+ // Disk Read Spill
267
295
  case "133":
268
296
  return "";
297
+ // Inline Dataset
269
298
  case "148":
270
299
  return "";
300
+ // Inline Dataset
271
301
  case "168":
272
302
  return "";
273
303
  }
@@ -275,16 +305,16 @@ function faCharFactory(kind) {
275
305
  }
276
306
  __name(faCharFactory, "faCharFactory");
277
307
  const _WUScopeController = class _WUScopeController {
308
+ graphDB;
309
+ subgraphsMap = {};
310
+ rSubgraphsMap = {};
311
+ verticesMap = {};
312
+ rVerticesMap = {};
313
+ edgesMap = {};
314
+ rEdgesMap = {};
315
+ kindMap = {};
316
+ _disabled = {};
278
317
  constructor() {
279
- __publicField(this, "graphDB");
280
- __publicField(this, "subgraphsMap", {});
281
- __publicField(this, "rSubgraphsMap", {});
282
- __publicField(this, "verticesMap", {});
283
- __publicField(this, "rVerticesMap", {});
284
- __publicField(this, "edgesMap", {});
285
- __publicField(this, "rEdgesMap", {});
286
- __publicField(this, "kindMap", {});
287
- __publicField(this, "_disabled", {});
288
318
  }
289
319
  clear() {
290
320
  this.subgraphsMap = {};
@@ -694,45 +724,43 @@ const _WUScopeController = class _WUScopeController {
694
724
  __name(_WUScopeController, "WUScopeController");
695
725
  let WUScopeController = _WUScopeController;
696
726
  const _WUGraph = class _WUGraph extends ChartPanel {
727
+ _partialAll = new Button().faChar("fa-window-restore").tooltip("Partial All").on("click", () => {
728
+ this.stateClick(this._partialAll);
729
+ });
730
+ _maxAll = new Button().faChar("fa-window-maximize").tooltip("Max All").on("click", () => {
731
+ this.stateClick(this._maxAll);
732
+ });
733
+ _toggleGraph = new ToggleButton().faChar("fa-chain").tooltip("Graph").selected(true).on("click", () => {
734
+ this.viewClick(this._toggleGraph);
735
+ });
736
+ _toggleActivities = new ToggleButton().faChar("fa-table").tooltip("Activitiies").selected(false).on("click", () => {
737
+ this.viewClick(this._toggleActivities);
738
+ });
739
+ _toggleEdges = new ToggleButton().faChar("fa-table").tooltip("Edges").selected(false).on("click", () => {
740
+ this.viewClick(this._toggleEdges);
741
+ });
742
+ _toggleSubgraphs = new ToggleButton().faChar("fa-table").tooltip("Subgraphs").selected(false).on("click", () => {
743
+ this.viewClick(this._toggleSubgraphs);
744
+ });
745
+ _graph = new Graph().layout("Hierarchy").applyScaleOnLayout(true).showToolbar(false).allowDragging(false);
746
+ _activities = new Table().pagination(false);
747
+ _edges = new Table().pagination(false);
748
+ _subgraphs = new Table().pagination(false);
749
+ _legend = new WUGraphLegend(this).on("click", (kind) => {
750
+ this.render();
751
+ }).on("mouseover", (kind) => {
752
+ const verticesMap = {};
753
+ for (const vertex of this._gc.vertices(kind)) {
754
+ verticesMap[vertex.id()] = true;
755
+ }
756
+ this._graph.highlightVerticies(verticesMap);
757
+ }).on("mouseout", (kind) => {
758
+ this._graph.highlightVerticies();
759
+ });
760
+ _view = new Carousel().widgets([this._graph, this._activities, this._edges, this._subgraphs]);
761
+ _gc = new WUScopeController();
697
762
  constructor() {
698
763
  super();
699
- __publicField(this, "_partialAll", new Button().faChar("fa-window-restore").tooltip("Partial All").on("click", () => {
700
- this.stateClick(this._partialAll);
701
- }));
702
- __publicField(this, "_maxAll", new Button().faChar("fa-window-maximize").tooltip("Max All").on("click", () => {
703
- this.stateClick(this._maxAll);
704
- }));
705
- __publicField(this, "_toggleGraph", new ToggleButton().faChar("fa-chain").tooltip("Graph").selected(true).on("click", () => {
706
- this.viewClick(this._toggleGraph);
707
- }));
708
- __publicField(this, "_toggleActivities", new ToggleButton().faChar("fa-table").tooltip("Activitiies").selected(false).on("click", () => {
709
- this.viewClick(this._toggleActivities);
710
- }));
711
- __publicField(this, "_toggleEdges", new ToggleButton().faChar("fa-table").tooltip("Edges").selected(false).on("click", () => {
712
- this.viewClick(this._toggleEdges);
713
- }));
714
- __publicField(this, "_toggleSubgraphs", new ToggleButton().faChar("fa-table").tooltip("Subgraphs").selected(false).on("click", () => {
715
- this.viewClick(this._toggleSubgraphs);
716
- }));
717
- __publicField(this, "_graph", new Graph().layout("Hierarchy").applyScaleOnLayout(true).showToolbar(false).allowDragging(false));
718
- __publicField(this, "_activities", new Table().pagination(false));
719
- __publicField(this, "_edges", new Table().pagination(false));
720
- __publicField(this, "_subgraphs", new Table().pagination(false));
721
- __publicField(this, "_legend", new WUGraphLegend(this).on("click", (kind) => {
722
- this.render();
723
- }).on("mouseover", (kind) => {
724
- const verticesMap = {};
725
- for (const vertex of this._gc.vertices(kind)) {
726
- verticesMap[vertex.id()] = true;
727
- }
728
- this._graph.highlightVerticies(verticesMap);
729
- }).on("mouseout", (kind) => {
730
- this._graph.highlightVerticies();
731
- }));
732
- __publicField(this, "_view", new Carousel().widgets([this._graph, this._activities, this._edges, this._subgraphs]));
733
- __publicField(this, "_gc", new WUScopeController());
734
- __publicField(this, "_prevHashSum");
735
- __publicField(this, "_prevScopeGraph");
736
764
  this.topOverlay(false);
737
765
  this.widget(this._view);
738
766
  const buttons = [
@@ -795,6 +823,8 @@ const _WUGraph = class _WUGraph extends ChartPanel {
795
823
  this.render((w) => {
796
824
  });
797
825
  }
826
+ _prevHashSum;
827
+ _prevScopeGraph;
798
828
  fetchScopeGraph() {
799
829
  const hash = hashSum({
800
830
  baseUrl: this.baseUrl(),
@@ -894,14 +924,14 @@ function safeEncode(item) {
894
924
  }
895
925
  __name(safeEncode, "safeEncode");
896
926
  const _Store = class _Store {
927
+ wuResult;
928
+ schema;
929
+ _columns;
930
+ _cache = {};
931
+ rowFormatter;
932
+ _filter = {};
933
+ onError;
897
934
  constructor(wuResult, schema, renderHtml, filter = {}, onError) {
898
- __publicField(this, "wuResult");
899
- __publicField(this, "schema");
900
- __publicField(this, "_columns");
901
- __publicField(this, "_cache", {});
902
- __publicField(this, "rowFormatter");
903
- __publicField(this, "_filter", {});
904
- __publicField(this, "onError");
905
935
  this.wuResult = wuResult;
906
936
  this.schema = schema;
907
937
  this._columns = this.schema2Columns(this.schema.root);
@@ -1065,13 +1095,10 @@ const _Store = class _Store {
1065
1095
  __name(_Store, "Store");
1066
1096
  let Store = _Store;
1067
1097
  const _WUResult = class _WUResult extends Common {
1098
+ _result;
1099
+ _localStore;
1068
1100
  constructor() {
1069
1101
  super();
1070
- __publicField(this, "_result");
1071
- __publicField(this, "_localStore");
1072
- __publicField(this, "_prevResultHash");
1073
- __publicField(this, "_prevStoreHash");
1074
- __publicField(this, "_prevQueryHash");
1075
1102
  this.renderHtml(false);
1076
1103
  }
1077
1104
  hashSum(opts = {}) {
@@ -1084,9 +1111,11 @@ const _WUResult = class _WUResult extends Common {
1084
1111
  logicalFile: this.logicalFile(),
1085
1112
  userID: this.user(),
1086
1113
  password: this.password(),
1114
+ bypassCache: this.bypassCache(),
1087
1115
  ...opts
1088
1116
  });
1089
1117
  }
1118
+ _prevResultHash;
1090
1119
  calcResult() {
1091
1120
  const resultHash = this.hashSum();
1092
1121
  if (this._prevResultHash !== resultHash) {
@@ -1105,6 +1134,9 @@ const _WUResult = class _WUResult extends Common {
1105
1134
  } else if (this.logicalFile()) {
1106
1135
  this._result = Result.attachLogicalFile(opts, "", this.logicalFile());
1107
1136
  }
1137
+ if (this._result && this.bypassCache()) {
1138
+ this._result.bypassCache(this.bypassCache());
1139
+ }
1108
1140
  }
1109
1141
  return this._result;
1110
1142
  }
@@ -1115,6 +1147,8 @@ const _WUResult = class _WUResult extends Common {
1115
1147
  }
1116
1148
  return Promise.resolve([]);
1117
1149
  }
1150
+ _prevStoreHash;
1151
+ _prevQueryHash;
1118
1152
  update(domNode, element) {
1119
1153
  super.update(domNode, element);
1120
1154
  const storeHash = this.hashSum({
@@ -1126,15 +1160,14 @@ const _WUResult = class _WUResult extends Common {
1126
1160
  const result = this.calcResult();
1127
1161
  if (result) {
1128
1162
  result.fetchXMLSchema().then((schema) => {
1129
- var _a, _b;
1130
1163
  this._localStore = new Store(result, schema, this.renderHtml(), this.filter(), (msg) => {
1131
1164
  if (this._dgrid) {
1132
1165
  this._dgrid.noDataMessage = `<span class='dojoxGridNoData'>${msg}</span>`;
1133
1166
  this._dgrid.refresh();
1134
1167
  }
1135
1168
  });
1136
- (_a = this._dgrid) == null ? void 0 : _a.set("columns", this._localStore.columns());
1137
- (_b = this._dgrid) == null ? void 0 : _b.set("collection", this._localStore);
1169
+ this._dgrid?.set("columns", this._localStore.columns());
1170
+ this._dgrid?.set("collection", this._localStore);
1138
1171
  });
1139
1172
  }
1140
1173
  }
@@ -1154,6 +1187,7 @@ WUResult.prototype.publish("sequence", void 0, "number", "Sequence Number");
1154
1187
  WUResult.prototype.publish("nodeGroup", "", "string", "NodeGroup");
1155
1188
  WUResult.prototype.publish("logicalFile", "", "string", "Logical File Name");
1156
1189
  WUResult.prototype.publish("filter", {}, "object", "Filter");
1190
+ WUResult.prototype.publish("bypassCache", false, "boolean", "Bypass cached results");
1157
1191
  var STATUS = /* @__PURE__ */ ((STATUS2) => {
1158
1192
  STATUS2["CREATE"] = "Created";
1159
1193
  STATUS2["COMPILE"] = "Compiled";
@@ -1169,17 +1203,17 @@ var STATUS_ACTIVE = /* @__PURE__ */ ((STATUS_ACTIVE2) => {
1169
1203
  return STATUS_ACTIVE2;
1170
1204
  })(STATUS_ACTIVE || {});
1171
1205
  const _WUStatus = class _WUStatus extends Graph {
1206
+ _wu;
1207
+ _wuHandle;
1208
+ _create;
1209
+ _compile;
1210
+ _execute;
1211
+ _complete;
1172
1212
  constructor() {
1173
1213
  super();
1174
- __publicField(this, "_wu");
1175
- __publicField(this, "_wuHandle");
1176
- __publicField(this, "_create");
1177
- __publicField(this, "_compile");
1178
- __publicField(this, "_execute");
1179
- __publicField(this, "_complete");
1180
- __publicField(this, "_prevHash");
1181
1214
  this.zoomable(false).zoomToFitLimit(1).layout("Hierarchy").hierarchyRankDirection("LR").showToolbar(false).allowDragging(false);
1182
1215
  }
1216
+ _prevHash;
1183
1217
  attachWorkunit() {
1184
1218
  const hash = hashSum({
1185
1219
  baseUrl: this.baseUrl(),
@@ -1337,14 +1371,14 @@ WUStatus.prototype.publish("baseUrl", "", "string", "HPCC Platform Base URL");
1337
1371
  WUStatus.prototype.publish("wuid", "", "string", "Workunit ID");
1338
1372
  const columns = ["label", "start", "end", "icon", "color", "series"];
1339
1373
  const _WUTimeline = class _WUTimeline extends ReactTimelineSeries {
1374
+ _palette = Palette.ordinal("default");
1340
1375
  constructor() {
1341
1376
  super();
1342
- __publicField(this, "_palette", Palette.ordinal("default"));
1343
- __publicField(this, "_prevHashSum");
1344
1377
  this.columns(columns).titleColumn("label").iconColumn("icon").colorColumn("color").seriesColumn("series").timePattern("%Y-%m-%dT%H:%M:%S.%LZ").tickFormat("%H:%M").tooltipTimeFormat("%H:%M:%S.%L").tooltipHTML((d) => {
1345
1378
  return d[columns.length].calcTooltip();
1346
1379
  });
1347
1380
  }
1381
+ _prevHashSum;
1348
1382
  clear() {
1349
1383
  delete this._prevHashSum;
1350
1384
  return this;