Quartz.NET is an open-source job scheduling framework, which is very suitable for regular polling of database synchronization, scheduled email notifications, and regular processing of data in daily work.
Quartz.NET allows developers to schedule jobs based on time intervals (or days). It implements a many-to-many relationship between jobs and triggers, and can also associate multiple jobs with different triggers.
Applications that integrate Quartz.NET can reuse jobs from different events and combine multiple jobs for a single event.
- Official Learning Documentation: http://www.quartz-scheduler.net/documentation/index.html
- Usage examples: http://www.quartz-scheduler.net/documentation/quartz-2.x/quick-start.html
- Official source code download: http://sourceforge.net/projects/quartznet/files/quartznet/
Quartz.net Remote task scheduling framework,.NET framework 4.5 is an example, other .net versions, please self-test
The project has two levels: Job-Client (Execute Tasks) and Job-Server (Task Scheduling)
Job-Client
nuget install: Install-Package Quartz -Version 2.6.1
Job-Server
nuget install: Install-Package Quartz -Version 2.6.1 Install-Package CrystalQuartz.Remote -Version 4.2.1
As shown below:
The Job-Client code is as follows:
Job-Server only needs to modify the web.config configuration
After we install CrystalQuartz.Remote, web.config will add the configuration as shown in the figure above, since we are not using port 555, we only need to modify the port
Once the modifications are complete, start the project
Browser input: http://localhost:port/CrystalQuartzPanel.axd
The full web.config configuration is as follows:
Start Job-Client first, and then start Job-Server, as shown in the following figure:
Pause the task
Resume mission
Finally, attach the source code:
Tourists, if you want to see the hidden content of this post, please Reply
|