{"action":"created","issue":{"url":"https://api.github.com/repos/aspnet/KestrelHttpServer/issues/611","labels_url":"https://api.github.com/repos/aspnet/KestrelHttpServer/issues/611/labels{/name}","comments_url":"https://api.github.com/repos/aspnet/KestrelHttpServer/issues/611/comments","events_url":"https://api.github.com/repos/aspnet/KestrelHttpServer/issues/611/events","html_url":"https://github.com/aspnet/KestrelHttpServer/issues/611","id":130597982,"number":611,"title":"How to specify / modify request timeout","user":{"login":"ayende","id":116915,"avatar_url":"https://avatars.githubusercontent.com/u/116915?v=3","gravatar_id":"","url":"https://api.github.com/users/ayende","html_url":"https://github.com/ayende","followers_url":"https://api.github.com/users/ayende/followers","following_url":"https://api.github.com/users/ayende/following{/other_user}","gists_url":"https://api.github.com/users/ayende/gists{/gist_id}","starred_url":"https://api.github.com/users/ayende/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ayende/subscriptions","organizations_url":"https://api.github.com/users/ayende/orgs","repos_url":"https://api.github.com/users/ayende/repos","events_url":"https://api.github.com/users/ayende/events{/privacy}","received_events_url":"https://api.github.com/users/ayende/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2016-02-02T07:17:08Z","updated_at":"2016-02-02T09:42:26Z","closed_at":null,"body":"I couldn't find a way in the API to set the request timeout, and (preferably) a way to dynamically change it.\r\nLike this:\r\n\r\nHttpContext.Current.Server.ScriptTimeout = 60 * 60 * 6;\r\n\r\nIs this possible?\r\n\r\n(Also, is this the right place to ask, is there a mailing list / forum?)"},"comment":{"url":"https://api.github.com/repos/aspnet/KestrelHttpServer/issues/comments/178476840","html_url":"https://github.com/aspnet/KestrelHttpServer/issues/611#issuecomment-178476840","issue_url":"https://api.github.com/repos/aspnet/KestrelHttpServer/issues/611","id":178476840,"user":{"login":"davidfowl","id":95136,"avatar_url":"https://avatars.githubusercontent.com/u/95136?v=3","gravatar_id":"","url":"https://api.github.com/users/davidfowl","html_url":"https://github.com/davidfowl","followers_url":"https://api.github.com/users/davidfowl/followers","following_url":"https://api.github.com/users/davidfowl/following{/other_user}","gists_url":"https://api.github.com/users/davidfowl/gists{/gist_id}","starred_url":"https://api.github.com/users/davidfowl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davidfowl/subscriptions","organizations_url":"https://api.github.com/users/davidfowl/orgs","repos_url":"https://api.github.com/users/davidfowl/repos","events_url":"https://api.github.com/users/davidfowl/events{/privacy}","received_events_url":"https://api.github.com/users/davidfowl/received_events","type":"User","site_admin":false},"created_at":"2016-02-02T09:42:25Z","updated_at":"2016-02-02T09:42:25Z","body":"> So what would be the behavior if I'm making an async operation in the request that doesn't timeout?\r\nDo we rely on the client to give up on this?\r\n\r\nCurrently yes. There's going to be a pass done to make sure there's limits for things like these (the issue I pointed you to), along with other limits (max body, max query, max headers etc).\r\n\r\n> The issue is that I have a client that is uploading a large dataset, and I had to manage this with the previous version of ASP.Net.\r\nNote having limits that I constantly have to manage is great, but on the other hand, what happens if a client open a request, write three bytes, and keep the connection open?\r\n\r\n> Do we rely on TCP to close the connection?\r\n\r\n> What happens if we have a client that send a byte per second? And thus creating tens of thousands of connections? That can cause us to hold a lot of state in memory.\r\n\r\nhttps://en.wikipedia.org/wiki/Slowloris_(computer_security)\r\n\r\nAll of these things are why we recommend that you host kestrel behind a reverse proxy like nginx. That's not to say we won't address some of these features in general. Some we will, some we want."}}