* Nicolai Petri <[EMAIL PROTECTED]> [001116 02:37] wrote:
> What's the best approach for a simple web-server(never more the 10 clients)
> ? Is it using pthread and a thread per connection . Or to make a
> non-blocking single thread server. Can people show me some simple examples
> of the 2 techniques ?
>
> And what's the pro's and con's for the 2 methods ???
Because you want something simple, I would use a thread per connection.
For a more complex/high-perfomance server you'd want to use several
threads using event queues and perhaps external processes for disk
IO.
--
-Alfred Perlstein - [[EMAIL PROTECTED]|[EMAIL PROTECTED]]
"I have the heart of a child; I keep it in a jar on my desk."
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message