MCPcopy Create free account
hub / github.com/Effect-TS/effect / currentUsage

Function currentUsage

packages/effect/src/Pool.ts:590–596  ·  view source on GitHub ↗
(self: Pool<A, E>)

Source from the content-addressed store, hash-verified

588 )
589
590const currentUsage = <A, E>(self: Pool<A, E>) => {
591 let count = self.state.waiters
592 for (const item of self.state.items) {
593 count += item.refCount
594 }
595 return count
596}
597
598const targetSize = <A, E>(self: Pool<A, E>) => {
599 if (self.state.isShuttingDown) return 0

Callers 1

targetSizeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected