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 2020/06/04 22:55:13 UTC

[GitHub] [openwhisk] tysonnorris opened a new pull request #4916: Prewarm eviction variance

tysonnorris opened a new pull request #4916:
URL: https://github.com/apache/openwhisk/pull/4916


   <!--- Provide a concise summary of your changes in the Title -->
   When enabling reactive prewarm configs, if batches of prewarms are removed at the same time across invokers, we end up with a herd of container deletion and creation at the same time, especially if invokers startup at the same time.  This can cause scheduling challenges particularly in mesos or kubernetes. Given that these prewarm containers are not in use, we should try to alleviate any extra issues the prewarm state changes may cause, and allow them to linger slightly longer, if there is a benefit to the scheduling system. 
   
   ## Description
   <!--- Provide a detailed description of your changes. -->
   
   
   
   <!--- Include details of what problem you are solving and how your changes are tested. -->
   
   ## Related issue and scope
   <!--- Please include a link to a related issue if there is one. -->
   - [ ] I opened an issue to propose and discuss this change (#????)
   
   ## My changes affect the following components
   <!--- Select below all system components are affected by your change. -->
   <!--- Enter an `x` in all applicable boxes. -->
   - [ ] API
   - [ ] Controller
   - [ ] Message Bus (e.g., Kafka)
   - [ ] Loadbalancer
   - [ ] Invoker
   - [ ] Intrinsic actions (e.g., sequences, conductors)
   - [ ] Data stores (e.g., CouchDB)
   - [ ] Tests
   - [ ] Deployment
   - [ ] CLI
   - [ ] General tooling
   - [ ] Documentation
   
   ## Types of changes
   <!--- What types of changes does your code introduce? Use `x` in all the boxes that apply: -->
   - [ ] Bug fix (generally a non-breaking change which closes an issue).
   - [ ] Enhancement or new feature (adds new functionality).
   - [ ] Breaking change (a bug fix or enhancement which changes existing behavior).
   
   ## Checklist:
   <!--- Please review the points below which help you make sure you've covered all aspects of the change you're making. -->
   This PR adds some configs and sensible defaults to allow the reactive prewarm config affects to be varied across invokers to smooth out deletion and rescheduling of prewarm containers:
   ```
       prewarm-expiration-check-interval: 1 minute # period to check for prewarm expiration
       prewarm-expiration-check-interval-variance: 10 seconds # varies expiration across invokers to avoid many concurrent expirations
       prewarm-expiration-limit: 100 # number of prewarms to expire in one expiration cycle (remaining expired will be considered for expiration in next cycle)
   ```
   
   - [x] I signed an [Apache CLA](https://github.com/apache/openwhisk/blob/master/CONTRIBUTING.md).
   - [x] I reviewed the [style guides](https://github.com/apache/openwhisk/wiki/Contributing:-Git-guidelines#code-readiness) and followed the recommendations (Travis CI will check :).
   - [x] I added tests to cover my changes.
   - [ ] My changes require further changes to the documentation.
   - [ ] I updated the documentation where necessary.
   
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to 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



[GitHub] [openwhisk] style95 closed pull request #4916: Prewarm eviction variance

Posted by GitBox <gi...@apache.org>.
style95 closed pull request #4916:
URL: https://github.com/apache/openwhisk/pull/4916


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to 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



[GitHub] [openwhisk] style95 commented on a change in pull request #4916: Prewarm eviction variance

Posted by GitBox <gi...@apache.org>.
style95 commented on a change in pull request #4916:
URL: https://github.com/apache/openwhisk/pull/4916#discussion_r435650494



##########
File path: tests/src/test/scala/org/apache/openwhisk/core/containerpool/test/ContainerPoolTests.scala
##########
@@ -1195,4 +1199,24 @@ class ContainerPoolObjectTests extends FlatSpec with Matchers with MockFactory {
     pool = pool - 'first
     ContainerPool.remove(pool, MemoryLimit.STD_MEMORY) shouldBe List('second)
   }
+
+  it should "remove expired in order of expiration" in {

Review comment:
       Can we add one more test case to make sure no more than `prewarmExpirationLimit` containers are removed?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to 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



[GitHub] [openwhisk] tysonnorris merged pull request #4916: Prewarm eviction variance

Posted by GitBox <gi...@apache.org>.
tysonnorris merged pull request #4916:
URL: https://github.com/apache/openwhisk/pull/4916


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to 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