Slash Boxes
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

rjbs (4671)

  (email not shown publicly)
AOL IM: RicardoJBSignes (Add Buddy, Send Message)
Yahoo! ID: RicardoSignes (Add User, Send Message)

I'm a Perl coder living in Bethlehem, PA and working Philadelphia. I'm a philosopher and theologan by training, but I was shocked to learn upon my graduation that these skills don't have many associated careers. Now I write code.

Journal of rjbs (4671)

Friday May 25, 2007
04:23 PM

perl email project non-synergy

[ #33353 ]

The last bug of the day was, "Why is this process getting so big?" See, it was getting an HTTP upload, creating an Email::Simple::FromHandle, then delivering it. It should all have been streaming around, nothing in memory.

Then we realized that Email::LocalDelivery was dealing with the string at once, because it was written before ::FromHandle. Here's the bizarre thing, though:

Email::LocalDelivery accepts only a string to deliver. In fact:

croak "Mail argument to deliver should just be a plain string" if ref $mail;

It calls the deliver method on the various Email::LocalDelivery::* classes, like ::Maildir, which says:

sub deliver { my ($class, $mail, @files) = @_; $mail = Email::Simple->new($mail) unless ref $mail eq "Email::Simple"; # For when we recurse

Unfortunately, ::Mbox does nothing of the sort, only writing a string to a file with no provision for receiving an Email::Simple object, so the exception in Email::LocalDelivery can't really be fixed without bizarre consequences: partial deliveries based on the delivery targets.

I'll probably fix this in all the E::LD:: classes I control, then try to get the other CPAN modules fixed, then hope nothing on the darkpan breaks. At least I can fix the streaming delivery in Email::LocalDelivery::Maildir and call its deliver method directly, because hey, THAT's a great idea...

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
More | Login | Reply
Loading... please wait.