If you don't want your process to wait until
delivery is complete, you can tell sendmail not
to deliver the email straight away, but to either do it in the
background or just queue the job until the next queue run. This can
significantly reduce the delay for the mod_perl process, which would
otherwise have to wait for the sendmail process
to complete. You can specify this for all deliveries in
sendmail.cf, or for individual email messages on
each invocation on the sendmail command line.
Here are the options:
Deliver in the background
Queue, and also defer the DNS/NIS lookups
The current trend is to move away from sendmail
and switch to using lighter mail delivery programs such as
qmail or postfix. You should
check the manpage of your favorite mailer application for equivalents
to the configuration presented for sendmail.
Alternatively, you may want to use Net::SMTP to
send your mail without calling an extra process. The main
disadvantage of using Net::SMTP is that it might
fail to deliver the mail because the destination peer server might be
down. It can also be very slow, in which case the mod_perl
application will do nothing while it waits for the mail to be sent.
|A.8. CGI::params in the mod_perlish Way||A.10. mod_rewrite in Perl|