@sentio/runtime 2.57.10-rc.4 → 2.57.10-rc.5

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/lib/index.d.ts CHANGED
@@ -484,7 +484,6 @@ interface ExecutionConfig_DecoderWorkerConfig {
484
484
  enabled: boolean;
485
485
  workerCount?: number | undefined;
486
486
  skipWhenDecodeFailed?: boolean | undefined;
487
- recordTiming?: boolean | undefined;
488
487
  }
489
488
  declare const ExecutionConfig_DecoderWorkerConfig: {
490
489
  encode(message: ExecutionConfig_DecoderWorkerConfig, writer?: _m0.Writer): _m0.Writer;
@@ -634,11 +633,10 @@ declare const processMetrics: {
634
633
  processor_rpc_duration: H;
635
634
  processor_rpc_queue_duration: H;
636
635
  processor_template_instance_count: C;
637
- processor_worker_run_time: G;
638
- processor_worker_wait_time: G;
639
- processor_worker_utilization: G;
636
+ processor_worker_run_time: C;
637
+ processor_worker_wait_time: C;
640
638
  processor_worker_queue_size: G;
641
- processor_worker_completed: G;
639
+ processor_worker_completed: C;
642
640
  stats(): {
643
641
  process_binding_count: number;
644
642
  process_binding_time: number;
@@ -655,7 +653,6 @@ declare const processMetrics: {
655
653
  processor_template_instance_count: number;
656
654
  processor_worker_run_time: number;
657
655
  processor_worker_wait_time: number;
658
- processor_worker_utilization: number;
659
656
  processor_worker_queue_size: number;
660
657
  processor_worker_completed: number;
661
658
  };
package/lib/index.js CHANGED
@@ -20,7 +20,7 @@ import {
20
20
  processMetrics,
21
21
  providerMetrics,
22
22
  timeoutError
23
- } from "./chunk-3P7ZNKVN.js";
23
+ } from "./chunk-W4Q3Q5DX.js";
24
24
 
25
25
  // src/state.ts
26
26
  var State = class _State {
@@ -47,7 +47,7 @@ import {
47
47
  require_minimal,
48
48
  require_src,
49
49
  trace
50
- } from "./chunk-3P7ZNKVN.js";
50
+ } from "./chunk-W4Q3Q5DX.js";
51
51
 
52
52
  // ../../node_modules/.pnpm/universalify@2.0.1/node_modules/universalify/index.js
53
53
  var require_universalify = __commonJS({
@@ -39396,6 +39396,28 @@ var httpServer = http2.createServer(async function(req, res) {
39396
39396
  // const metrics = await mergedRegistry.metrics()
39397
39397
  // res.write(metrics)
39398
39398
  // break
39399
+ case "/heap": {
39400
+ try {
39401
+ const file = "/tmp/" + Date.now() + ".heapsnapshot";
39402
+ const session = new Session();
39403
+ const fd = import_fs_extra2.default.openSync(file, "w");
39404
+ session.connect();
39405
+ session.on("HeapProfiler.addHeapSnapshotChunk", (m) => {
39406
+ import_fs_extra2.default.writeSync(fd, m.params.chunk);
39407
+ });
39408
+ await session.post("HeapProfiler.takeHeapSnapshot");
39409
+ session.disconnect();
39410
+ import_fs_extra2.default.closeSync(fd);
39411
+ const readStream = import_fs_extra2.default.createReadStream(file);
39412
+ res.writeHead(200, { "Content-Type": "application/json" });
39413
+ readStream.pipe(res);
39414
+ res.end();
39415
+ } catch {
39416
+ res.writeHead(500);
39417
+ res.end();
39418
+ }
39419
+ break;
39420
+ }
39399
39421
  case "/profile": {
39400
39422
  try {
39401
39423
  const profileTime = parseInt(queries.get("t") || "1000", 10) || 1e3;