EVO HTML to PDF Converter

Install EVO PDF Server in an Azure Cloud Service Worker Role

EVO PDF Client for .NET Documentation

When the HTML to PDF Server runs in a Worker Role of an Azure Cloud Service it can be accessed through an IP address which is automatically assigned at deployment time and a TCP port which is 40001 by default.

The Azure Cloud Service Worker Role can be found in 'Server\Azure\CloudService\TCP_WorkerRole' folder of the location where you extracted the Zip archive of the software. The folder contains the prebuilt package in the 'Bin' subfolder and the Visual Studio source project in 'Src' subfolder.

There are two options to install the HTML to PDF Server in Azure Cloud Service Worker Role: from the Visual Studio solution or from the prebuilt package. The prebuilt package is exported from the Visual Studio solution to be used in case you don't have the Azure development tools installed on your machine.

Installing the Azure Worker Role from the Visual Studio

The Visual Studio Solution for Azure Cloud Service Worker Role there is in 'Server\Azure\CloudService\TCP_WorkerRole\Src' folder.

Before publishing the service you can set in the 'Server\Azure\CloudService\TCP_WorkerRole\Src\ServiceConfiguration.Cloud.cscfg' configuration file various options like a service password or the maximum number of conversions running at the same time.

To publish the Cloud Service from Visual Studio, open the 'EvoHtmlToPdfAzureService.sln' solution in Visual Studio, right click on 'EvoHtmlToPdfAzureService' project and choose 'Publish' option from the contextual menu.

In the first panel 'Sign In' of the publish wizard choose your Azure subscription and click 'Next'.

In the next panel 'Settings', a popup panel might appear and ask you to create a new Storage Account in case you don't have any Storage Account in your Azure Portal account. In this case choose a name for the new storage account and a 'Region or Affinity Group'. Leave the default value for the other options and click the 'Create' button to go back to the 'Settings' panel.

In the 'Common Settings' tab of the 'Settings' panel, under the 'Cloud Service' option, choose to create a new cloud service or use the suggested name in case you did not have any previous cloud service or storage account in your Azure account. If you choose to create a new Cloud Service you will be prompted to select a name for the cloud service and a 'Region or Affinity Group' for deployment. Click the 'Create' button to return to the 'Settings' panel. Leave the default value for the other options in the 'Settings' panel and click the 'Next' button.

In the next panel 'Diagnostics' choose if you want to send telemetry data to Microsoft and click the 'Next' button.

In the 'Summary' panel you can review the options you have chosen. If everything looks good you can click the 'Publish' button to create and start the cloud service.

You'll be able to see the evolution of the deployment process in Visual Studio. When the deployment is complete you can login into your account of Microsoft Azure Portal to obtain the public IP address of the HTML to PDF service.

In Azure Portal you can find the Cloud Service you created if you select 'All resources' item from the menu of the Azure Management Portal. Click the link to cloud service from the list of resources to open the cloud service 'Overview' panel. In that panel you can see the current status of the cloud service and obtain information about the service.

When the deployment finished and the service instance is running, click the cloud service instance to open instance properties panel where you can find the service public IP address. You can use this IP address to connect the client library to service in our demo applications and in your applications.

Installing the Azure Worker Role from Prebuilt Package

The Visual Studio Solution for Azure Cloud Service Worker Role there is in 'Server\Azure\CloudService\TCP_WorkerRole\Src' folder.

Before publishing the service you can set in the 'Server\Azure\CloudService\TCP_WorkerRole\Src\ServiceConfiguration.Cloud.cscfg' configuration file various options like a service password or the maximum number of conversions running at the same time.

To publish the Cloud Service from Visual Studio, open the 'EvoHtmlToPdfAzureService.sln' solution in Visual Studio, right click on 'EvoHtmlToPdfAzureService' project and choose 'Publish' option from the contextual menu.

In the first panel 'Sign In' of the publish wizard choose your Azure subscription and click 'Next'.

In the next panel 'Settings', a popup panel might appear and ask you to create a new Storage Account in case you don't have any Storage Account in your Azure Portal account. In this case choose a name for the new storage account and a 'Region or Affinity Group'. Leave the default value for the other options and click the 'Create' button to go back to the 'Settings' panel.

In the 'Common Settings' tab of the 'Settings' panel, under the 'Cloud Service' option, choose to create a new cloud service or use the suggested name in case you did not have any previous cloud service or storage account in your Azure account. If you choose to create a new Cloud Service you will be prompted to select a name for the cloud service and a 'Region or Affinity Group' for deployment. Click the 'Create' button to return to the 'Settings' panel. Leave the default value for the other options in the 'Settings' panel and click the 'Next' button.

In the next panel 'Diagnostics' choose if you want to send telemetry data to Microsoft and click the 'Next' button.

In the 'Summary' panel you can review the options you have chosen. If everything looks good you can click the 'Publish' button to create and start the cloud service.

You'll be able to see the evolution of the deployment process in Visual Studio. When the deployment is complete you can login into your account of Microsoft Azure Portal to obtain the public IP address of the HTML to PDF service.

In Azure Portal you can find the Cloud Service you created if you select 'All resources' item from the menu of the Azure Management Portal. Click the link to cloud service from the list of resources to open the cloud service 'Overview' panel. In that panel you can see the current status of the cloud service and obtain information about the service.

When the deployment finished and the service instance is running, click the cloud service instance to open instance properties panel where you can find the service public IP address. You can use this IP address to connect the client library to service in our demo applications and in your applications.

HTML to PDF Server Configuration Options

Before publishing the service you can set in the 'ServiceConfiguration.Cloud.cscfg' configuration file various options like a service password or the maximum number of conversions running at the same time. The configuration options are listed below.

  • Distributed Option - This option is false by default and it can be enabled to run each conversion in a separate process. It offers more isolation between parallel conversions but it can be slower.

  • MaxConcurrentClients Option - This option has value 12 by default and it indicates how many conversions are running in parallel. If the maximum number of parallel conversions was reached the subsequent conversion are queued until an execution slot becomes available.

  • ServicePassword Option - This option is empty by default and it can be set with a password string to be verified by the service before accepting a conversion request.

  • Impersonation Options - The ImpersonationUsername, ImpersonationPassword, ImpersonationDomain and ImpersonationLogonMode options are empty by default and they can be used to run the service under a specific user account on the hosting Windows machine.

Uninstallation

You can remove the cloud service from your Azure account management portal.