LEAD Technologies, Inc

Deploying a Cloud

To deploy your cloud solution, you must deploy the necessary server and worker components.

Server

The server hosts the JobService and WorkerService, which are consumed by the client and workers to communicate with the central server. The below dll's are required to host these services.

Create a virtual directory , and include the above dll's in the application bin directory. Locate both the JobService and WorkerService SVC files in the root of the virtual directory. LEADTOOLS includes the JobService.svc and WorkerService.svc files which can be used when deploying.

The WCF service web.config should contain the below settings.

The Workers.xml must be located in the App_Data directory of the virtual directory. This configuration file defines the settings for each worker in the cloud. For more information on these configuration files and their settings, refer to LEADTOOLS Cloud Settings.

LEADTOOLS includes a SQL script file (LEADTOOLS Cloud Server 17.5\Examples\DotNet\CS\CloudServerConfigDemo\Resources\ASPNetSqlReg.sql) which can be used to install the database, tables, stored procedures, etc, in any SQL database. Alternatively, the existing database installed with the toolkit can be attached to any SQL server instance. If the default settings were used to install the database, the database files (LEADTOOLSCloudDB.mdf and LEADTOOLSCloudDB_log.LDF can be found in MSSQL\Data directory.

For more information on the Cloud database, refer to Understanding The LEADTOOLS Cloud Database.

Worker

Each worker machine requires the windows worker service to be installed. The below dll's are required when deploying the worker service.

The windows service can be installed using InstallUtil.exe (included with .NET framework). For more information on InstallUtil.exe, refer to http://msdn.microsoft.com/en-us/library/50614e95(v=vs.80).aspx. The worker service accepts command line arguments used to specify the description and display name of the service (see below for example). This is especially useful when multiple services, each being responsible for a different job type, are installed on the same machine. For more information on using multiple job types, refer to Understanding the LEADTOOLS Cloud Database.

To install the service:

Installutil /ServiceName= "ServiceName" /Description="ServiceDescription" /DisplayName="ServiceDisplayName" [ServicePath]

Example - Installutil /ServiceName="LEADTOOLSOcrCloudService" /Description="LEADTOOLS OCR Cloud Service" /DisplayName="LEADTOOLSOcrCloudService" "C:\Cloud\MyService.exe"

To uninstall the service:

Installutil /u /ServiceName= "ServiceName" /Description="ServiceDescription" /DisplayName="ServiceDisplayName" [ServicePath]

Example - Installutil /u /ServiceName="LEADTOOLSOcrCloudService" /Description="LEADTOOLS OCR Cloud Service" /DisplayName="LEADTOOLSOcrCloudService" "C:\Cloud\MyService.exe"

The Worker layer (Leadtools.Cloud.WorkerLayer.exe) is responsible for loading your custom worker assembly responsible for actually processing jobs. This executable is provided in both Win32 and x64 configurations so be sure to deploy the correct version based on the target configuration of your worker assembly. For more information on creating worker assemblies, refer to Creating Cloud Worker Assemblies.

The worker service configuration file (Leadtools.Cloud.WorkerService.exe.config) should contain the below settings.

If installing multiple services, you should either deploy the worker service executable for each service to separate directories, or rename the service executable (and config file) uniquely for the service it belongs to. This allows each service to have its own configuration file, specifying specific settings for each service. This is useful in cases where a single machine will host multiple services, each responsible for a specific job type. For more information on these settings, refer to LEADTOOLS Cloud Settings.

 

 


Products | Support | Contact Us | Copyright Notices

© 2006-2012 All Rights Reserved. LEAD Technologies, Inc.