X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=src%2Findex.ts;h=ad0af4875b64cf176ba7718fec69d60403412735;hb=0274ce2ddfe129ce40ff5b322f52777449902386;hp=95ef8255d659c39e545044e05a749db6f201dad4;hpb=325f50bc1777ea44abc9736ce9d780ec0c8f90e2;p=poolifier.git diff --git a/src/index.ts b/src/index.ts index 95ef8255..ad0af487 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,26 +1,30 @@ -import { DynamicClusterPool } from './pools/cluster/dynamic' -import { FixedClusterPool } from './pools/cluster/fixed' -import { DynamicThreadPool } from './pools/thread/dynamic' -import { FixedThreadPool } from './pools/thread/fixed' -import { ClusterWorker } from './worker/cluster-worker' -import { ThreadWorker } from './worker/thread-worker' - -export type { DynamicClusterPoolOptions } from './pools/cluster/dynamic' +export { DynamicClusterPool } from './pools/cluster/dynamic' +export { FixedClusterPool } from './pools/cluster/fixed' +export type { ClusterPoolOptions } from './pools/cluster/fixed' +export { PoolEvents } from './pools/pool' export type { - FixedClusterPoolOptions, - WorkerWithMessageChannel as ClusterWorkerWithMessageChannel -} from './pools/cluster/fixed' -export type { DynamicThreadPoolOptions } from './pools/thread/dynamic' + IPool, + PoolEmitter, + PoolOptions, + PoolEvent, + TasksQueueOptions +} from './pools/pool' export type { - FixedThreadPoolOptions, - WorkerWithMessageChannel as ThreadWorkerWithMessageChannel -} from './pools/thread/fixed' -export type { WorkerOptions } from './worker/worker-options' -export { - FixedThreadPool, - FixedClusterPool, - DynamicClusterPool, - DynamicThreadPool, - ThreadWorker, - ClusterWorker -} + ErrorHandler, + ExitHandler, + IWorker, + MessageHandler, + OnlineHandler +} from './pools/worker' +export { WorkerChoiceStrategies } from './pools/selection-strategies/selection-strategies-types' +export type { + WorkerChoiceStrategy, + WorkerChoiceStrategyOptions +} from './pools/selection-strategies/selection-strategies-types' +export { DynamicThreadPool } from './pools/thread/dynamic' +export { FixedThreadPool } from './pools/thread/fixed' +export type { ThreadWorkerWithMessageChannel } from './pools/thread/fixed' +export { ClusterWorker } from './worker/cluster-worker' +export { ThreadWorker } from './worker/thread-worker' +export { KillBehaviors } from './worker/worker-options' +export type { KillBehavior, WorkerOptions } from './worker/worker-options'