2.314 PRIORITY_TXNS_MODE

PRIORITY_TXNS_MODE specifies the mode for Priority Transactions.

Property Description

Parameter type

String

Syntax

PRIORITY_TXNS_MODE = { ROLLBACK | TRACK }

Default value

ROLLBACK

Modifiable

ALTER SYSTEM

Modifiable in a PDB

Yes

Basic

No

Oracle RAC

Multiple instances must have the same value.

Values:

  • ROLLBACK - This setting enables Priority Transactions. The database will automatically roll back low-priority transactions that are blocking higher priority transactions from obtaining row locks.

    Before enabling Priority Transactions, ensure that the following initialization parameters are configured properly:

    • PRIORITY_TXNS_HIGH_WAIT_TARGET - Specifies the maximum number of seconds that a HIGH priority transaction will wait for a row lock

    • PRIORITY_TXNS_MEDIUM_WAIT_TARGET - Specifies the maximum number of seconds that a MEDIUM priority transaction will wait for a row lock

    • TXN_PRIORITY - Specifies a priority (HIGH, MEDIUM, or LOW) for all transactions in a user session

    When running in ROLLBACK mode, you can track the performance of Priority Transactions by monitoring the following statistics:

    • txns rollback priority_txns_high_wait_target

    • txns rollback priority_txns_medium_wait_target

  • TRACK - This setting allows you to track the potential behavior of Priority Transactions. You can use this mode to tune the Priority Transactions initialization parameters before enabling ROLLBACK mode.

    The database determines when HIGH and MEDIUM priority transactions would be rolled back, given the current values of the Priority Transactions initialization parameters. However, instead of actually rolling back the transactions, the database only increments the following statistics:

    • txns track mode priority_txns_high_wait_target

    • txns track mode priority_txns_medium_wait_target

    You can also monitor the following wait events to determine the amount of time transactions are waiting for row locks:

    • enq: TX - row lock (HIGH priority)

    • enq: TX - row lock (MEDIUM priority)

    • enq: TX - row lock (LOW priority)

Note:

This parameter is available starting with Oracle Database 23ai.