Oracle8i Supplied Packages Reference Release 8.1.5 A68001-01 |
|
DBMS_DEFER_SYS
procedures manage default replication node lists.
This package is the system administrator interface to a replicated transactional deferred remote procedure call facility. Administrators and replication daemons can execute transactions queued for remote nodes using this facility, and administrators can control the nodes to which remote calls are destined.
Subprogram | Description |
---|---|
ADD_DEFAULT_DEST procedure |
Adds a destination database to the |
DELETE_DEFAULT_DEST procedure |
Removes a destination database from the |
DELETE_DEF_DESTINATION procedure |
Removes a destination database from the |
DELETE_ERROR procedure |
Deletes a transaction from the |
DELETE_TRAN procedure |
Deletes a transaction from the |
DISABLED function |
Determines whether propagation of the deferred transaction queue from the current site to a given site is enabled. |
EXCLUDE_PUSH function |
Acquires an exclusive lock that prevents deferred transaction |
EXECUTE_ERROR procedure |
Re-executes a deferred transaction that did not initially complete successfully. |
EXECUTE_ERROR_AS_USER procedure |
Re-executes a deferred transaction that did not initially complete successfully. |
PURGE function |
Purges pushed transactions from the deferred transaction queue at your current master or snapshot site. |
PUSH function |
Forces a deferred remote procedure call queue at your current master or snapshot site to be pushed to another master site. |
REGISTER_PROPAGATOR procedure |
Registers the given user as the propagator for the local database. |
SCHEDULE_PURGE procedure |
Schedules a job to purge pushed transactions from the deferred transaction queue at your current master or snapshot site. |
SCHEDULE_PUSH procedure |
Schedules a job to push the deferred transaction queue to a remote master destination. |
SET_DISABLED procedure |
Disables or enables propagation of the deferred transaction queue from the current site to a given destination site. |
UNREGISTER_PROPAGATOR procedure |
Unregister a user as the propagator from the local database. |
UNSCHEDULE_PURGE procedure |
Stops automatic purges of pushed transactions from the deferred transaction queue at a snapshot or master site. |
UNSCHEDULE_PUSH procedure |
Stops automatic pushes of the deferred transaction queue from a snapshot or master site to another master site. |
This procedure adds a destination database to the DEFDEFAULTDEST
view.
DBMS_DEFER_SYS.ADD_DEFAULT_DEST ( dblink IN VARCHAR2);
Parameter | Description |
---|---|
dblink |
The fully qualified database name of the node that you want to add to the |
Exception | Description |
---|---|
ORA-23352 |
The |
This procedure removes a destination database from the DEFDEFAULTDEST
view.
DBMS_DEFER_SYS.DELETE_DEFAULT_DEST ( dblink IN VARCHAR2);
This procedure removes a destination database from the DEFSCHEDULE
view.
DBMS_DEFER_SYS.DELETE_DEF_DESTINATION ( destination IN VARCHAR2, force IN BOOLEAN := FALSE);
To delete a transaction from the DEFERROR
view.
DBMS_DEFER_SYS.DELETE_ERROR( deferred_tran_id IN VARCHAR2, destination IN VARCHAR2);
To delete a transaction from the DEFTRANDEST
view. If there are no other DEFTRANDEST
or DEFERROR
entries for the transaction, then the transaction is deleted from the DEFTRAN
and DEFCALL
views as well.
DBMS_DEFER_SYS.DELETE_TRAN ( deferred_tran_id IN VARCHAR2, destination IN VARCHAR2);
To determine whether propagation of the deferred transaction queue from the current site to a given site is enabled. The DISABLED
function returns TRUE
if the deferred remote procedure call (RPC) queue is disabled for the given destination.
DBMS_DEFER_SYS.DISABLED ( destination IN VARCHAR2) RETURN BOOLEAN;
Parameter | Description |
---|---|
destination |
The fully qualified database name of the node whose propagation status you want to check. |
Return | Description |
---|---|
TRUE |
Propagation to this site from the current site is disabled. |
FALSE |
Propagation to this site from the current site is enabled. |
Exception | Description |
---|---|
NO_DATA_FOUND |
|
To acquire an exclusive lock that prevents deferred transaction PUSH
(either serial or parallel). This function does a commit when acquiring the lock. The lock is acquired with RELEASE_ON_COMMIT
=>
TRUE
, so that pushing of the deferred transaction queue can resume after the next commit.
DBMS_DEFER_SYS.EXCLUDE_PUSH ( timeout IN INTEGER) RETURN INTEGER;
Return | Description |
---|---|
0 |
Success, lock acquired. |
1 |
Timeout, no lock acquired. |
2 |
Deadlock, no lock acquired. |
4 |
Already own lock. |
To reexecute a deferred transaction that did not initially complete successfully. This procedure raises an ORA-24275
error when illegal combinations of NULL
and non-NULL
parameters are used.
DBMS_DEFER_SYS.EXECUTE_ERROR ( deferred_tran_id IN VARCHAR2, destination IN VARCHAR2);
Exception | Description |
---|---|
badparam |
Parameter value missing or invalid (for example, if |
missinguser |
Invalid user. |
To reexecute a deferred transaction that did not initially complete successfully. Each transaction is executed in the security context of the connected user. This procedure raises an ORA-24275
error when illegal combinations of NULL
and non-NULL
parameters are used.
DBMS_DEFER_SYS.EXECUTE_ERROR_AS_USER ( deferred_tran_id IN VARCHAR2, destination IN VARCHAR2);
Exception | Description |
---|---|
badparam |
Parameter value missing or invalid (for example, if destination is |
missinguser |
Invalid user. |
To purge pushed transactions from the deferred transaction queue at your current master or snapshot site.
DBMS_DEFER_SYS.PURGE ( purge_method IN BINARY_INTEGER := purge_method_quick, rollback_segment IN VARCHAR2 := NULL, startup_seconds IN BINARY_INTEGER := 0, execution_seconds IN BINARY_INTEGER := seconds_infinity, delay_seconds IN BINARY_INTEGER := 0, transaction_count IN BINARY_INTEGER := transactions_infinity, write_trace IN BOOLEAN := NULL); RETURN BINARY_INTEGER;
Exception | Description |
---|---|
argoutofrange |
Parameter value is out of a valid range. |
executiondisabled |
Execution of purging is disabled. |
defererror |
Internal error. |
This function forces a deferred remote procedure call queue at your current master or snapshot site to be pushed (executed, propagated) to another master site using either serial or parallel propagation.
DBMS_DEFER_SYS.PUSH ( destination IN VARCHAR2, parallelism IN BINARY_INTEGER := 0, heap_size IN BINARY_INTEGER := 0, stop_on_error IN BOOLEAN := FALSE, write_trace IN BOOLEAN := FALSE, startup_seconds IN BINARY_INTEGER := 0, execution_seconds IN BINARY_INTEGER := seconds_infinity, delay_seconds IN BINARY_INTEGER := 0, transaction_count IN BINARY_INTEGER := transactions_infinity, delivery_order_limit IN NUMBER := delivery_order_infinity) RETURN BINARY_INTEGER;
This procedure registers the given user as the propagator for the local database. It also grants to the given user CREATE
SESSION
, CREATE
PROCEDURE
, CREATE
DATABASE
LINK
, and EXECUTE
ANY
PROCEDURE
privileges (so that the user can create wrappers).
DBMS_DEFER_SYS.REGISTER_PROPAGATOR ( username IN VARCHAR2);
Parameter | Description |
---|---|
username |
Name of the user. |
Exception | Description |
---|---|
missinguser |
Given user does not exist. |
alreadypropagator |
Given user is already the propagator. |
duplicatepropagator |
There is already a different propagator. |
This procedure schedules a job to purge pushed transactions from the deferred transaction queue at your current master or snapshot site. You should schedule one purge job.
DBMS_DEFER_SYS.SCHEDULE_PURGE ( interval IN VARCHAR2, next_date IN DATE, reset IN BOOLEAN := NULL, purge_method IN BINARY_INTEGER := NULL, rollback_segment IN VARCHAR2 := NULL, startup_seconds IN BINARY_INTEGER := NULL, execution_seconds IN BINARY_INTEGER := NULL, delay_seconds IN BINARY_INTEGER := NULL, transaction_count IN BINARY_INTEGER := NULL, write_trace IN BOOLEAN := NULL);
This procedure schedules a job to push the deferred transaction queue to a remote master destination. This procedure does a COMMIT
.
DBMS_DEFER_SYS.SCHEDULE_PUSH ( destination IN VARCHAR2, interval IN VARCHAR2, next_date IN DATE, reset IN BOOLEAN := FALSE, parallelism IN BINARY_INTEGER := NULL, heap_size IN BINARY_INTEGER := NULL, stop_on_error IN BOOLEAN := NULL, write_trace IN BOOLEAN := NULL, startup_seconds IN BINARY_INTEGER := NULL, execution_seconds IN BINARY_INTEGER := NULL, delay_seconds IN BINARY_INTEGER := NULL, transaction_count IN BINARY_INTEGER := NULL);
To disable or enable propagation of the deferred transaction queue from the current site to a given destination site. If the disabled parameter is TRUE
, then the procedure disables propagation to the given destination and future invocations of PUSH
do not push the deferred remote procedure call (RPC) queue. SET_DISABLED
eventually affects a session already pushing the queue to the given destination, but does not affect sessions appending to the queue with DBMS_DEFER
.
If the disabled parameter is FALSE
, then the procedure enables propagation to the given destination and, although this does not push the queue, it permits future invocations to PUSH
to push the queue to the given destination. Whether the disabled parameter is TRUE
or FALSE
, a COMMIT
is required for the setting to take effect in other sessions.
DBMS_DEFER_SYS.SET_DISABLED ( destination IN VARCHAR2, disabled IN BOOLEAN := TRUE);
Exception | Description |
---|---|
NO_DATA_FOUND |
No entry was found in the |
To unregister a user as the propagator from the local database. This procedure
DEFPROPAGATOR
.
REGISTER_PROPAGATOR
from the given user (including identical privileges granted independently).
DBMS_DEFER_SYS.UNREGISTER_PROPAGATOR ( username IN VARCHAR2, timeout IN INTEGER DEFAULT DBMS_LOCK.MAXWAIT);
Parameter | Description |
---|---|
username |
Name of the propagator user. |
timeout |
Timeout in seconds. If the propagator is in use, then the procedure waits until timeout. The default is |
Parameter | Description |
---|---|
missingpropagator |
Given user is not a propagator. |
propagator_inuse |
Propagator is in use, and thus cannot be unregistered. Try later. |
This procedure stops automatic purges of pushed transactions from the deferred transaction queue at a snapshot or master site.
DBMS_DEFER_SYS.UNSCHEDULE_PURGE;
None
This procedure stops automatic pushes of the deferred transaction queue from a snapshot or master site to another master site.
DBMS_DEFER_SYS.UNSCHEDULE_PUSH ( dblink IN VARCHAR2);
Parameter | Description |
---|---|
dblink |
Fully qualified pathname to master database site at which you want to unschedule periodic execution of deferred remote procedure calls. |
Exception | Description |
---|---|
NO_DATA_FOUND |
No entry was found in the |