{"action":"created","issue":{"url":"https://api.github.com/repos/kubernetes/kubernetes/issues/28986","repository_url":"https://api.github.com/repos/kubernetes/kubernetes","labels_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/28986/labels{/name}","comments_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/28986/comments","events_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/28986/events","html_url":"https://github.com/kubernetes/kubernetes/issues/28986","id":165716862,"number":28986,"title":"Memory based autoscaler","user":{"login":"slaskawi","id":8417158,"avatar_url":"https://avatars.githubusercontent.com/u/8417158?v=3","gravatar_id":"","url":"https://api.github.com/users/slaskawi","html_url":"https://github.com/slaskawi","followers_url":"https://api.github.com/users/slaskawi/followers","following_url":"https://api.github.com/users/slaskawi/following{/other_user}","gists_url":"https://api.github.com/users/slaskawi/gists{/gist_id}","starred_url":"https://api.github.com/users/slaskawi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/slaskawi/subscriptions","organizations_url":"https://api.github.com/users/slaskawi/orgs","repos_url":"https://api.github.com/users/slaskawi/repos","events_url":"https://api.github.com/users/slaskawi/events{/privacy}","received_events_url":"https://api.github.com/users/slaskawi/received_events","type":"User","site_admin":false},"labels":[{"id":238245616,"url":"https://api.github.com/repos/kubernetes/kubernetes/labels/area/autoscaling","name":"area/autoscaling","color":"5319e7","default":false},{"id":244613097,"url":"https://api.github.com/repos/kubernetes/kubernetes/labels/team/control-plane","name":"team/control-plane","color":"d2b48c","default":false}],"state":"open","locked":false,"assignee":{"login":"jszczepkowski","id":10820769,"avatar_url":"https://avatars.githubusercontent.com/u/10820769?v=3","gravatar_id":"","url":"https://api.github.com/users/jszczepkowski","html_url":"https://github.com/jszczepkowski","followers_url":"https://api.github.com/users/jszczepkowski/followers","following_url":"https://api.github.com/users/jszczepkowski/following{/other_user}","gists_url":"https://api.github.com/users/jszczepkowski/gists{/gist_id}","starred_url":"https://api.github.com/users/jszczepkowski/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jszczepkowski/subscriptions","organizations_url":"https://api.github.com/users/jszczepkowski/orgs","repos_url":"https://api.github.com/users/jszczepkowski/repos","events_url":"https://api.github.com/users/jszczepkowski/events{/privacy}","received_events_url":"https://api.github.com/users/jszczepkowski/received_events","type":"User","site_admin":false},"assignees":[{"login":"jszczepkowski","id":10820769,"avatar_url":"https://avatars.githubusercontent.com/u/10820769?v=3","gravatar_id":"","url":"https://api.github.com/users/jszczepkowski","html_url":"https://github.com/jszczepkowski","followers_url":"https://api.github.com/users/jszczepkowski/followers","following_url":"https://api.github.com/users/jszczepkowski/following{/other_user}","gists_url":"https://api.github.com/users/jszczepkowski/gists{/gist_id}","starred_url":"https://api.github.com/users/jszczepkowski/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jszczepkowski/subscriptions","organizations_url":"https://api.github.com/users/jszczepkowski/orgs","repos_url":"https://api.github.com/users/jszczepkowski/repos","events_url":"https://api.github.com/users/jszczepkowski/events{/privacy}","received_events_url":"https://api.github.com/users/jszczepkowski/received_events","type":"User","site_admin":false}],"milestone":null,"comments":10,"created_at":"2016-07-15T05:54:07Z","updated_at":"2016-11-21T10:55:02Z","closed_at":null,"body":"Hey!\n\nI've been working on integrating Kubernetes and Infinispan (Java based Data Grid, distributed cache,  in-memory key/value store) and I noticed that [Kubernetes horizontal pod autoscaling feature](http://kubernetes.io/docs/user-guide/horizontal-pod-autoscaling) operates only on CPU metrics. \n\nI would like to propose extending the Autoscaler's functionality and adding memory based thresholds (I understand that a similar effect might be achieved by using Custom Metrics but it requires a lot more configuration). The Autoscaler could possibly be configured to use a combination of two - CPU and memory metrics (but this needs a longer thought how to avoid flipping the number of replicas, probably the easiest way is to set priorities to the metrics).\n\nN.B. Since there are usually 3 types of applications - CPU, memory and I/O intensive, we could add 3rd metric to the Autoscaler - I/O. However I'm not sure how this fits into Persistent Volumes concept in Kubernetes.\n\nWhat do you think about this idea?\n\nThanks\nSebastian\n"},"comment":{"url":"https://api.github.com/repos/kubernetes/kubernetes/issues/comments/261905801","html_url":"https://github.com/kubernetes/kubernetes/issues/28986#issuecomment-261905801","issue_url":"https://api.github.com/repos/kubernetes/kubernetes/issues/28986","id":261905801,"user":{"login":"slaskawi","id":8417158,"avatar_url":"https://avatars.githubusercontent.com/u/8417158?v=3","gravatar_id":"","url":"https://api.github.com/users/slaskawi","html_url":"https://github.com/slaskawi","followers_url":"https://api.github.com/users/slaskawi/followers","following_url":"https://api.github.com/users/slaskawi/following{/other_user}","gists_url":"https://api.github.com/users/slaskawi/gists{/gist_id}","starred_url":"https://api.github.com/users/slaskawi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/slaskawi/subscriptions","organizations_url":"https://api.github.com/users/slaskawi/orgs","repos_url":"https://api.github.com/users/slaskawi/repos","events_url":"https://api.github.com/users/slaskawi/events{/privacy}","received_events_url":"https://api.github.com/users/slaskawi/received_events","type":"User","site_admin":false},"created_at":"2016-11-21T10:55:02Z","updated_at":"2016-11-21T10:55:02Z","body":"Yes, reclaiming memory from JVM is very tricky.\r\n\r\nPerhaps using HPA here is not the best approach here and I should look into [Custom Metrics](https://github.com/kubernetes/kubernetes/blob/release-1.5/docs/proposals/resource-metrics-api.md#custom-metrics-in-hpa)? Since an app (a Data Grid in my case) can estimate the data size and observe how much it dropped after adding additional node, scaling based on some custom metric could be a way out."}}
{"actor":{"display_login":"slaskawi"}}