Monday, July 6, 2020

Oracle: Readers can block Writers (in distributed transactions)

https://docs.oracle.com/cd/E11882_01/server.112/e25494/ds_txns.htm#i1007836

Queries that start after a node has prepared cannot access the associated locked data until all phases complete.

A distributed transaction is ANY operation across a database link. It will result in a total table lock and access will be serialized. :(

This means a long running query for a data warehouse will lock the source tables for the duration of the transaction, until the client COMMIT's. It also means that the client will wait until it can obtain a table-level lock on the object. This behaviour is influenced by the system parameter DISTRIBUTED_LOCK_TIMEOUT.

It also implies that, SCN's are local, and foreign context is limited.

No comments:

Post a Comment