 |
|
Oracle Managing
Job Chains
Oracle Tips by Burleson Consulting |
This
is an excerpt from "Oracle 10g New Features for Administrators" by
Ahmed Baraka.
• The RUN_CHAIN procedure immediately runs a chain
by creating a run-once job with the job name given. If no job_name
is given, one is automatically assigned in the form
SCHED_CHAIN_JOB${N}. If a list of start steps is given, only those
steps are started when the chain begins running (steps that would
have normally started are not run). If no list of start steps is
given, then the chain starts normally
DBMS_SCHEDULER.RUN_CHAIN('chain_name','job_name','steps_to_start')
• The DROP_CHAIN_RULE procedure removes a rule from
an existing chain. If dropping this rule makes the chain invalid,
the user should first disable the chain to ensure that it does not
run.
DBMS_SCHEDULER.DROP_CHAIN_RULE('chain_name','rule_name')
• Disable a chain
DBMS_SCHEDULER.DISABLE('chain_name')
• Drop a chain
DBMS_SCHEDULER.DROP_CHAIN('chain_name')
• Alter the SKIP or PAUSE attributes of a chain step
by using the ALTER_CHAIN procedure. The ALTER_CHAIN procedure
affects only future runs of the specified steps.
• Alter the steps in a running chain by using the
ALTER_RUNNING_CHAIN procedure
• Drop a step from a chain by using the
DROP_CHAIN_STEP procedure
Monitoring Job Chains
DBA_SCHEDULER_CHAINS - contains information about
the chain owner and name; the rule set name and rule set owner for
the chain; the number of rules; the number of steps; whether or not
the chain is enabled; whether or not the chain uses an evaluation
interval; and whether or not the chain uses a user-defined rule set.
DBA_SCHEDULER_CHAIN_RULES - displays the name and
owner of the chain for which the rule was defined; the rule name,
owner, and condition; and the action to be performed if the
condition evaluates to TRUE.
DBA_SCHEDULER_CHAIN_STEPS - displays the name and
owner of the chain for which the step was created; the step name;
the program name and owner; whether the step should be skipped or
not; and whether or not the step should be paused after it
completes.
DBA_SCHEDULER_RUNNING_CHAINS - contains the chain
name and owner; the name and owner of the job that points to the
chain; the name of the steps in the chain and their current state;
errors encountered by the chain step; the time at which the chain
step started and ended; how long it took the step to complete; and
the name of the job running the step, if it is current executing.
 |
If you like Oracle tuning, see the
book "Oracle
Tuning: The Definitive Reference", with 950 pages of tuning
tips and scripts.
You can buy it direct from the publisher for 30%-off and get
instant access to the code depot of Oracle tuning scripts. |