18 Dec '13, 4pm
@aleksm_ ist sehr nah dran, auch, wenn es etwas anderes ist.
There’s a problem with our application, however. If there are multiple chat clients open they won’t all be updated in real time when a message is sent. Only the client that sent the message will see the new message; all the others will have to reload the page to see the it. There are a couple of solutions to this problem. One is to have each client poll for new messages every couple of seconds of so, which isn’t the best idea. The other is to hold a socket connection open to the server on each client so that the server can push new messages as they come in so that they appear in real time. The problem with this solution is that Rails’ architecture isn’t set up to to handle long requests.