X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=examples%2Ftypescript%2Fsmtp-client-pool%2Fsrc%2Fpool.ts;h=2fc53c980b20b9f26590e3408382f88cd86ada62;hb=0fce423d00ff1b5714140f22ebc47484affa3d94;hp=ec2ec1367c5f0219dd8f685d3977e1f61d0ddf7a;hpb=f83745944c9604776dceed8361b665d48a90bb79;p=poolifier.git diff --git a/examples/typescript/smtp-client-pool/src/pool.ts b/examples/typescript/smtp-client-pool/src/pool.ts index ec2ec136..2fc53c98 100644 --- a/examples/typescript/smtp-client-pool/src/pool.ts +++ b/examples/typescript/smtp-client-pool/src/pool.ts @@ -2,7 +2,7 @@ import { fileURLToPath } from 'node:url' import { dirname, extname, join } from 'node:path' import { DynamicThreadPool, availableParallelism } from 'poolifier' import type SMTPTransport from 'nodemailer/lib/smtp-transport/index.js' -import { type WorkerData } from './types.js' +import type { WorkerData } from './types.js' const workerFile = join( dirname(fileURLToPath(import.meta.url)), @@ -12,7 +12,7 @@ const workerFile = join( export const smtpClientPool = new DynamicThreadPool< WorkerData, SMTPTransport.SentMessageInfo ->(1, availableParallelism(), workerFile, { +>(0, availableParallelism(), workerFile, { enableTasksQueue: true, tasksQueueOptions: { concurrency: 8