
using realbasic to develop a http server
Quote:
>i have explored into many of the sample code on socket.
>none of it demonstrate a true server solution.
>i am trying to write a http server, which will be listening on port 80 for
>many simultaneous sessions.
>rb has strong support in socket, but it seems to listen only once on single
>port. once a client has established a connection with it, the port will not
>be available for other until the first connection is closed and
>re-establish.
>un-fortunately, in http server environment, i need to handle multiple
>connections on single port number (which is 80).
>anyone has done this before??
Yes. Don't bother. It sucked rocks and I had experience in writing HTTP
servers before (I wrote one that runs on the Newton Messagepad that was
featured in WiReD magazine and have worked on one in Java, as well).
I ended up recasting the functions I needed into a CGI that I called from
MacOS Personal Websharing (or any other WebSTAR compatible server) after
trying and trying to avoid all the crashes and instabilities.
Don't re-invent this wheel, my friend...
--
Matthew Vaughn