In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly explains "what is the Schedule feature of Oracle scheduling". The content of the explanation is simple and clear, and it is easy to learn and understand. Please follow the editor's train of thought to study and learn "what are the features of Oracle scheduling Schedule".
The concept of Job Classes is equivalent to creating a job group. DBA can put all those job with the same characteristics into the same Job Classes.
Then, by applying the Resource usage Plan feature in ORACE to Job Class, you can manage the resource allocation needed during the execution of these job.
1. Create a Job Classes
Create a Job Classes using the CREATE_JOB_CLASS process of the DBMS_SCHEDULER package
Begin
Dbms_scheduler.create_job_class ('myjobclass1')
End
The name of the Job Class to be created by JOB_CLASS_NAME. Note that the specified length should not exceed 30 characters, nor should it have the same name as the existing Job Class.
RESOURCE_CONSUMER_GROUP specifies the RCG (Resource Consumer Group) where the created Job Class is located.
You can think of it as a way of allocating resources, in which users, sessions, or objects in the same RCG group share a set of resources, and the resources available for allocation are allocated to the RCG in the way specified by DBA.
If the design is reasonable, in this way, the resources of the server can be used more effectively.
SERVICE specifies the Service where the Job Class is created. This option is common in the RAC environment. We all know that the RAC environment consists of multiple instances + databases. The Service specified here actually refers to the instance on which the Job Class will run.
Note: this parameter conflicts with the RESOURCE_CONSUMER_GROUP parameter, and only one of the two parameters is set for the same Job Class.
LOGGING_LEVEL specifies the level of logging, with the following three levels
N DBMS_SCHEDULER.LOGGING_OFF: turn off logging
N DBMS_SCHEDULER.LOGGING_RUNS: record the running information of all tasks under this Job Class
N DBMS_SCHEDULER.LOGGING_FULL: record all the relevant information about the task under the Job Class, including not only the operation of the task, but also the creation and modification of the task.
LOG_HISTORY: specify the time of logging in days. For example, specify a value of 90 for the LOG_HISTORY parameter, which means that the log information is retained for the last 90 days.
COMMENTS specifies comment information
All the above parameters are optional, except that LOG_CLASS_NAME is a required parameter.
2. You can query the Job Classes that already exists in the system through the DBA_SCHEDULER_JOB_CLASSES view (or ALL_SCHEDULER_JOB_CLASS view), for example:
Select job_class_name,resource_consumer_group,service from dba_scheduler_job_classes where job_class_name = 'MYJOBCLASS1'
JOB_CLASS_NAME RESOURCE_CONSUMER_GROUP SERVICE
-
MYJOBCLASS1
When you create a Jobs, you can specify the Job Class where the job is located through the JOB_CLASS parameter. If not, the created job belongs to DEFAULT_JOB_CLASS by default.
As for how to query which Job Class the created jobs belongs to, query the * _ SCHEDULER_JOBS view.
3. Manage Job Classes
You should also remember that the DBMS_SCHEDULER.SET_ATTRIBUTE process was used in the previous section to modify the properties of job. In fact, SET_ATTRIBUTE can also be used to modify the properties of Job Class.
The operation method is exactly the same as modifying the job attribute, except that the scope of the function is wider. After modifying the Job Class, all job attributes under the Job Class will be cascaded (those currently running will not take effect immediately, but will not take effect until the next run).
For example: modify the log save time of the MY_FIRST_JC you just created
Begin
DBMS_SCHEDULER.SET_ATTRIBUTE ('MYJOBCLASS1','LOG_HISTORY','30')
End
The properties that can be modified by the Job Class, that is, the five attributes that can be selected when created.
4. Delete Job Classes
The DBMS_SCHEDULER package provides a DROP_JOB_CLASS procedure for deleting Job Classes. The procedure call is very simple, for example, delete the MYJOBCLASS1 you just created, and execute the command as follows:
Begin
DBMS_SCHEDULER.DROP_JOB_CLASS ('MYJOBCLASS1')
End
If you have more than one Job Classes to delete, you don't need to execute DROP_JOB_CLASS multiple times, you just need to separate the parameter values with commas when you specify values for the procedure.
Thank you for your reading, the above is the content of "what is the Schedule feature of Oracle scheduling". After the study of this article, I believe you have a deeper understanding of what the Schedule feature of Oracle scheduling is, and the specific use needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.