Re: singlethreaded or multithreaded

Stipe Tolj <[email protected]>
Newsgroups gmane.comp.mobile.kannel.devel
Organization tolj.org system architecture
Message-ID <[email protected]>
Andreas Fink schrieb:
> I think you should for sure be able to accept multiple simultaneous
> incoming connections as its in the nature of a webserver. If you process
> them sequentially or more than one in parallel is then a performance
> issue. Kannel for sure doesnt stop working until it got the answer from
> the webserver as its written asynchronously. So it can have multiple
> parallel requests to multiple servers (this happens especially during
> WAP use). I'm not 100% sure how it handles requests to the same server
> as there it can keep a connection open and reuse it (HTTP Keepalive) but
> it for sure would not hurt your software to be able to handle a few
> requests in parallel as it would give you speed.

I can shade some light here.

The HTTP client layer in gwlib/http.[ch] works this way:

We look for a connection to the target host in our connection pool. If we have
one in the pool we grep it and use it, if we don't have one, we create a TCP
connection to the host.

As soon as the request/response transaction is finished, and we run in
Keep-Alive mode (HTTP/1.1) we will put the connection back to the pool.

Well, what does that mean? we create as man connections (there is no hard limit
per host target), as the re-cycling of the connection is put back into the pool.

This is a pretty hard way to hit the HTTP server. We get a lot of complains that
we break HTTP servers by hitting it too hard ;)

Stipe

-- 
-------------------------------------------------------------------
Kölner Landstrasse 419
40589 Düsseldorf, NRW, Germany

tolj.org system architecture      Kannel Software Foundation (KSF)
http://www.tolj.org/              http://www.kannel.org/

mailto:st_{at}_tolj.org           mailto:stolj_{at}_kannel.org
-------------------------------------------------------------------
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.