server-push

Implementing a server side push for a small number of clients

£可爱£侵袭症+ 提交于 2019-12-11 23:09:01
问题 For an web application I am working on I have the following requirements: Clients need to be able to log in via a web brower. After logging in, they will be able to change configurations (normal request/response) will be able to receive alarms sent by the server (a server side push) Now, the question is how to implement the alarms. I first thought of using some long polling approach (Comet), but as the amount of clients will definitely belimited to 5-10, I'm now thinking to go with a simpler

Refresh chat box when new msg received

倾然丶 夕夏残阳落幕 提交于 2019-12-11 17:46:56
问题 I'm new to PHP. I'm going to make a simple web application using PHP, a chat box. I don't know a better way to refresh the chat window as soon as new msg received. The only thing that comes into my mind is refreshing page frequently. I know it's not a good idea. I know how to use AJAX, so I can refresh only the chat box (without refreshing whole page). But in AJAX also, client has to send a request. Is there a way to refresh the chat box by the server when a new msg received? 回答1: The

Real-time two side push communication via GPRS?

故事扮演 提交于 2019-12-11 08:26:37
问题 Here is a use-case from the document which describes Volvo Buses' IT system: While driving a bus a driver continuously gets real-time information about the route, next stops and information about how he is doing according to the time-table. The vehicle’s deviation from the timetable, displayed in real-time, both in real figures and as a easily interpreted graphical “meter”. The information is constantly updated. All that information is sent to the on-board computer from the Central System via

Does Socket.io garantee that broadcasted events are received in order client side?

删除回忆录丶 提交于 2019-12-10 02:16:05
问题 Is there some kind of ordering mechanism in Socket.io that garanties that events are received in order by clients. Exemple : if Server emits event Evt1 to client A, Server broadcasts Evt2 to all clients. thud client A receives Evt1 then Evt2 and only in that order. I am a bit lazy reading the code and can't find my answer on the net. My guess is NO, and if it's the case how would you implement it or is there existing solutions? 回答1: No, you have to do that at the application level if you need

Java Servlet 3.0 server push: Sending data multiple times using same AsyncContext

倖福魔咒の 提交于 2019-12-08 23:35:36
问题 Lead by several examples and questions answered here ( mainly http://www.javaworld.com/javaworld/jw-02-2009/jw-02-servlet3.html?page=3 ), I want to have server sending the response multiple times to a client without completing the request. When request times out, I create another one and so on. I want to avoid long polling, since I have to recreate request every time I get the response. (and that quite isn't what async capabilities of servlet 3.0 are aiming at). I have this on server side:

What's a simple way to web-ify my command-line daemon?

↘锁芯ラ 提交于 2019-12-08 10:32:16
问题 Suppose I have a simple daemon type script that I run on my webserver. I run it in a terminal, with gnu screen, so I can keep an eye on it. That works fine (incidentally, I use this trick). But now suppose I'd like to make a web page where I can keep an eye on my script's output. What's the easiest way to do that? Notes: This is mainly for myself and a couple co-hackers so if websockets is the answer and it only works on Chrome or something, that's acceptable. This question is asking

Are there any good open-sourced comet web servers for ASP.NET MVC applications?

余生颓废 提交于 2019-12-08 01:06:05
问题 I'm looking for one that can be used to handle many long poll clients and does not create a thread for each request. 回答1: Each call to IIS (ASP.NET) page works on its own thread. A good library should not create some extra threads. So, I'm using PokeIn inside my solution(online learning) and it doesnt create extra threads. It has a free community edition but not an open source :( 回答2: you can check the source code for Pokein here edit It seems that the latest source available isn't that up to

jQuery ajax php long polling

☆樱花仙子☆ 提交于 2019-12-07 15:03:34
问题 I've been trying to get this long polling script to work but I keep getting stuck. This time I have a problem with the ajax request to the server. The php script that serves the data (running the long-poll using a loop and sleep) works perfectly fine but my jQuery script doesn't. So far I've tried using a normal $.ajax() request and a $.post() request to the script however when I do so the entire script stalls. Well the script actually loads like it is supposed to but the page shows that it

ASP.Net HTTP2 PushPromise is slow

女生的网名这么多〃 提交于 2019-12-07 13:45:02
问题 I'm trying to implement the Http2 push server functionality using "PushPromise" .NET 4.6.1, for this I have a "html extension" with Razor (we did not implement MVC only used the Razor engine to build the pages). public static IHtmlString PushPromiseStylesheet(this HtmlHelper htmlHelper, string src, bool addDomElement = true) { var context = HttpContext.Current; var path = System.Web.Optimization.Styles.Url(src).ToString(); var headers = new NameValueCollection { { "accept-encoding", context

Client side Callback in GWT

扶醉桌前 提交于 2019-12-07 05:19:06
问题 I'm trying to create a logger for a GWT application as an exercise to evaluate GWT. What I specifically want to do is have it so that I can post messages to a client side label at any point from the server side. So, if some interesting stuff has happened on the server the client can be updated. My First question is, is this possible, I can understand it not being. Second, if it is possible, where should I look for information, I've tried google and their documentation and all the showcases