{"action":"closed","issue":{"url":"https://api.github.com/repos/twitter/finagle/issues/241","labels_url":"https://api.github.com/repos/twitter/finagle/issues/241/labels{/name}","comments_url":"https://api.github.com/repos/twitter/finagle/issues/241/comments","events_url":"https://api.github.com/repos/twitter/finagle/issues/241/events","html_url":"https://github.com/twitter/finagle/issues/241","id":27285976,"number":241,"title":"high memory utilization in RequestSemaphoreFilter ","user":{"login":"azenkov","id":3092945,"avatar_url":"https://avatars.githubusercontent.com/u/3092945?v=3","gravatar_id":"","url":"https://api.github.com/users/azenkov","html_url":"https://github.com/azenkov","followers_url":"https://api.github.com/users/azenkov/followers","following_url":"https://api.github.com/users/azenkov/following{/other_user}","gists_url":"https://api.github.com/users/azenkov/gists{/gist_id}","starred_url":"https://api.github.com/users/azenkov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/azenkov/subscriptions","organizations_url":"https://api.github.com/users/azenkov/orgs","repos_url":"https://api.github.com/users/azenkov/repos","events_url":"https://api.github.com/users/azenkov/events{/privacy}","received_events_url":"https://api.github.com/users/azenkov/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2014-02-10T17:52:16Z","updated_at":"2015-02-04T19:53:23Z","closed_at":"2015-02-04T19:53:23Z","body":"I was profiling finagle server to find a a reason for OOM exception we saw on or production servers. I was able to narrow it down to RequestSemaphoreFilter. We are using .maxConcurrentRequests(4)  on our ServerBuilder.\r\nLooks like the reason for a high memory consumption is that RequestSemaphoreFilter holds references to request object for way too long. Our requests can get very big in hundreds of MB and when RequestSemaphoreFilter kepps holding hundreds of request objects in its waitq ArrayDeque server crushes with OOM. \r\nIs this expected behavior or a bug?\r\n\r\nwe saw a big jump in memory utilization. After profil"}}