Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.java.programmer > #19686 > unrolled thread
| Started by | "sl@exabyte" <sb5309@hotmail.com> |
|---|---|
| First post | 2012-11-10 22:06 +0800 |
| Last post | 2012-12-09 18:30 -0500 |
| Articles | 20 on this page of 21 — 9 participants |
Back to article view | Back to comp.lang.java.programmer
Java servlet, comet, long polling, websocket: I am consused !! "sl@exabyte" <sb5309@hotmail.com> - 2012-11-10 22:06 +0800
Re: Java servlet, comet, long polling, websocket: I am consused !! markspace <-@.> - 2012-11-10 08:09 -0800
Re: Java servlet, comet, long polling, websocket: I am consused !! "sl@exabyte" <sb5309@hotmail.com> - 2012-11-11 00:21 +0800
Re: Java servlet, comet, long polling, websocket: I am consused !! markspace <-@.> - 2012-11-10 08:31 -0800
Re: Java servlet, comet, long polling, websocket: I am consused !! "William Bonawentura" <nie@ma.mnie.pl> - 2012-11-12 07:38 +0100
Re: Java servlet, comet, long polling, websocket: I am consused !! "sl@exabyte" <sb5309@hotmail.com> - 2012-11-12 22:13 +0800
Re: Java servlet, comet, long polling, websocket: I am consused !! Arne Vajhøj <arne@vajhoej.dk> - 2012-12-10 22:20 -0500
Re: Java servlet, comet, long polling, websocket: I am consused !! Kevin McMurtrie <mcmurtrie@pixelmemory.us> - 2012-11-10 13:23 -0800
Re: Java servlet, comet, long polling, websocket: I am consused !! "sl@exabyte" <sb5309@hotmail.com> - 2012-11-11 21:30 +0800
Re: Java servlet, comet, long polling, websocket: I am consused !! Kevin McMurtrie <mcmurtrie@pixelmemory.us> - 2012-11-13 00:44 -0800
Re: Java servlet, comet, long polling, websocket: I am consused !! "sl@exabyte" <sb5309@hotmail.com> - 2012-11-11 21:37 +0800
Re: Java servlet, comet, long polling, websocket: I am consused !! Arne Vajhøj <arne@vajhoej.dk> - 2012-12-10 22:24 -0500
Re: Java servlet, comet, long polling, websocket: I am consused !! jebblue <n@n.nnn> - 2012-11-23 11:26 -0600
Re: Java servlet, comet, long polling, websocket: I am consused !! Kevin McMurtrie <mcmurtrie@pixelmemory.us> - 2012-11-28 21:02 -0800
Re: Java servlet, comet, long polling, websocket: I am consused !! jebblue <n@n.nnn> - 2012-12-07 00:09 -0600
Re: Java servlet, comet, long polling, websocket: I am consused !! Arved Sandstrom <asandstrom2@eastlink.ca> - 2012-12-07 06:43 -0400
Re: Java servlet, comet, long polling, websocket: I am consused !! Arne Vajhøj <arne@vajhoej.dk> - 2012-12-09 18:42 -0500
Re: Java servlet, comet, long polling, websocket: I am consused !! Silvio <silvio@internet.com> - 2012-11-29 11:30 +0100
Re: Java servlet, comet, long polling, websocket: I am consused !! jebblue <n@n.nnn> - 2012-12-07 00:12 -0600
Re: Java servlet, comet, long polling, websocket: I am consused !! Roedy Green <see_website@mindprod.com.invalid> - 2012-12-09 10:01 -0800
Re: Java servlet, comet, long polling, websocket: I am consused !! Arne Vajhøj <arne@vajhoej.dk> - 2012-12-09 18:30 -0500
Page 1 of 2 [1] 2 Next page →
| From | "sl@exabyte" <sb5309@hotmail.com> |
|---|---|
| Date | 2012-11-10 22:06 +0800 |
| Subject | Java servlet, comet, long polling, websocket: I am consused !! |
| Message-ID | <k7ln1q$id0$1@news.albasani.net> |
I have been reading the above topics for several days, and now utterly confused. I am trying to to put a server program for char room feature on my web site. To make the server program more efficient I am thinking of using sockets. For the client end, I would to use socket if I can (otherwise AJAX). At the server end, PHP or java daemon. My questions: 1. a) For the front end, can I use java servlet ? I understand that websocket is not generally supported. b) Is java servlet supported by browsers generally ? 2. I discover that there are comet, long polling, websocket. I am very confused now. Can some experts discuss somewhat of all these options ? Thanks.
[toc] | [next] | [standalone]
| From | markspace <-@.> |
|---|---|
| Date | 2012-11-10 08:09 -0800 |
| Message-ID | <k7lu6u$ad2$1@dont-email.me> |
| In reply to | #19686 |
On 11/10/2012 6:06 AM, sl@exabyte wrote: > a) For the front end, can I use java servlet ? No. Servlets are server side technology. > b) Is java servlet supported by browsers generally ? Never. Servlets are a server side technology. However, look at Java applets: <http://docs.oracle.com/javase/tutorial/deployment/applet/> All GUI browsers on Mac, Linux and Windows that I know of support Java applets. Android doesn't: use an app. iOS doesn't: use their ecosystem.
[toc] | [prev] | [next] | [standalone]
| From | "sl@exabyte" <sb5309@hotmail.com> |
|---|---|
| Date | 2012-11-11 00:21 +0800 |
| Message-ID | <k7luu2$3tg$1@news.albasani.net> |
| In reply to | #19687 |
> On 11/10/2012 6:06 AM, sl@exabyte wrote: >> a) For the front end, can I use java servlet ? > > No. Servlets are server side technology. > >> b) Is java servlet supported by browsers generally ? > > Never. Servlets are a server side technology. > > However, look at Java applets: > <http://docs.oracle.com/javase/tutorial/deployment/applet/> > > All GUI browsers on Mac, Linux and Windows that I know of support Java > applets. Android doesn't: use an app. iOS doesn't: use their > ecosystem. My apology, 'java servlet' should be 'java applet'. I think coding in java applet allows access to sockets. Thanks.
[toc] | [prev] | [next] | [standalone]
| From | markspace <-@.> |
|---|---|
| Date | 2012-11-10 08:31 -0800 |
| Message-ID | <k7lvhp$hp4$1@dont-email.me> |
| In reply to | #19688 |
On 11/10/2012 8:21 AM, sl@exabyte wrote:java applet'. > > I think coding in java applet allows access to sockets. Yes it does. <http://docs.oracle.com/javase/tutorial/networking/sockets/index.html> <http://docs.oracle.com/javase/7/docs/api/java/net/Socket.html> <http://docs.oracle.com/javase/7/docs/api/java/net/ServerSocket.html>
[toc] | [prev] | [next] | [standalone]
| From | "William Bonawentura" <nie@ma.mnie.pl> |
|---|---|
| Date | 2012-11-12 07:38 +0100 |
| Message-ID | <k7q5gl$otp$1@news2.ipartners.pl> |
| In reply to | #19688 |
> I think coding in java applet allows access to sockets. Except clients behind http proxy.
[toc] | [prev] | [next] | [standalone]
| From | "sl@exabyte" <sb5309@hotmail.com> |
|---|---|
| Date | 2012-11-12 22:13 +0800 |
| Message-ID | <k7r065$knh$1@news.albasani.net> |
| In reply to | #19705 |
William Bonawentura wrote: >> I think coding in java applet allows access to sockets. > > Except clients behind http proxy. Thanks for your info. I have heard of proxy server, but not bothered with it so far. I did some 'google'ing on proxy server. My current understanding is the proxy server may block the communication port. So to enable the administrator needs to give permission to use this port. Would MSN have the same problem ? Thanks for your guide.
[toc] | [prev] | [next] | [standalone]
| From | Arne Vajhøj <arne@vajhoej.dk> |
|---|---|
| Date | 2012-12-10 22:20 -0500 |
| Message-ID | <50c6a67d$0$291$14726298@news.sunsite.dk> |
| In reply to | #19688 |
On 11/10/2012 11:21 AM, sl@exabyte wrote: >> However, look at Java applets: >> <http://docs.oracle.com/javase/tutorial/deployment/applet/> >> >> All GUI browsers on Mac, Linux and Windows that I know of support Java >> applets. Android doesn't: use an app. iOS doesn't: use their >> ecosystem. > > My apology, 'java servlet' should be 'java applet'. That is a bloody big difference. > I think coding in java applet allows access to sockets. It does. Server side is more tricky. Either a standalone server/daemon program or a full Java EE application-server with a JCA inbound adapter. And you need to get through all the firewalls, which may be easy or may be impossible. Arne
[toc] | [prev] | [next] | [standalone]
| From | Kevin McMurtrie <mcmurtrie@pixelmemory.us> |
|---|---|
| Date | 2012-11-10 13:23 -0800 |
| Message-ID | <509ec5dd$0$26894$742ec2ed@news.sonic.net> |
| In reply to | #19686 |
In article <k7ln1q$id0$1@news.albasani.net>, "sl@exabyte" <sb5309@hotmail.com> wrote: > I have been reading the above topics for several days, and now utterly > confused. > > I am trying to to put a server program for char room feature on my web > site. To make the server program more efficient I am thinking of using > sockets. > > For the client end, I would to use socket if I can (otherwise AJAX). > > At the server end, PHP or java daemon. > > My questions: > > 1. > a) For the front end, can I use java servlet ? I understand that websocket > is not generally supported. > b) Is java servlet supported by browsers generally ? > > 2. > I discover that there are comet, long polling, websocket. I am very confused > now. > > Can some experts discuss somewhat of all these options ? > > Thanks. I'm using WebSockets with Jetty. It generally works well for two-way text messaging and it doesn't interfere with REST/Servlet APIs. Recent but important features, like ping/pong and different message types, aren't supported by browsers. There's also zero error handling defined so you'll need to work that in. Tomcat has experimental support for WebSockets but I recommend Jetty instead. -- I will not see posts from Google because I must filter them as spam
[toc] | [prev] | [next] | [standalone]
| From | "sl@exabyte" <sb5309@hotmail.com> |
|---|---|
| Date | 2012-11-11 21:30 +0800 |
| Message-ID | <k7o9a4$k8q$1@news.albasani.net> |
| In reply to | #19690 |
Kevin McMurtrie wrote: > In article <k7ln1q$id0$1@news.albasani.net>, > "sl@exabyte" <sb5309@hotmail.com> wrote: > >> I have been reading the above topics for several days, and now >> utterly confused. >> >> I am trying to to put a server program for char room feature on my >> web site. To make the server program more efficient I am thinking of >> using sockets. >> >> For the client end, I would to use socket if I can (otherwise AJAX). >> >> At the server end, PHP or java daemon. >> >> My questions: >> >> 1. >> a) For the front end, can I use java servlet ? I understand that >> websocket is not generally supported. >> b) Is java servlet supported by browsers generally ? >> >> 2. >> I discover that there are comet, long polling, websocket. I am very >> confused now. >> >> Can some experts discuss somewhat of all these options ? >> >> Thanks. > > > I'm using WebSockets with Jetty. It generally works well for two-way > text messaging and it doesn't interfere with REST/Servlet APIs. > Recent but important features, like ping/pong and different message > types, aren't supported by browsers. There's also zero error > handling defined so you'll need to work that in. > > Tomcat has experimental support for WebSockets but I recommend Jetty > instead. Just curious, have you thought about using javacript with java applet ? If yes, what made you choose WebSockets with jetty ? Thanks.
[toc] | [prev] | [next] | [standalone]
| From | Kevin McMurtrie <mcmurtrie@pixelmemory.us> |
|---|---|
| Date | 2012-11-13 00:44 -0800 |
| Message-ID | <50a20889$0$26827$742ec2ed@news.sonic.net> |
| In reply to | #19694 |
In article <k7o9a4$k8q$1@news.albasani.net>, "sl@exabyte" <sb5309@hotmail.com> wrote: > Kevin McMurtrie wrote: > > In article <k7ln1q$id0$1@news.albasani.net>, > > "sl@exabyte" <sb5309@hotmail.com> wrote: > > > >> I have been reading the above topics for several days, and now > >> utterly confused. > >> > >> I am trying to to put a server program for char room feature on my > >> web site. To make the server program more efficient I am thinking of > >> using sockets. > >> > >> For the client end, I would to use socket if I can (otherwise AJAX). > >> > >> At the server end, PHP or java daemon. > >> > >> My questions: > >> > >> 1. > >> a) For the front end, can I use java servlet ? I understand that > >> websocket is not generally supported. > >> b) Is java servlet supported by browsers generally ? > >> > >> 2. > >> I discover that there are comet, long polling, websocket. I am very > >> confused now. > >> > >> Can some experts discuss somewhat of all these options ? > >> > >> Thanks. > > > > > > I'm using WebSockets with Jetty. It generally works well for two-way > > text messaging and it doesn't interfere with REST/Servlet APIs. > > Recent but important features, like ping/pong and different message > > types, aren't supported by browsers. There's also zero error > > handling defined so you'll need to work that in. > > > > Tomcat has experimental support for WebSockets but I recommend Jetty > > instead. > > Just curious, have you thought about using javacript with java applet ? > > If yes, what made you choose WebSockets with jetty ? > > Thanks. Applets are uncommon and so are developers for them. Sun screwed up the Applet and GUI APIs over and over again right when Applets were needed. HTML5 features create interactive GUIs far more easily and efficiently than anything from Sun or Oracle. WebSockets were chosen because they were a very simple way to provide realtime two-way communications between client and server. Jetty was chosen because it appears that it receives aggressive refactoring to keep the code lean and clean. WebSocket support is mature and cleanly integrated. Jetty also has clear layering that makes it possible for unit tests to build a mini environment for invoking Servlets. The downside is that configuration documentation is incomplete. -- I will not see posts from Google because I must filter them as spam
[toc] | [prev] | [next] | [standalone]
| From | "sl@exabyte" <sb5309@hotmail.com> |
|---|---|
| Date | 2012-11-11 21:37 +0800 |
| Message-ID | <k7o9mr$kv1$1@news.albasani.net> |
| In reply to | #19690 |
Kevin McMurtrie wrote: > > I'm using WebSockets with Jetty. It generally works well for two-way > text messaging and it doesn't interfere with REST/Servlet APIs. > Recent but important features, like ping/pong and different message > types, aren't supported by browsers. There's also zero error > handling defined so you'll need to work that in. > > Tomcat has experimental support for WebSockets but I recommend Jetty > instead. Just thinking. If javascript can communicate with java applet (which can access sockets), why bother to have websocket ? Forgive me if this is a stupid question.
[toc] | [prev] | [next] | [standalone]
| From | Arne Vajhøj <arne@vajhoej.dk> |
|---|---|
| Date | 2012-12-10 22:24 -0500 |
| Message-ID | <50c6a769$0$288$14726298@news.sunsite.dk> |
| In reply to | #19695 |
On 11/11/2012 8:37 AM, sl@exabyte wrote: > Just thinking. If javascript can communicate with java applet (which can > access sockets), why bother to have websocket ? > > Forgive me if this is a stupid question. Actually it is a pretty good question. Java applets are out of fashion - JavaScript is in fashion. There are or will soon be 1 billion smartphones with browsers without applet support. A Java-JavaScript solution is more complex than a pure JavaScript solution. But that said, then I still consider the Java applet solution to be a perfectly viable solution that must be considered. Arne
[toc] | [prev] | [next] | [standalone]
| From | jebblue <n@n.nnn> |
|---|---|
| Date | 2012-11-23 11:26 -0600 |
| Message-ID | <dq-dnVh_K8ErLDLNnZ2dnUVZ_umdnZ2d@giganews.com> |
| In reply to | #19690 |
On Sat, 10 Nov 2012 13:23:41 -0800, Kevin McMurtrie wrote: > In article <k7ln1q$id0$1@news.albasani.net>, > "sl@exabyte" <sb5309@hotmail.com> wrote: > >> I have been reading the above topics for several days, and now utterly >> confused. >> >> I am trying to to put a server program for char room feature on my web >> site. To make the server program more efficient I am thinking of using >> sockets. >> >> For the client end, I would to use socket if I can (otherwise AJAX). >> >> At the server end, PHP or java daemon. >> >> My questions: >> >> 1. >> a) For the front end, can I use java servlet ? I understand that websocket >> is not generally supported. >> b) Is java servlet supported by browsers generally ? >> >> 2. >> I discover that there are comet, long polling, websocket. I am very confused >> now. >> >> Can some experts discuss somewhat of all these options ? >> >> Thanks. > > > I'm using WebSockets with Jetty. It generally works well for two-way > text messaging and it doesn't interfere with REST/Servlet APIs. Recent > but important features, like ping/pong and different message types, > aren't supported by browsers. There's also zero error handling defined > so you'll need to work that in. > > Tomcat has experimental support for WebSockets but I recommend Jetty > instead. Jetty doesn't even have a clean start/stop CLI interface like Tomcat has had all along. Tomcat is the basis for all major Enterprise Java web servers.
[toc] | [prev] | [next] | [standalone]
| From | Kevin McMurtrie <mcmurtrie@pixelmemory.us> |
|---|---|
| Date | 2012-11-28 21:02 -0800 |
| Message-ID | <50b6ec84$0$29801$742ec2ed@news.sonic.net> |
| In reply to | #19868 |
In article <dq-dnVh_K8ErLDLNnZ2dnUVZ_umdnZ2d@giganews.com>, jebblue <n@n.nnn> wrote: > On Sat, 10 Nov 2012 13:23:41 -0800, Kevin McMurtrie wrote: > > > In article <k7ln1q$id0$1@news.albasani.net>, > > "sl@exabyte" <sb5309@hotmail.com> wrote: > > > >> I have been reading the above topics for several days, and now utterly > >> confused. > >> > >> I am trying to to put a server program for char room feature on my web > >> site. To make the server program more efficient I am thinking of using > >> sockets. > >> > >> For the client end, I would to use socket if I can (otherwise AJAX). > >> > >> At the server end, PHP or java daemon. > >> > >> My questions: > >> > >> 1. > >> a) For the front end, can I use java servlet ? I understand that websocket > >> is not generally supported. > >> b) Is java servlet supported by browsers generally ? > >> > >> 2. > >> I discover that there are comet, long polling, websocket. I am very > >> confused > >> now. > >> > >> Can some experts discuss somewhat of all these options ? > >> > >> Thanks. > > > > > > I'm using WebSockets with Jetty. It generally works well for two-way > > text messaging and it doesn't interfere with REST/Servlet APIs. Recent > > but important features, like ping/pong and different message types, > > aren't supported by browsers. There's also zero error handling defined > > so you'll need to work that in. > > > > Tomcat has experimental support for WebSockets but I recommend Jetty > > instead. > > Jetty doesn't even have a clean start/stop CLI interface like > Tomcat has had all along. Tomcat is the basis for all major > Enterprise Java web servers. Why the totally off-topic reply about the start/stop procedure? /opt/jetty/bin/jetty.sh stop /opt/jetty/bin/jetty.sh start Or use the init.d scripts. That looks a lot like Tomcat. I recommend using the server best supports the features you need. Software developers aren't paid lots of money to make decisions based on FUD. There's good reason for Restlet, Jetty, Resin, Tomcat, and other engines existing. -- I will not see posts from Google because I must filter them as spam
[toc] | [prev] | [next] | [standalone]
| From | jebblue <n@n.nnn> |
|---|---|
| Date | 2012-12-07 00:09 -0600 |
| Message-ID | <g_WdnW3sOeK4FVzNnZ2dnUVZ_gWdnZ2d@giganews.com> |
| In reply to | #20016 |
On Wed, 28 Nov 2012 21:02:59 -0800, Kevin McMurtrie wrote: > In article <dq-dnVh_K8ErLDLNnZ2dnUVZ_umdnZ2d@giganews.com>, > jebblue <n@n.nnn> wrote: > >> On Sat, 10 Nov 2012 13:23:41 -0800, Kevin McMurtrie wrote: >> >> > In article <k7ln1q$id0$1@news.albasani.net>, >> > "sl@exabyte" <sb5309@hotmail.com> wrote: >> > >> >> I have been reading the above topics for several days, and now utterly >> >> confused. >> >> >> >> I am trying to to put a server program for char room feature on my web >> >> site. To make the server program more efficient I am thinking of using >> >> sockets. >> >> >> >> For the client end, I would to use socket if I can (otherwise AJAX). >> >> >> >> At the server end, PHP or java daemon. >> >> >> >> My questions: >> >> >> >> 1. >> >> a) For the front end, can I use java servlet ? I understand that websocket >> >> is not generally supported. >> >> b) Is java servlet supported by browsers generally ? >> >> >> >> 2. >> >> I discover that there are comet, long polling, websocket. I am very >> >> confused >> >> now. >> >> >> >> Can some experts discuss somewhat of all these options ? >> >> >> >> Thanks. >> > >> > >> > I'm using WebSockets with Jetty. It generally works well for two-way >> > text messaging and it doesn't interfere with REST/Servlet APIs. Recent >> > but important features, like ping/pong and different message types, >> > aren't supported by browsers. There's also zero error handling defined >> > so you'll need to work that in. >> > >> > Tomcat has experimental support for WebSockets but I recommend Jetty >> > instead. >> >> Jetty doesn't even have a clean start/stop CLI interface like >> Tomcat has had all along. Tomcat is the basis for all major >> Enterprise Java web servers. > > Why the totally off-topic reply about the start/stop procedure? > Cars or the moon would be off-topic. > /opt/jetty/bin/jetty.sh stop > /opt/jetty/bin/jetty.sh start > > Or use the init.d scripts. That looks a lot like Tomcat. > Thanks, guess I didn't look far enough. Tomcat is still the basis of every major enterprise Java platform. > I recommend using the server best supports the features you need. > Software developers aren't paid lots of money to make decisions based on > FUD. There's good reason for Restlet, Jetty, Resin, Tomcat, and other > engines existing. FUD? Nope. Mistake yes, FUD no, not at all. When WebSphere or WebLogic decide to switch to Jetty I'll look at it again.
[toc] | [prev] | [next] | [standalone]
| From | Arved Sandstrom <asandstrom2@eastlink.ca> |
|---|---|
| Date | 2012-12-07 06:43 -0400 |
| Message-ID | <rLjws.1939$Wh.1918@newsfe13.iad> |
| In reply to | #20145 |
On 12/07/2012 02:09 AM, jebblue wrote: > On Wed, 28 Nov 2012 21:02:59 -0800, Kevin McMurtrie wrote: > [ SNIP ] > >> I recommend using the server best supports the features you need. >> Software developers aren't paid lots of money to make decisions based on >> FUD. There's good reason for Restlet, Jetty, Resin, Tomcat, and other >> engines existing. > > FUD? Nope. Mistake yes, FUD no, not at all. When WebSphere or > WebLogic decide to switch to Jetty I'll look at it again. > I'm with Kevin on this one. And bear in mind, when you say "WebSphere" or "WebLogic" it's not like you've got this dedicated team of web container experts, with each app server development staff, that constantly evaluates servlet containers and gets their decisions quickly acted upon. In practice the resources allocated for software development on a major JEE app server are less than you might think. Most are probably either fixing bugs or designing/implementing new features (which latter is driven by the marketers). If an included/embedded web/servlet container is cutting it, and that original choice probably came down to one or a small handful of people way back when (so why do they know more than you, exactly?), and the cost of *change* is probably not justifiable for incremental improvements achieved by using another container, why do you think that what a major app server uses gives you any major guidance at all? Other than that what they use is good for them. It's possibly not the _best_ for them at any given time. It's very possibly not the best choice for anyone else's requirements, although you can expect it to be adequate. AHS
[toc] | [prev] | [next] | [standalone]
| From | Arne Vajhøj <arne@vajhoej.dk> |
|---|---|
| Date | 2012-12-09 18:42 -0500 |
| Message-ID | <50c5220a$0$283$14726298@news.sunsite.dk> |
| In reply to | #20145 |
On 12/7/2012 1:09 AM, jebblue wrote: > On Wed, 28 Nov 2012 21:02:59 -0800, Kevin McMurtrie wrote: >> /opt/jetty/bin/jetty.sh stop >> /opt/jetty/bin/jetty.sh start >> >> Or use the init.d scripts. That looks a lot like Tomcat. >> > > Thanks, guess I didn't look far enough. Given that it is in the same location as for Tomcat, then it appears that you have not been looking at all. > Tomcat is still the basis of > every major enterprise Java platform. Still not. >> I recommend using the server best supports the features you need. >> Software developers aren't paid lots of money to make decisions based on >> FUD. There's good reason for Restlet, Jetty, Resin, Tomcat, and other >> engines existing. > > FUD? Nope. Mistake yes, FUD no, not at all. When WebSphere or > WebLogic decide to switch to Jetty I'll look at it again. They probably prefer their own. But heard of a small company called Google? They use Jetty! Arne
[toc] | [prev] | [next] | [standalone]
| From | Silvio <silvio@internet.com> |
|---|---|
| Date | 2012-11-29 11:30 +0100 |
| Message-ID | <50b7394d$0$6847$e4fe514c@news2.news.xs4all.nl> |
| In reply to | #19868 |
On 11/23/2012 06:26 PM, jebblue wrote: > On Sat, 10 Nov 2012 13:23:41 -0800, Kevin McMurtrie wrote: > >> In article <k7ln1q$id0$1@news.albasani.net>, >> "sl@exabyte" <sb5309@hotmail.com> wrote: >> >>> I have been reading the above topics for several days, and now utterly >>> confused. >>> >>> I am trying to to put a server program for char room feature on my web >>> site. To make the server program more efficient I am thinking of using >>> sockets. >>> >>> For the client end, I would to use socket if I can (otherwise AJAX). >>> >>> At the server end, PHP or java daemon. >>> >>> My questions: >>> >>> 1. >>> a) For the front end, can I use java servlet ? I understand that websocket >>> is not generally supported. >>> b) Is java servlet supported by browsers generally ? >>> >>> 2. >>> I discover that there are comet, long polling, websocket. I am very confused >>> now. >>> >>> Can some experts discuss somewhat of all these options ? >>> >>> Thanks. >> >> >> I'm using WebSockets with Jetty. It generally works well for two-way >> text messaging and it doesn't interfere with REST/Servlet APIs. Recent >> but important features, like ping/pong and different message types, >> aren't supported by browsers. There's also zero error handling defined >> so you'll need to work that in. >> >> Tomcat has experimental support for WebSockets but I recommend Jetty >> instead. > > Jetty doesn't even have a clean start/stop CLI interface like > Tomcat has had all along. Tomcat is the basis for all major > Enterprise Java web servers. > That is utter nonsense.
[toc] | [prev] | [next] | [standalone]
| From | jebblue <n@n.nnn> |
|---|---|
| Date | 2012-12-07 00:12 -0600 |
| Message-ID | <g_WdnWzsOeJfFVzNnZ2dnUVZ_gUAAAAA@giganews.com> |
| In reply to | #20017 |
On Thu, 29 Nov 2012 11:30:37 +0100, Silvio wrote: > On 11/23/2012 06:26 PM, jebblue wrote: >> On Sat, 10 Nov 2012 13:23:41 -0800, Kevin McMurtrie wrote: >> >>> In article <k7ln1q$id0$1@news.albasani.net>, >>> "sl@exabyte" <sb5309@hotmail.com> wrote: >>> >>>> I have been reading the above topics for several days, and now utterly >>>> confused. >>>> >>>> I am trying to to put a server program for char room feature on my web >>>> site. To make the server program more efficient I am thinking of using >>>> sockets. >>>> >>>> For the client end, I would to use socket if I can (otherwise AJAX). >>>> >>>> At the server end, PHP or java daemon. >>>> >>>> My questions: >>>> >>>> 1. >>>> a) For the front end, can I use java servlet ? I understand that websocket >>>> is not generally supported. >>>> b) Is java servlet supported by browsers generally ? >>>> >>>> 2. >>>> I discover that there are comet, long polling, websocket. I am very confused >>>> now. >>>> >>>> Can some experts discuss somewhat of all these options ? >>>> >>>> Thanks. >>> >>> >>> I'm using WebSockets with Jetty. It generally works well for two-way >>> text messaging and it doesn't interfere with REST/Servlet APIs. Recent >>> but important features, like ping/pong and different message types, >>> aren't supported by browsers. There's also zero error handling defined >>> so you'll need to work that in. >>> >>> Tomcat has experimental support for WebSockets but I recommend Jetty >>> instead. >> >> Jetty doesn't even have a clean start/stop CLI interface like >> Tomcat has had all along. Tomcat is the basis for all major >> Enterprise Java web servers. >> > > That is utter nonsense. No actually, read the README.txt file at the top level. It says run it as a jar. Kevin had the right answer, use bin/jetty.sh and supply one of the options such as start or stop.
[toc] | [prev] | [next] | [standalone]
| From | Roedy Green <see_website@mindprod.com.invalid> |
|---|---|
| Date | 2012-12-09 10:01 -0800 |
| Message-ID | <77k9c819i3hrebe8hfdmg5ckpa40eqbop7@4ax.com> |
| In reply to | #19868 |
On Fri, 23 Nov 2012 11:26:14 -0600, jebblue <n@n.nnn> wrote, quoted or indirectly quoted someone who said : >>> b) Is java servlet supported by browsers generally ? Servlets run on the Server. To the browser client they just look like static web pages. You can run some intelligence such as Ajax, Applets or JWS at the client. Then you can send any message format you want back and forth. see http://mindprod.com/jgloss/servletwomb.html For very high speed communication, you use UDP packets. The catch is, there is no guaranteed delivery. But often that may not matter if all you are doing is apprising each other of current state. See http://mindprod.com/jgloss/udp.html -- Roedy Green Canadian Mind Products http://mindprod.com Students who hire or con others to do their homework are as foolish as couch potatoes who hire others to go to the gym for them.
[toc] | [prev] | [next] | [standalone]
Page 1 of 2 [1] 2 Next page →
Back to top | Article view | comp.lang.java.programmer
csiph-web