SQL Redux
Brent Strignano
brent at MIRABITO.COM
Mon Aug 4 21:15:07 IST 2003
If the end result is to get the items into an SQL database I think each
method would be very similar overall, as long as the database connection
isn't closed at the end of each message logging operation. The batch
method would need to do an extra operation at the end to parse the log
and do an insert per line when the child process shuts down. The
real-time method would have more to at message arrival, but since the
operation needs to be performed anyway it seems to me to be a matter of
procrastination, do a little now or a LOT later. Again as long as the
database connection doesn't have to be reestablished for each message.
Just a thought...
Brent Strignano
System Administrator
Granite Capital Holdings
Sidney, NY USA
-----Original Message-----
From: Julian Field [mailto:mailscanner at ECS.SOTON.AC.UK]
Sent: Monday, August 04, 2003 2:48 PM
To: MAILSCANNER at JISCMAIL.AC.UK
Subject: Re: SQL Redux
At 14:29 04/08/2003, you wrote:
>If there's really no performance hit to logging after every email
>instead of in batches, I'll see about changing my code to do it that
>way too. Nothing worse than having to wait for all of the children to
>finish logging before I can do a full restart of MailScanner.
There must be a significant performance hit. In one case you are just
appending a line to a file. In the other case you are adding a record to
a database table and updating various indices. This *has* to be a much
bigger operation than just adding 1 line to a file.
--
Julian Field
www.MailScanner.info
Professional Support Services at www.MailScanner.biz MailScanner thanks
transtec Computers for their support
More information about the MailScanner
mailing list