Is there a way to turn an existing class library into a worker role?
I don't want to add more projects to the solution especially when this project will only call MyLibrary.Class.Run()
.
How to turn existing class library into worker role
1.8k Views Asked by Uri Abramson At
2
Eventually, I found the solution:
Add a cloud service project to the solution
I had to edit the project file of my class library and add this:
<RoleType>Worker</RoleType>
to the first<PropertyGroup>
element.In addition to that, my service entry point class had to extend
RoleEntryPoint
.Once this is done, right click no the Roles folder in the cloud service project and choose Add -> Worker role project in solution and choose my Class Library.
That's it.