I don't see why 2PC would require any protocol-level change. I would
think that the API would be something like
BEGIN;issue some commands ...PRECOMMIT;-- if the above does not return an error, thenCOMMIT;
In other words, 2PC would require some new commands, but a new command
doesn't affect the protocol layer.
regards, tom lane