[Info-vax] Apache + mod_php performance
Dan Cross
cross at spitfire.i.gajendra.net
Thu Oct 3 16:40:33 EDT 2024
In article <vdmokf$3r6ke$1 at dont-email.me>,
Dave Froble <davef at tsoft-inc.com> wrote:
>On 10/2/2024 1:52 PM, Simon Clubley wrote:
>> On 2024-10-02, Arne Vajhøj <arne at vajhoej.dk> wrote:
>>> On 10/2/2024 11:07 AM, Dan Cross wrote:
>>>> In article <vdjmq4$37f8q$3 at dont-email.me>,
>>>> Arne Vajhøj <arne at vajhoej.dk> wrote:
>>>>> On 10/2/2024 10:47 AM, Dan Cross wrote:
>>>>>> [snip]
>>>>>> You do not seem to understand how this is qualitatively
>>>>>> different from your test program not sending `Connection: close`
>>>>>> with its single request per connection, and then blocking until
>>>>>> the server times it out.
>>>>>
>>>>> It is qualitative different from what you are imaging.
>>>>>
>>>>> The client does not block until the server times out.
>>>>
>>>> So what, exactly, does it do?
>>>
>>> It moves on to next request.
>>>
>>
>> Does it reuse an existing connection for the next request (which is
>> what you have told the server you are going to do due to your keep-alive
>> settings) or does it always create a brand-new connection for the next
>> request ?
>
>I don't work much with this kind of stuff, but I have questions?
>
>If a connection is persistent, then there is already a connection, no need for a
>"brand-new" connection. However, perhaps you're asking whether the client uses
>an existing connection, or always issues a new connection request?
I think the last place I saw Arne's goalposts, he was trying to
match the behavior he expects from a bunch of "browser" users;
these would presumably connect to his service independently, but
if they tied up a bunch of resources with idle connections, they
would starve other users. The issue here is that an Apache
instance in the configuration he's using is only capable of
handling a single _connection_ per instance; if that connection
is idle, then that instance is blocked from performing otherwise
useful work.
The issue here is that a browser may open a connection to the
server and the user may wander away; if that connection is
persistent, then it's going to tie up an Apache instance, since
the user has gone to get a cup of coffee or whatever and isn't
actively using it.
Of course, this isn't specific to VMS, or a function of how VSI
ported it or whatever else Arne initially thought. The issue
was, Arne insisting that his test driver wasn't using persistent
connections, that it actually was since he didn't know to send a
`Connection: close` header with HTTP/1.1 to turn off
keep-alives. It's not a bug in Apache, either, despite his
protestations that it was because disabling keep-alive on the
server increased throughput for him; it's curious that he would
do that for the exact behavior he claimed he was warning people
about 20 years ago.
It's odd that he hadn't heard about Unix file descriptor
passing, which has been around since 1983; particularly since
when I suggested that a way to build an application like this
is for a master process to accept a connection and then pass it
off to a worker process and he said, "that's how it's usually
done." Given that he was unaware of the mechanism by which one
might transfer the connection from one process to another, one
must wonder how he thought it was done?
- Dan C.
More information about the Info-vax
mailing list