The following issue has been ASSIGNED.
======================================================================
http://www.dbmail.org/mantis/view.php?id=282
======================================================================
Reported By: ryo
Assigned To: paul
======================================================================
Project: DBMail
Issue ID: 282
Category: General
Reproducibility: sometimes
Severity: minor
Priority: normal
Status: assigned
======================================================================
Date Submitted: 08-Nov-05 02:21 CET
Last Modified: 27-Jan-06 21:02 CET
======================================================================
Summary: PostgreSQL Error "current transaction is aborted,
commands ignored until end of transaction block"
Description:
The program keeps executing a query even after db_query() fails when
it is called from insert_address_cache() and insert_field_cache() in
dbmail-message.c. That is because the first argument of trace()
function is TRACE_WARNING.
However, unless a program publishes a "commit" or a "rollback" to
PostgreSQL after such a query fails in a transaction, the program
will continue to fail executing the rest of all queries on PostgreSQL
due to the error below:
ERROR: current transaction is aborted, commands ignored until end of
transaction block
For example, if the daemon dbmail-lmtpd inserts a string of more than
100 chars to dbmail_fromfield.fromname, dbmail's logs will be filled
with the messages as described at "Additional Information"
below. (Please refer to it.) Then, insert_messages() function fails
as well.
In order for us to get rid of such a problem, I made a patch that
will publish a rollback when db_query() fails in insert_address_cache()
and insert_field_cache().
Please see the uploaded file.
======================================================================
Issue History
Date Modified Username Field Change
======================================================================
08-Nov-05 02:21 ryo New Issue
08-Nov-05 02:21 ryo File Added: dbmail-cache-savepoint.patch
27-Jan-06 21:02 paul Status new => assigned
27-Jan-06 21:02 paul Assigned To => paul
======================================================================