Skip site navigation (1) Skip section navigation (2)

Re: Transactional support across multiple machines...

From: Maciek Sakrejda <msakrejda(at)truviso(dot)com>
To: Peter Tap <ptrtap(at)yahoo(dot)com>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Transactional support across multiple machines...
Date: 2010-11-17 19:15:36
Message-ID: AANLkTim2TEDOiBN+bLWrf7gb4xfz3zJqTC4BGpyxyHTA@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-jdbc
Once the transactions are prepared, they are serialized to disk and
you will be able to go back and commit them later even if you have a
database crash (assuming safe postgresql.conf settings). All
distributed commit mechanisms will be built on something like this
under the hood--there is no magical "commit everywhere atomically"
functionality (perhaps with quantum computing ;) ). But Heikki is
right--you probably want to go through higher-level APIs like JTA.
Just make sure you understand the recovery guarantees if you fail in
the middle of, e.g., a JTA commit, which could translate into some
committed prepared transactions and some uncommitted ones, or some
rolled back and some prepared.

Everything you need to either commit or roll back (depending on when
the failure occurred) the full set of transactions will be there on
disk, but I don't know whether the JTA implementation will do that for
you. And you definitely don't want prepared transactions sitting
around on disk indefinitely.
---
Maciek Sakrejda | System Architect | Truviso

1065 E. Hillsdale Blvd., Suite 215
Foster City, CA 94404
(650) 242-3500 Main
www.truviso.com

In response to

pgsql-jdbc by date

Next:From: Michael ForkDate: 2010-11-18 05:26:20
Subject: Re: PSQLException: The column name <col> was not found in this ResultSet.
Previous:From: Peter TapDate: 2010-11-17 18:55:21
Subject: Re: Transactional support across multiple machines...

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group