Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@travetto/worker

Package Overview
Dependencies
Maintainers
1
Versions
186
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@travetto/worker - npm Package Compare versions

Comparing version 4.0.0-rc.3 to 4.0.0-rc.4

4

package.json
{
"name": "@travetto/worker",
"version": "4.0.0-rc.3",
"version": "4.0.0-rc.4",
"description": "Process management utilities, with a focus on inter-process communication",

@@ -28,3 +28,3 @@ "keywords": [

"dependencies": {
"@travetto/base": "^4.0.0-rc.3",
"@travetto/base": "^4.0.0-rc.4",
"generic-pool": "^3.9.0"

@@ -31,0 +31,0 @@ },

@@ -1,4 +0,4 @@

import gp from 'generic-pool';
import os from 'node:os';
import timers from 'node:timers/promises';
import { Options, Pool, createPool } from 'generic-pool';

@@ -24,3 +24,3 @@ import { Env, Util } from '@travetto/base';

type WorkerInput<I, O> = (() => Worker<I, O>) | ((input: I, inputIdx: number) => Promise<O>);
type WorkPoolConfig<I, O> = gp.Options & {
type WorkPoolConfig<I, O> = Options & {
onComplete?: (output: O, input: I, finishIdx: number) => void;

@@ -42,3 +42,3 @@ onError?(ev: Error, input: I, finishIdx: number): (unknown | Promise<unknown>);

/** Build worker pool */
static #buildPool<I, O>(worker: WorkerInput<I, O>, opts?: WorkPoolConfig<I, O>): gp.Pool<Worker<I, O>> {
static #buildPool<I, O>(worker: WorkerInput<I, O>, opts?: WorkPoolConfig<I, O>): Pool<Worker<I, O>> {
let pendingAcquires = 0;

@@ -49,3 +49,3 @@

// Create the pool
const pool = gp.createPool({
const pool = createPool({
async create() {

@@ -52,0 +52,0 @@ try {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc