repositories
/
poolifier.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fix: fix fair share algorithm implementation
[poolifier.git]
/
src
/
pools
/
selection-strategies
/
selection-strategies-types.ts
diff --git
a/src/pools/selection-strategies/selection-strategies-types.ts
b/src/pools/selection-strategies/selection-strategies-types.ts
index 968d2996e0dfd05f7a21404c656010e2bdfcc92b..114ae8c555141fd08bff0103fcf79d62a65b5f83 100644
(file)
--- a/
src/pools/selection-strategies/selection-strategies-types.ts
+++ b/
src/pools/selection-strategies/selection-strategies-types.ts
@@
-78,16
+78,20
@@
export interface IWorkerChoiceStrategy {
readonly requiredStatistics: RequiredStatistics
/**
* Resets strategy internals.
readonly requiredStatistics: RequiredStatistics
/**
* Resets strategy internals.
+ *
+ * @returns `true` if the reset is successful, `false` otherwise.
*/
reset: () => boolean
/**
*/
reset: () => boolean
/**
- * Updates strategy internals.
+ * Updates
worker node
strategy internals.
*
* @returns `true` if the update is successful, `false` otherwise.
*/
*
* @returns `true` if the update is successful, `false` otherwise.
*/
- update: () => boolean
+ update: (
workerNodeKey: number
) => boolean
/**
* Chooses a worker node in the pool and returns its key.
/**
* Chooses a worker node in the pool and returns its key.
+ *
+ * @returns The worker node key.
*/
choose: () => number
/**
*/
choose: () => number
/**