Cloud services (the Web / Worker Role role) provide you with a complete virtual machine (VM). Since you wanted to compare WebJobs with a cloud service, I assume that you are interested in the role of the worker. Usually you want to use the worker role to handle background tasks. You can do the same with WebJobs. From what I understand, here are some of the key differences:
- WebJobs are for one purpose only and are designed to handle tasks. You can do the same with a working role, but since you get a full virtual machine, you can do a lot of things with it (for example, by hosting a node.js server).
- If your goal is to run scheduled tasks, WebJobs will make it very easy for you. You essentially use a console application, deploy it as a WebJob, and then plan your work through the portal. With WorkerRole, this is not so straightforward. In fact, you are responsible for scheduling tasks that you could do either through the built-in .Net libraries (System.Timer, etc.), or use third-party schedule libraries such as Quartz.net.
- If your application is dependent on some applications that you need to install, you cannot run through WebJobs. However, you can install additional software as an Employee through startup tasks.
- I assume that in the end they offer
PaaS , but I consider WebJobs to be a true PaaS offer, since you have just started your task, and the platform will take care of planning and performing this task.
Gaurav mantri
source share