I'm developing an ASP.NET web application. There is some functionality I need to trigger every 10 minutes. So currently I'm considering a 'scheduled task' or to create a Windows service to call the URL.
But I remember once I did the same thing in a PHP web hosting space, using a cron job.
So is there anything like cron jobs in IIS?
Note: I'm not expecting to use 3rd-party online scheduler services.
Microsoft Windows' counterpart for cron is the Scheduled Task. Each Scheduled Task is planned by the Task Scheduler.
Crontab: Crontab (CRON TABle) is a file which contains the schedule of cron entries to be run and at specified times. File location varies by operating systems. Cron job or cron schedule: Cron job or cron schedule is a specific set of execution instructions specifying day, time and command to execute.
I agree with @Amadan - apples and oranges.
However, I would tend toward writing a custom Windows service for this purpose rather than using Windows Task Scheduler. Another SO question speaks to pros & cons of each option.
While Windows services are straightforward(-enough) to develop, you might consider the open-source Topshelf framework to ease some of the development and deployment quirks that typically come with them.
And to be fair, remember that cron
is not part of PHP of course, just a tool that may be available to you in *nix PHP hosting environments: ASP.NET is no different really; the question is what cron
-like tool is available to you in your ASP.NET environment that meets your requirements and you prefer.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With