cbickel commented on a change in pull request #4011: Customize invoker use
memory for memory based loadbalancing
URL:
https://github.com/apache/incubator-openwhisk/pull/4011#discussion_r218742092
##########
File path:
core/controller/src/main/scala/whisk/core/loadBalancer/ShardingContainerPoolBalancer.scala
##########
@@ -594,22 +599,21 @@ case class ShardingContainerPoolBalancerState(
val actualSize = newSize max 1 // if a cluster size < 1 is reported, falls
back to a size of 1 (alone)
if (_clusterSize != actualSize) {
_clusterSize = actualSize
- val newTreshold = if (totalInvokerThreshold / actualSize <
MemoryLimit.minMemory) {
- logging.warn(
- this,
- s"registered controllers: ${_clusterSize}: the slots per invoker
fall below the min memory of one action.")(
- TransactionId.loadbalancer)
- MemoryLimit.minMemory // letting this fall below minMemory doesn't
make sense
- } else {
- totalInvokerThreshold / actualSize
+ _invokerSlots = _invokerSlots.zipWithIndex.map {
Review comment:
easier would be again to use the `_invokers`-list here, instead of handling
with indexes.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services