Advanced Configuration
File storage
Overview
WorkflowGen stores files (such as attachments to a request) in a folder tree structure. By default these files are stored on the web server in the folder specified in the ApplicationDataPath
parameter in the configuration file (web.config
), e.g. <add key="ApplicationDataPath" value="\\SERVER\SHARE$\wfgen\App_Data" />
.
The default value is empty and thus will point to the physical directory DRIVE:\Inetpub\wwwroot\wfgen\App_Data
. The default is to keep all the files on the web server.
You might need to move this storage folder location to a dedicated file server for the following reasons:
High volume (large attachments, document archiving, high usage level)
Web Farm architecture implementation (see Web Farm architecture)
Basic configuration allows you to easily move these files, but with a low security level.
Basic configuration
The following steps must be followed to configure your web server:
Create the storage folder on the file server
DRIVE:\FOLDER
(e.g.D:\filepub
).Re-create the folder tree structure relative to the file storage location:
DRIVE:\FOLDER\wfgen\App_Data
DRIVE:\FOLDER\wfgen\App_Data\Files\API
DRIVE:\FOLDER\wfgen\App_Data\Files\DataSet
DRIVE:\FOLDER\wfgen\App_Data\Files\EFormASPX
DRIVE:\FOLDER\wfgen\App_Data\Files\MergeForm
DRIVE:\FOLDER\wfgen\App_Data\Files\RemoteApproval
DRIVE:\FOLDER\wfgen\App_Data\Files\RestApiClient
DRIVE:\FOLDER\wfgen\App_Data\Files\XmlToDatabase
DRIVE:\FOLDER\wfgen\App_Data\Files\XmlTrans
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\auth
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\CancelRequest
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\CompleteAction
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\CopyData
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\Dir
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\Engine
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\GetFormData
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\GetProcessData
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\GetUsersFromDir
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\MergeForm
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\Notifications
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\Portal
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\RaiseException
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\RemoteApproval
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\RestApiClient
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\SendHttpPost
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\SendMessage
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\StartProcess
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\UpdateProcessData
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\XmlToDatabase
DRIVE:\FOLDER\wfgen\App_Data\LogFiles\XmlTrans
Copy the existing files and folders from their original locations to the new locations, which should still follow the same structure.
Create a share on the folder
DRIVE:\FOLDER
. This folder should then be accessible by a\\SERVER\SHARE$
type UNC name.Give NTFS modify permissions on the share as well as all of its folders and sub-folders for all users of WorkflowGen.
Edit the
ApplicationDataPath
parameter inDRIVE:\Inetpub\wwwroot\wfgen\web.config
to<add key="ApplicationDataPath" value="\\SERVER\SHARE$\wfgen\App_Data" />
. This is because WorkflowGen will use the specified path inApplicationDataPath
to store the\Files
,\LogFiles
, and\Templates
folders.
Database authentication
Using Windows Authentication instead of SQL Server Authentication
You can set up your SQL Server connection to use Windows Authentication (SSPI) instead of SQL Server Authentication for the WorkflowGen back-end database and other external databases. This SQL authentication mode provides additional security, since no credentials are stored in the web.config
file.
To configure Windows Authentication, use one of the following connection strings in the WorkflowGen web.config
file, located in the DRIVE:\Inetpub\wwwroot\wfgen
folder:
OR
You'll also need to modify the WorkflowGen application pool identity for a service account. To do this:
In IIS Manager, right-click on the WorkflowGen application pool, then select Advanced Settings.
In the Process Model section, select Identity, then click the
...
button.Select Custom Account, then click Set...
Enter your credentials, then click OK.
Make sure the application pools for the other WorkflowGen web applications (
auth
,graphql
,hooks
,scim
,ws
, andwebforms
) match thewfgen
application pool.Make sure the custom account has read/write and modify permissions for the WorkflowGen SQL database and the WorkflowGen files and folders.
Use the same account as the application identity to run the WorkflowGen engine and directory synchronization services.
For more information on SQL Server connection strings, see https://www.connectionstrings.com/sql-server/.
Web Farm architecture
Overview
To allow higher availability and scalability of the application, you can install WorkflowGen in a Web Farm architecture. The application is therefore installed on several servers, but the database and file storage directory are centralized on one dedicated server.
User requests are automatically routed to different servers depending on their load and availability. You can choose between different methods of load balancing such as DNS Round Robin or setup a hardware load balancer.
Configuration
Prerequisites
WorkflowGen on all web servers
File storage centralized in one location
Common
WebForms
folder for all web serversIdentical configuration on all WorkflowGen servers
File storage location
Apply the basic configuration explained in the Basic configuration section before modifying the WorkflowGen configuration.
Setting up a common WebForms folder
If you have configured multiple instances of WorkflowGen on different web servers in a Web Farm setup, you must share the same WebForms
folder for all servers. To do this:
Share your
WebForms
folder. This can be either your primary WorkflowGen site’s localWebForms
folder, or aWebForms
folder on a network file server.If you are using a network file server and you have content in your primary WorkflowGen site’s local
WebForms
folder, we suggest copying the content of this folder to the sharedWebForms
folder.Once you have shared the folder, copy the UNC path.
Do the following for each instance of WorkflowGen:
In IIS, navigate to the
WebForms
application folder.Right-click on the folder, then choose Manage Application / Advanced Settings.
Replace the physical path with the UNC path you copied in step 3.
Add the
<add key="ApplicationWebFormsPath" value="" />
parameter with the UNC path as the value to theweb.config
file.✏️ Note: This parameter is currently only used by the SOAP Web Service API to manage processes and requests with the built-in form designer enabled.
Ensure that the required permissions (modify, read and execute, list folder contents, read, write) are correctly applied to the shared
WebForms
folder for the IIS application pool used by theWebForms
application.
WorkflowGen configuration
Verify that all web servers have the same configuration for the WorkflowGen application and for all workflow applications. The \wfgen\web.config
files must be identical.
The WorkflowGen engine service is a Windows Service that is installed with WorkflowGen and should only be run from one web server. The other servers should only run this service as a backup if the main service fails to run.
Data and application backup is done in the same way except that it only affects the file server (for file type data) and one web server since they have identical configurations (with regards to the applications).
Database file storage mode
Overview
This feature allows process file data (including attachments) to be stored in the database. It allows you to perform WorkflowGen data backup without interrupting service, so that WorkflowGen can still be used during the backup.
Setup and configuration
WorkflowGen web configuration
Set the ApplicationDefaultProcessDataFileStorageMethod
parameter to File
to store process data files in the file system, or set it to Database
to store process data files in the database.
This parameter will define the default process data file storage method when creating a new process or importing a process XPDL of previous version.
Usage
Each process version can have the process data file storage method set independently. This will allow different processes using the file system or database storage method.
New process
On the Process information tab:
Check the Process data storage option Store file content in database to enable the database file storage method.
Uncheck the Process data storage option to disable the database file storage method. This will then use the file system storage method.
Existing process
On the Process information tab:
Uncheck the Process data storage option to disable the database file storage method. This will then use the file system storage method.
When changing process data storage method, the following rules must be applied:
There should be no existing requests using the previous process data storage method. You can either delete existing requests or create a new version of the process.
There should be no existing
FILE
type process data with the default file value using the previous process data storage method. You can delete all default file values, change the process data storage method, and re-upload the default file values into the process data.
Additional information
Temporary files
For a Web Farm architecture, file storage must be centralized in a common shared storage path. The settings in the File storage section must be applied for temporary files.
In the database file storage method, WorkflowGen will still create temporary files in the \wfgen\App_Data
folder (ApplicationDataPath
) to be used by requests and actions at runtime.
These temporary files will be automatically deleted when the requests or actions are completed.
Custom asynchronous system action
To ensure data integrity and 24-hour / 7-days-a-week operation time in database file storage method, your custom asynchronous system action that uses FILE
IN parameters must also save the file content in your custom application database when the file is referenced later by your action.
This will ensure that the file will still exist and can be used later by your asynchronous system action, since only the WorkflowGen database and your custom application database are backed up.
Configuring multiple instances of WorkflowGen
Overview
This section describes how to configure multiple instances of WorkflowGen on the same web server. Each instance of WorkflowGen also requires a dedicated license. This section assumes that you have already installed separate instances of WorkflowGen as described in the Setup section.
For instructions on how to configure multiple instances of WorkflowGen on different servers in a Web Farm setup, see the Web Farm architecture section.
Setup and configuration
To configure multiple instances of WorkflowGen on a single server, perform the steps outlined below. While more than two installations are possible, the following steps assume only two instances are installed.
Before modifying the service, it must be uninstalled using the winsvc-uninstall.cmd
file found in the \bin
folder of the application installation (for example, DRIVE:\Program Files\Advantys\WorkflowGen\Services\bin\winsvc-uninstall.cmd
). Be sure to run it as the administrator of the server.
WorkflowGen directory synchronization service
For both instances of WorkflowGen, edit the parameter name in the WfgDirectoriesSyncService.exe.config
WorkflowGen directory synchronization service configuration file as shown in the following examples.
Instance 1: Edit the
DRIVE:\Program Files\Advantys\WorkflowGen1\Services\bin\WfgDirectoriesSyncService.exe.config
file as follows:Instance 2: Edit the
DRIVE:\Program Files\Advantys\WorkflowGen2\Services\bin\WfgDirectoriesSyncService.exe.config
file as follows:
WorkflowGen engine service
For both instances of WorkflowGen, edit the parameter name in the WfgWorkflowEngineService.exe.config
WorkflowGen engine service configuration file.
Instance 1: Edit the
DRIVE:\Program Files\Advantys\WorkflowGen1\Services\bin\WfgWorkflowEngineService exe.config
file as follows:Instance 2: Edit the
DRIVE:\Program Files\Advantys\WorkflowGen2\Services\bin\WfgWorkflowEngineService exe.config file
as follows:
Windows command scripts (install and uninstall of services)
For both instances of WorkflowGen you need to modify the Windows shell scripts that are used to install and uninstall the WfgDirectoriesSyncService
and WfgWorkflowEngineService
Windows services as described above.
Instance 1:
Install script:
DRIVE:\Program Files\Advantys\WorkflowGen1\Services\bin\winsvc-install.cmd
Based on the value given for theServiceName
parameter defined in the WorkflowGen directory synchronization service section above, yourwinsvc-install.cmd
file should appear as follows:Uninstall script:
DRIVE:\Program Files\Advantys\WorkflowGen1\Services\bin\winsvc-uninstall.cmd
Based on the value given for theServiceName
parameter defined in the WorkflowGen directory synchronization service section above, yourwinsvc-uninstall.cmd
file should appear as follows:
Instance 2:
Install script:
DRIVE:\Program Files\Advantys\WorkflowGen2\Services\bin\winsvc-install.cmd
Based on the value given for theServiceName
parameter defined in the WorkflowGen directory synchronization service section above, yourwinsvc-install.cmd
file should appear as follows:Uninstall script:
DRIVE:\Program Files\Advantys\WorkflowGen2\Services\bin\winsvc-uninstall.cmd
Based on the value given for theServiceName
parameter defined in the WorkflowGen directory synchronization service section above, yourwinsvc-uninstall.cmd
file should appear as follows:
Install the Windows Services
For both instances, you must run the install scripts that have been modified as described above using administrator permissions.
Instance 1:
DRIVE:\Program Files\Advantys\WorkflowGen1\Services\bin\winsvc-install.cmd
Instance 2:
DRIVE:\Program Files\Advantys\WorkflowGen2\Services\bin\winsvc-install.cmd
Database scaling
Overview
The database scaling feature allows for the addition of database servers in order to dramatically improve server performance and response times. The additional read-only replica database servers will be used as dedicated read-only servers (SELECT SQL queries). The read-only database servers are replicated from the existing primary database using the SQL Server Replication service.
This feature is only supported in MS SQL Server.
Requirements
Overview
SQL Server 2014 or later for all database servers
SQL Server Replication feature must be installed on all SQL Server instances
SQL Server Agent must be installed and configured on all SQL Server instances
Setup and configuration
Overview
This section provides a general procedure for configuring the SQL Server Replication service on all the SQL Server instances and enabling the WorkflowGen web server in database scaling mode. This procedure is an example based on one WorkflowGen instance and two database server instances architecture.
If your current architecture differs from this example, you can adapt the procedure and some specific configuration options according to your needs.
Your current WorkflowGen environment must meet the following prerequisites:
The initial WorkflowGen database is already installed on the primary database instance.
The read-only database instance does not contain an existing WorkflowGen database.
The WorkflowGen web server is fully configured and allows access to the Administration Module with a WorkflowGen administrator account.
SQL Server configuration options
It is mandatory to update the SQL Server's max text repl size
configuration option with a higher value in order for the database replication to function properly. We recommend setting this to the maximum value of 2147483647
instead of the default value of 65536
.
Run the following SQL statements in the source (primary) and destination (read-only) SQL Server database instances (this example uses SQL Server 2008):
For more information, see http://msdn.microsoft.com/en-us/library/ms186225.aspx and select your version of SQL Server from the drop-down menu.
SQL Server replication services
To set up a publication on the primary database:
Open SQL Server Management Studio.
Connect to the primary database instance.
Open the Replication node.
Right-click on Local Publications and choose New Publication. The New Publication Wizard will open. Click Next.
Select
WFGEN
in the Publication Database list. Click Next.Select Transactional publication in the Publication type list. Click Next.
Check all Tables and Views (optional if the WorkflowGen Reporting Module is installed in the current database instance) in the Articles list. Click Next.
The Article Issues dialog box will open if you selected Views in the previous step. Click Next.
The Filter Table Rows dialog box will open. There is no need to filter the data in the publication. Click Next.
The Snapshot Agent dialog box will open. Check Create a snapshot immediately and keep the snapshot available to initialize subscriptions. Click Next.
In Snapshot Agent Security, provide valid service or administrator credentials for the Windows account. Click Next.
Check Create the publication. Click Next.
Enter the Publication name
WFGEN_PUB
.Click Finish. If all is successful, close the New Publication Wizard.
To set up a subscription on the read-only database:
Open SQL Server Management Studio.
Connect to the read-only database instance.
Open the Replication node.
Right-click on Local Subscriptions and choose New Subscription. The New Subscription Wizard will open. Click Next.
Select
<Find SQL Server Publisher...>
.Connect to the primary database instance.
Select
WFGEN_PUB
in the Databases and publications list. Click Next.Select Run each agent at its Subscriber (pull subscriptions). Click Next.
In the Subscription Database column, select
<New database...>
.Enter the
WFGEN
as the Database name and click OK. Click Next.In Distribution Agent Security, provide valid service or administrator credentials for the Windows account. Click Next.
In Synchronization Schedule, select Run continuously. Click Next.
In Initialize Subscriptions, select Immediately. Click Next.
Select Create the subscription(s). Click Next.
Click Finish. If all is successful, close the New Subscription Wizard.
Create and add the SQL user
WFGEN_USER
to theWFGEN
read-only database security withdb_datareader
anddb_datawriter
permissions.
The WFGEN_USER
account will be used in the connection string for the WFGEN
read-only database in WorkflowGen.
Database scaling in WorkflowGen
Enable the multi-database mode in WorkflowGen:
In the WorkflowGen Administration Module, open the Configuration Panel and select the General tab.
In the Read-only database connection string field, enter the WorkflowGen connection string of the read-only database instance.
Check Enable on Multi-database to turn on the database scaling feature.
Check each of the specific Portal pages and Modules:
If unchecked, it will use the primary database.
If checked, it will use the read-only replica database.
Save and close.
References
For more information on SQL Server replication, see http://msdn.microsoft.com/en-us/library/ms151198.aspx and select your version of SQL Server from the drop-down menu.
For more information on the SQL Server
max text repl size
option, see http://msdn.microsoft.com/en-us/library/ms186225.aspx and select your version of SQL Server from the drop-down menu.
Custom language support and layout
Overview
You can customize WorkflowGen according to your language and, if applicable, the required language layout.
Customizing the resource files
To customize the resource files for your language, first make copies of the .resx
files in the following folders:
\wfgen\App_GlobalResources
\wfgen\WfApps\WebForms\App_GlobalResources
\wfgen\ws\App_GlobalResources
Append the file name with the language code and, if needed, a hyphen followed by the country code; for example, .ar-AE
for Arabic and United Arab Emirates. Then, customize the resource files as needed.
Customizing the CSS files
If the custom language requires a different layout, such as right-to-left text, customize the CSS files as needed using the method in the previous section.
Last updated