Subject | Re: [Firebird-Architect] Question on classic |
---|---|
Author | Dmitry Yemanov |
Post date | 2005-10-26T10:17:11Z |
"Ann W. Harrison" <aharrison@...> wrote:
relies on the transaction cache. TPC_snapshot_state() returns its cached
value only if it's committed or dead. For supposedly active transaction it
tries to get a lock of the transaction ID. If failed - return active. If
succeeded, refetch the TIP.
Looks correct and reliable for classic at the first glance.
Dmitry
>VIO asks TRA_snapshot_state(). For read-committed, TRA_snapshot_state()
> He stores a record in thread1 and commits it, then wakes
> thread2. Thread2 doesn't immediately see the new record,
> but does eventually. In thinking it over, I'm not at all
> sure how or when the state of newly committed transactions
> is conveyed to separate classic processes. Do you know?
relies on the transaction cache. TPC_snapshot_state() returns its cached
value only if it's committed or dead. For supposedly active transaction it
tries to get a lock of the transaction ID. If failed - return active. If
succeeded, refetch the TIP.
Looks correct and reliable for classic at the first glance.
Dmitry