{"action":"created","issue":{"url":"https://api.github.com/repos/ptaoussanis/sente/issues/265","repository_url":"https://api.github.com/repos/ptaoussanis/sente","labels_url":"https://api.github.com/repos/ptaoussanis/sente/issues/265/labels{/name}","comments_url":"https://api.github.com/repos/ptaoussanis/sente/issues/265/comments","events_url":"https://api.github.com/repos/ptaoussanis/sente/issues/265/events","html_url":"https://github.com/ptaoussanis/sente/issues/265","id":177125252,"number":265,"title":"Scalability issues / handling many simultaneous users?","user":{"login":"luposlip","id":763627,"avatar_url":"https://avatars.githubusercontent.com/u/763627?v=3","gravatar_id":"","url":"https://api.github.com/users/luposlip","html_url":"https://github.com/luposlip","followers_url":"https://api.github.com/users/luposlip/followers","following_url":"https://api.github.com/users/luposlip/following{/other_user}","gists_url":"https://api.github.com/users/luposlip/gists{/gist_id}","starred_url":"https://api.github.com/users/luposlip/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/luposlip/subscriptions","organizations_url":"https://api.github.com/users/luposlip/orgs","repos_url":"https://api.github.com/users/luposlip/repos","events_url":"https://api.github.com/users/luposlip/events{/privacy}","received_events_url":"https://api.github.com/users/luposlip/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/ptaoussanis/sente/labels/question/usage","name":"question/usage","color":"d4c5f9"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":23,"created_at":"2016-09-15T09:06:54Z","updated_at":"2016-09-22T12:47:42Z","closed_at":null,"body":"Hi!\r\n\r\nI'm using Sente in a startup, where everything has gone just fine in our very small test scenarios with 5-6 people. Yesterday we had a demonstration, and [UPDATE] the websocket stopped responding to incoming events at around 15-20 simultaneous connections.\r\n\r\nAdmittedly I haven't done much to limit the amount of work done for each socket event (such as sending back an `:ack` and spawning work to another thread etc.). But then again - it's only 20 users - and all the events cause no more than at most 50ms of work (most in the area around 50-500ns).\r\n\r\nI don't care much (at this point) about user wait time. It doesn't matter if the users have to wait for a couple of seconds before they get the returned data from the socket. What worries me is that the socket simply cease to work. There's nothing to see in any log file. Client browser sends its frames to the server, but the socket just act as a black hole.\r\n\r\nThe server in general works fine though, because the async (AJAX) login/logoff, user activation and other AJAX based stuff works perfectly.\r\n\r\nThe server uses:\r\n```\r\n                 [org.clojure/clojure \"1.9.0-alpha10\"]\r\n                 [org.clojure/core.async \"0.2.385\"]\r\n                 [http-kit \"2.2.0\"]\r\n                 [ring/ring-core \"1.5.0\"]\r\n                 [ring/ring-devel \"1.5.0\"]\r\n                 [ring/ring-defaults \"0.2.1\"]\r\n                 [com.taoensso/encore \"2.80.1\"]\r\n                 [com.taoensso/timbre \"4.7.4\"]\r\n                 [com.taoensso/sente \"1.10.0\"]\r\n```\r\n\r\nThe client uses:\r\n```\r\n                 [org.clojure/clojure \"1.9.0-alpha10\"]\r\n                 [org.clojure/clojurescript \"1.9.227\"]\r\n                 [org.clojure/core.async \"0.2.385\"]\r\n                 [com.taoensso/encore \"2.67.1\"]\r\n                 [cljs-ajax \"0.5.8\"]\r\n                 [com.taoensso/timbre \"4.7.2\" :exclusions [com.taoensso/encore]]\r\n                 [com.taoensso/sente \"1.10.0\"]\r\n                 [reagent \"0.6.0-rc\"]\r\n                 [re-frame \"0.8.0\"]\r\n                 [secretary \"1.2.3\"]\r\n```\r\n\r\nI'm not saying this is a bug, it can easily be me using the socket in a wrong manner.\r\n\r\nBut have anyone seen this in their own setup, have any ideas on what goes wrong, or at least how I can proceed my investigation?\r\n\r\nThanks!\r\n\r\nBest,\r\nHenrik"},"comment":{"url":"https://api.github.com/repos/ptaoussanis/sente/issues/comments/248893869","html_url":"https://github.com/ptaoussanis/sente/issues/265#issuecomment-248893869","issue_url":"https://api.github.com/repos/ptaoussanis/sente/issues/265","id":248893869,"user":{"login":"luposlip","id":763627,"avatar_url":"https://avatars.githubusercontent.com/u/763627?v=3","gravatar_id":"","url":"https://api.github.com/users/luposlip","html_url":"https://github.com/luposlip","followers_url":"https://api.github.com/users/luposlip/followers","following_url":"https://api.github.com/users/luposlip/following{/other_user}","gists_url":"https://api.github.com/users/luposlip/gists{/gist_id}","starred_url":"https://api.github.com/users/luposlip/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/luposlip/subscriptions","organizations_url":"https://api.github.com/users/luposlip/orgs","repos_url":"https://api.github.com/users/luposlip/repos","events_url":"https://api.github.com/users/luposlip/events{/privacy}","received_events_url":"https://api.github.com/users/luposlip/received_events","type":"User","site_admin":false},"created_at":"2016-09-22T12:47:42Z","updated_at":"2016-09-22T12:47:42Z","body":"Well, bugger.. Now the issue happened again. I can login/logout of my app (because it uses old-school AJAX). All Sente handlers is off the main thread in around 0.2ms because I've moved them into different threads via a simple `(future (do-the-stuff ...))`.\r\n\r\nBut Sente doesn't reply at all :(\r\n\r\nSo for now - what is the suggestion? To write my own router, and debug via that?"}}
{"actor":{"display_login":"luposlip"}}