In order to create a LEADTOOLS Job Processor Worker it is only necessary to create an assembly whose class derives from the JobBase class. After a new job is received, the windows service will spawn a new process to handle the job. The new process will load your worker assembly and call the OnJobReceived Method so that your assembly can begin working on the job. The typical workflow for implementing a worker can be summed up as follows:
Create an assembly that derives from the JobBase class.
Override the OnJobReceived Method to include any code necessary to start processing your job. This method should block until job processing is complete.
Call UpdatePercentage to inform the windows service of the current progress. If the UpdatePercentage Method returns false, the job was either aborted or deleted by the user. When the UpdatePercentage Method returns false, stop processing and call the SetAbortedStatus Method. For more information, refer to the UpdatePercentage Method.
Upon successful completion of the job processing, call the SetCompletedStatus Method.
If the job fails for any reason call the SetFailureStatus Method.
If your process hangs, the windows service will terminate the process. If your process is killed or unexpectedly terminates, the worker assembly will be reloaded and the OnJobTerminated Method (if implemented) will be called so that you can react accordingly to the error. For more information, refer to OnJobTerminated.
The configuration file allows you to specify the namespace and class of your assembly, instructing the process which assembly to load when a new job is received. For more information, refer to LEADTOOLS Job Processor Settings.
Programming with the LEADTOOLS Distributed Computing (Job Processor) SDK
LEADTOOLS Job Processor Settings
Creating Job Processor Worker Assemblies Tutorial
Understanding The LEADTOOLS Job Processor Database
Deploying LEADTOOLS Distributed Computing (JobProcessor) Applications
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document