You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@openwhisk.apache.org by GitBox <gi...@apache.org> on 2017/12/14 22:51:01 UTC

[GitHub] tysonnorris opened a new issue #3110: INVOKER_CORESHARE overloaded?

tysonnorris opened a new issue #3110: INVOKER_CORESHARE overloaded?
URL: https://github.com/apache/incubator-openwhisk/issues/3110
 
 
   <!--
   Do NOT share passwords, credentials or other confidential information.
   
   Before creating a new issue, please check if there is one already open that
   fits the defect you are reporting.
   If you open an issue and realize later it is a duplicate of a pre-existing
   open issue, please close yours and add a comment to the other.
   
   Issues can be created for either defects or enhancement requests. If you are a committer than please add the labels "bug" or "feature". If you are not a committer please make clear in the comments which one it is, so that committers can add these labels later.
   
   If you are reporting a defect, please edit the issue description to include the
   information shown below.
   
   If you are reporting an enhancement request, please include information on what you are trying to achieve and why that enhancement would help you.
   
   For more information about reporting issues, see
   https://github.com/apache/incubator-openwhisk/blob/master/CONTRIBUTING.md#raising-issues
   
   Use the commands below to provide key information from your environment:
   You do not have to include this information if this is a feature request.
   -->
   
   ## Environment details:
   
   * local deployment
   ## Steps to reproduce the issue:
   
   Currently INVOKER_CORESHARE config (which dictates WhiskConfig.invokerCoreShare) appears overloaded in some confusing way:
   
   1. it is used to directly set the `--cpu-shares` value on `docker run` commands
   2. it is used to indirectly set the max active containers in the ContainerPool
   
   ## Provide the expected results and outputs:
   
   Expect container CpuShares to be some value approximating a portion of 1024.0, based on coreshare+numcores and 1024.0.
   
   
   ## Provide the actual results and outputs:
   
   docker inspect locally shows e.g. `"CpuShares": 2` for stem cell containers when INVOKER_CORESHARE=2
   
   ## Additional information you deem important:
   I think this came from the invoker refactoring a while back:
   ```
   -            cpuShares = OldContainerPool.cpuShare(config),
    +            cpuShares = config.invokerCoreShare.toInt,
   ```
   where ye ole ContainerPool.cpuShare was
   ```
       private val totalShare = 1024.0 // This is a pre-defined value coming from docker and not our hard-coded value.
       def cpuShare(config: WhiskConfig) = (totalShare / getDefaultMaxActive(config)).toInt
   ```

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services