On 1/31/11 11:26 AM, Simon Riggs wrote: > The purpose of errcodes is to allow programs to check them and then act. > It's pointless to add a new errcode that is so rare that nobody will > ever program for it because they won't expect it, let alone test for it. > Or at least won't assign any sensible priority to handling that error.
Personally, I would prefer a new error code because I *intend* to write specific code to deal with replication cancellation. Without a specific code, then I cannot distinguish replication cancel from whatever else it's lumped in with, except by regexping the error message. If we're not going to get a new code, then I'd prefer DEADLOCK_DETECTED because the behavior we expect from the client (try the whole transaction over from the beginning) is the same. -- -- Josh Berkus PostgreSQL Experts Inc. http://www.pgexperts.com -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers