I tripped over the fact that the PerlResponseHandler does not send EOS
(which is optional, after all).  Here are a couple of reasons mod_perl
should go ahead and send the EOS right after the PerlRespnseHandler
exits:

- Efficiency: one less brigade & associated calls, since it can be added
  to the tail of the last bucket brigade sent.  This saves us from
  having to call filter handlers twice[1].
- Testing of EOS handling in mod_perl test suite.  For instance, I can't
  test the Apache::Filter->eof() correctly right now, since it never sees the
  EOS.

The easiest way I can think of to do this is to add "send_eos" flags as
new parameters to modperl_wbucket_pass() and modperl_wbucket_flush().

It would also be nice to be able to send the EOS from within the
PerlResponseHandler subroutine, so that output filters could be flushed
before doing any real cleanup.  The new Apache::Filter->close() does
that for filter handlers, for instance, although it may allow multiple
EOSed to be sent downstream as-is (I need to look at it and see if
close()ing before the real EOS is receoived sends two downstream).

- Barrie

[1] I know they aren't called twice, since EOS-only bucket brigades
don't cause a filter handler to be called.  But I think they need to be
called so that filter handlers can flush internal state.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to