Hope Micro$oft's
next browser uses a 'connected' client-server approach... HTTP2 ?
Nah.. it will never
happen...
Regards, Daniel
Your
question raises some interesting issues about the limitations of the web
server-client relationship. Ideally, what you need is a classic "publish and
subscribe" paradigm (which is what this servlet mailing list is really,
except its using email), but this isn't how web clients and their hosts
work together - its more like "ask me a question, and I'll (try to) tell
you the answer, but if I don't find it till later, you'll never know!!", which
is hardly a satisfactory solution, if one at all, but hey, it cheap and easy
to develop and deploy! An alternative is to have a special network
listener (a web server is a glorified listener, but one that only
operates "on demand") that maintains continuous communication with its
clients, even when there's nothing to "say", which is expensive on network
resources, so there's the downside, but doable. Maybe you need to think
instead about EJB's and RMI (since Java doesn't support the function
pointers that would allow a callback function between (say) a C++ client
and an RPC to a remote host)...good luck!
HTML is the result of a request to the
server, and after the response is sent from the server, the server has
no idea that the client is there until it receives another request.
You could have the page refresh every xx seconds, but this would cause a big
overhead for the server. You could also do this using applets -- the
server can communicate with the applet sessions. Most HTML based
chat programs work with applets for this reason.
Mike
----- Original Message -----
Sent: Thursday, October 24, 2002 7:15
AM
Subject: Re: Sending Response Objet
to client without request.
Not with HTTP.
hi;
I have to develop an application that have
to fetch data from server after some time, or when ever there are some
changes in data on the server then server have to send those changes to
the clients ( http clients viewing that site).
The simplest way to set some time interval
in java script of client side to refresh the page.
Is there any way that I can send response
to all clients without their request ( I have IPs of those
clients)..????
Any Comments or suggestions...
Mazhar!
|