Merge branch 'master' of github.com:poolifier/poolifier
[poolifier.git] / src / pools / thread / dynamic.ts
index e1565d00b7949b2af74cc97f44f2bdc30185e61c..7bf477dd837c0ce3e30cb65ad308c32ca0774f48 100644 (file)
@@ -1,5 +1,5 @@
 import type { PoolOptions } from '../pool'
-import { PoolType } from '../pool-internal'
+import { PoolType } from '../pool'
 import type { ThreadWorkerWithMessageChannel } from './fixed'
 import { FixedThreadPool } from './fixed'
 
@@ -41,12 +41,12 @@ export class DynamicThreadPool<
   }
 
   /** @inheritDoc */
-  public get full (): boolean {
+  protected get full (): boolean {
     return this.workerNodes.length === this.max
   }
 
   /** @inheritDoc */
-  public get busy (): boolean {
-    return this.full && this.findFreeWorkerNodeKey() === -1
+  protected get busy (): boolean {
+    return this.full && this.internalBusy()
   }
 }