to a PDF version of this guide.

Transcription

to a PDF version of this guide.
WorkflowGen 5.7.4
Technical Reference Guide
Updated September 6, 2016
Copyright © Advantys 2016
www.workflowgen.com
Table of Contents
Overview
5
System requirements
6
End-users
Web server
Database server
Authentication methods and directory synchronization
Alerts and XML syndication
SharePoint Server lists integration with built-in form designer
Product technical components
Overview
Web applications
WorkflowGen main ASP.NET 2.0 application
ASP.NET workflow applications (wfgen/wfapps)
Windows services
WorkflowGen engine service
WorkflowGen directory synchronization service
WorkflowGen data
File data
Log files
Templates
SQL database
Setup
Preparation
General
Requirements for installation on Oracle 9i / 10g / 11g databases
WorkflowGen setup (InstallShield Wizard installation)
Welcome screen
WorkflowGen files and folders architecture
Disk space requirements
Web application folder specification
WorkflowGen services folder specification
Database configuration
WorkflowGen administrator account setup
WorkflowGen general configuration
Ready to install
Setup completed
WorkflowGen setup (manual installation)
Installation pack
WorkflowGen files and folders architecture
Database creation
WorkflowGen Administrator account setup
WorkflowGen web configuration
WorkflowGen Windows Services installation
Server-side COM components
Overview
6
7
8
8
9
9
10
10
11
11
11
12
12
12
13
13
13
13
13
14
14
14
14
16
17
17
18
19
21
22
25
27
27
28
29
29
29
29
31
32
32
33
33
Installation
Application files access configuration
File permissions
Server-side COM components
Configuring IIS
Creating a MIME type (required for PDF forms only)
Creating the application pool
Creating the website (if WorkflowGen is set up on a new website)
Configuring the website
Creating the WorkflowGen application
Creating workflow applications and services
IIS file size restrictions
Additional configuration for Windows in 64-bit
When configuring WorkflowGen on IIS in 32-bit compatibility mode
When configuring WorkflowGen on IIS in 64-bit native mode
Creating the WorkflowGen COM+ applications
WorkflowGen Windows services
WorkflowGen engine service
WorkflowGen directory synchronization service
Tests
Web app addresses
Test sample processes
Additional configurations
License activation
Overview
How to activate WorkflowGen
License per user
Security
Overview
Which authentication mode to choose?
Authentication methods
Integrated Windows authentication
IIS HTTP basic authentication
WorkflowGen HTTP basic authentication
Custom HTTP basic authentication
Form authentication
HTTPS: Using SSL with WorkflowGen
Overview
IIS configuration
Application parameters to update
Links to WorkflowGen
Advanced configuration
File storage
Overview
Basic configuration
Web Farm architecture
Overview
Implementation method
Online database backup
33
34
34
34
34
34
34
35
35
36
37
38
38
38
39
39
40
40
41
41
41
41
42
42
42
42
44
45
45
45
46
46
46
47
48
49
50
50
50
50
50
51
51
51
51
53
53
54
55
Overview
Setup and configuration (not required if running version 5.1 or greater)
Usage
Additional information
Configuring multiple instances of WorkflowGen
Overview
Setup and configuration
Database scaling
Overview
Requirements
Setup and configuration
Database scaling in WorkflowGen
References
Operations
Backup
Overview
Full (data + applications)
Data only
Moving the WorkflowGen database
SQL Server database
Oracle database
Moving the WorkflowGen application
Monitoring
Storage space
Directory synchronization
Windows service
Usage
55
55
55
56
56
56
56
60
60
61
62
85
86
87
87
87
87
87
87
87
88
88
88
88
89
89
89
Using IIS SMTP gateway
90
Synchronizing a directory in command line
91
Sample code for an HTTP module
92
Overview
Source code
92
92
5
WorkflowGen 5.7.4 Technical Reference Guide
Overview
This guide covers all of the procedures involved in the installation and maintenance of WorkflowGen. It is
aimed at system administrators who will be required to install or carry out maintenance of the application.
6
WorkflowGen 5.7.4 Technical Reference Guide
System requirements
End-users
The WorkflowGen Portal is a fully web-based application. No ActiveX components are required.
Operating systems
l
Windows XP
l
Windows Vista
l
Windows 7
l
Windows 8 / 8.1
l
Mac OS X
Web browsers
l
Internet Explorer 8 or higher *
l
Firefox
l
Safari
l
Chrome
Plug-in
l
Flash plug-in version 8 or higher (only required to display process graphical follow-up)
Display
l
Super VGA (1024 × 768) or higher-resolution video adapter and monitor
l
For form designers, the suggested minimum resolution is 1366 × 768
* As of WorkflowGen version 5.7.0, the WorkflowGen website must have the following configuration to display in Internet Explorer 8 or
higher: Security zone set to Local intranet or Trusted zone, and either excluded or removed from the Compatibility View Setting
list, because WorkflowGen must run in the latest Internet Explorer document mode (Edge). See
http://support.microsoft.com/kb/174360 and http://support.microsoft.com/kb/2536204 for more information.
7
WorkflowGen 5.7.4 Technical Reference Guide
Web server
The system requirements for the web server hosting WorkflowGen are as follows:
Operating systems
l
Windows Server 2012 or 2012 R2 1, 2, 4
l
Windows Server 2008 or 2008 R2 1, 2, 4
l
Windows Server 2003 or 2003 R2 1, 2
l
Windows 7 1, 2, 3, 4
l
Windows 8 / 8.1 1, 2, 3, 4
Note: If you are installing WorkflowGen on a 64-bit operating system, make sure WOW64 is installed on the
Windows machine.
Web server
l
Microsoft IIS 6.0 or higher
l
.NET Framework 2.0 or higher
Minimum hardware configuration for test systems
l
Processor: 1 GHz
l
RAM: 512 MB
l
Hard disk: 20 GB
Please refer to the WorkflowGen Scalability Guide on the Community Site for up-to-date server specifications
based on your planned usage of the system, at the following URL:
http://community.workflowgen.com/kb/workflowgen-server-configuration-and-scalability.html
1. Installations of WorkflowGen on a 64-bit server in Compatibility mode are only supported in versions 5.0.39 and later.
2. Installations of WorkflowGen on a 64-bit server in Native mode are only supported in versions 5.3.0 and later.
3. Windows 7, 8, and 8.1 should only be used as development environments.
4. Requires Microsoft Script Control 1.0 to be installed in order to function with WorkflowGen. The Microsoft Script Control 1.0 can be
downloaded at the following location: http://www.microsoft.com/downloads/details.aspx?FamilyId=D7E31492-2595-49E6-8C021426FEC693AC&displaylang=en.
8
WorkflowGen 5.7.4 Technical Reference Guide
Database server
The system requirements for the database server hosting the WorkflowGen database are as follows:
Hardware specifications
l
Processor: 1 GHz
l
RAM: 512 MB
l
Hard disk: 20 GB
Database servers supported
l
Microsoft SQL Server 2005 and Express Edition
l
Microsoft SQL Server 2008, R2 and Express Edition
l
Microsoft SQL Server 2012, R2 and Express Edition
l
Microsoft SQL Server 2014 and Express Edition
l
Oracle 9i
l
Oracle 10g
l
Oracle 11g and R2
Please refer to the WorkflowGen Scalability Guide on the Community Site for up-to-date server specifications
based on your planned usage of the system at the following URL:
http://community.workflowgen.com/kb/workflowgen-server-configuration-and-scalability.html
Authentication methods and directory
synchronization
Authentication methods
l
Integrated Windows or IIS Basic (Active Directory)
l
Applicative (WorkflowGen)
l
Forms
l
Custom (SSO: single sign-on)
Directory synchronization
l
Active Directory (supports all versions of Windows Server 2003, 2008, and 2012)
l
LDAP-compatible directory
l
Text files
9
WorkflowGen 5.7.4 Technical Reference Guide
Alerts and XML syndication
Email alerts
l
Email alerts are sent via SMTP protocols (Exchange and Lotus Notes are compatible).
l
Any email client can receive WorkflowGen alerts.
l
Email layout and content can be customized in HTML or plain text.
For best performance, the IIS SMTP gateway should be used (see Using IIS SMTP gateway on page 90).
XML syndication
WorkflowGen provides an XML RSS feed (called the "portlet") to embed existing Web Portal with
WorkflowGen data.
SharePoint Server lists integration with built-in form
designer
SharePoint Server lists data binding integration for the ListBox and DropDownListBox tools.
l
l
The SharePoint Server 2007/WSS 3.0 (version 12.0.0.0) or 2010 (version 14.0.0.0) must be installed on
the same WorkflowGen IIS server.
The SharePoint Server website and lists must be configured to allow access for WorkflowGen users.
The following authentication configurations have been tested and supported:
l
SharePoint Server website: Integrated Windows (NTLM)
l
WorkflowGen website: Integrated Windows (NTLM) or IIS HTTP
WorkflowGen’s web configuration file must declare a reference to the SharePoint API library.
Example:
<system.web>
<compilation debug="false">
<assemblies>
<add assembly="Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral,
PublicKeyToken=71e9bce111e9429c" />
</assemblies>
</compilation>
</system.web>
10
WorkflowGen 5.7.4 Technical Reference Guide
Product technical components
Overview
WorkflowGen is a Microsoft Active Server Pages .NET (ASP.NET 2.0) application. It includes:
l
.aspx files
l
.css, .js, .gif and .jpg files
l
.NET assemblies (.dll files)
l
A relational database (MS SQL Server or Oracle)
l
Some server-side COM files (.dll files)
A Windows service is used for directory synchronization, overdue actions management, etc.
The WorkflowGen application is hosted on a new or an existing IIS website and is separated into two distinct
modules:
l
A module for end-users: the Portal
l
A module for administrators and process managers
The process actions can be handled by some underneath web applications such as eFormASPX (which aims
at displaying .NET Web Forms) and storing the filled-out data once the forms are submitted. These
applications can be built-in or can be developed according to the SDK requirements and specifications.
The WorkflowGen database contains:
l
User management (which can be synchronized with an existing directory)
l
Process definitions and executions
l
l
Information on the follow-up of ongoing and completed requests, as well as significant associated data
(APPROVAL, AMOUNT, documents, etc.)
Statistics information about the closed and running requests
The processes can be imported from or exported to an XML file that contains the process definition based
upon the XPDL 1.0 standard format of the WfMC (Workflow Management Coalition).
All data files, including the web form projects with their XML data and other attachments are stored on the
server disk and auto-archived chronologically.
11
WorkflowGen 5.7.4 Technical Reference Guide
Web applications
WorkflowGen main ASP.NET 2.0 application
This application contains the core application. The user module and administration are both in that main
application:
l
\wfgen: User module.
l
\wfgen\admin: Administration module.
l
\wfgen\bin: Contains all the core assembly files that are needed to run WorkflowGen.
l
l
l
l
l
l
\wfgen\App_GlobalResources: Contains the resx files that are needed for globalization. If you want to
add a new language support to WorkflowGen, you have to create the new resx files in this folder.
\wfgen\js: Used to store the different JavaScript files that are needed to run WorkflowGen.
\wfgen\wfapps: Contains all the SDKs, Web Forms, and Web services used by your WorkflowGen
processes.
\wfgen\swf: Contains the Flash files that are used for the graphical follow-up and for process designing in
the administrative module.
\wfgen\ws: Contains the WorkflowGen Web service API.
\wfgen\App_Themes: Contains the styles of the user and the administration modules. The styles are
completely customizable for both modules. Each module has a corresponding CSS file. To create your
own skins, please refer to the WorkflowGen Developer documentation. To change the currently selected
skin, please refer to the Administration module documentation.
ASP.NET workflow applications (wfgen/wfapps)
Workflow web applications
The \wfgen\wfapps\webapps folder contains the following workflow applications:
l
eFormASPX: application used to launch web forms in a process workflow.
l
eFormPDF: application used to launch PDF forms in a process workflow.
l
DocUpload: application used to upload a document to the workflow.
l
DocApproval: application used to approve or disapprove a document in a process workflow.
This folder can also be used to store your own SDK procedures. Please refer to the Developer documentation
for more information about SDK.
Workflow Web services
The \wfgen\wfapps\webservices folder contains the following workflow Web services:
12
WorkflowGen 5.7.4 Technical Reference Guide
l
l
l
l
l
GetUsersFromDir: Web service used to get a list of usernames of WorkflowGen based on user criteria.
XmlToDatabase: Web service used to export a FORM_DATA document generated by eFormASPX to a
database of your choice.
PdfToDatabase: Web service used to export a FDF document generated by eFormPDF into an external
database.
XmlTrans: Web service used to apply an XSL transformation to any xml file.
FdfToXml: Web service used to convert an FDF document generated by eFormPDF to an XML file that
eFormASPX could then use.
This folder can also be used to store your own SDK web services. Please refer to the Developer
documentation for more information about SDK.
Workflow web forms
The \wfgen/wfapps/webforms folder is used to store the web forms used in the process workflows.
Windows services
WorkflowGen engine service
The following automatic task executions are provided by this Windows service:
l
Action overdue exceptions
l
Notification management
l
Deletion of inactive delegations
l
Deletion of ghost activities (a list of activities initialized but never started)
This service is installed by the setup pack and is started automatically after installation.
The default suggested installation path is:
"C:\Program Files\Advantys\WorkflowGen\Services\bin\WfgWorkflowEngineService.exe".
WorkflowGen directory synchronization service
The automatic users and groups synchronization is provided by this Windows service. This service is
installed by the setup pack and started automatically after installation.
The default suggested installation path is:
"C:\Program Files\Advantys\WorkflowGen\Services\bin\WfgDirectoriesSyncService.exe".
The synchronization service can also be executed from a command line (see Synchronizing a directory in
command line on page 91 for more information).
13
WorkflowGen 5.7.4 Technical Reference Guide
WorkflowGen data
File data
The \wfgen\App_Data\files\runtime folder contains the data that are related to each process instance. The
data that are generated by the workflows are stored in this folder. If the Process data storage option is
selected to store file content in the database, then data of type ‘file’ are stored directly in the database and not
in the directory structure.
The \wfgen\App_Data\files\design folder contains the data that are uploaded directly in the process
definition, and when the processes are instantiated, those data are copied to the runtime folder. If the Process
data storage option is selected to store file content in the database then data of type ‘file’ are stored directly in
the database and not in the directory structure.
The \wfgen\App_Data\files\charts\images folder contains the temporary files of the graphical charts.
Log files
The \wfgen\App_Data\LogFiles folder contains the logs created by WorkflowGen (Directory
synchronization, WorkflowGen authentication module).
Templates
The \wfgen\App_Data\Templates folder contains the templates used by WorkflowGen (notifications, charts,
portlet, form designer styles and tools, processes).
SQL database
The WorkflowGen database contains:
l
User management
l
Process definitions
l
Follow-up information about ongoing and closed processes, as well as significant workflow-related data
(approvals, amounts, documents, etc.)
14
WorkflowGen 5.7.4 Technical Reference Guide
Setup
Preparation
General
You must be administrator of the web server. Using a local administrator account is recommended. You must
know:
l
The physical path on the web server where WorkflowGen web application will be installed
l
The physical path on the web server where WorkflowGen Windows services will be installed
l
The URL of the web server where WorkflowGen will be installed
l
MS SQL server database:
l
l
the name of the MS SQL server
l
the credentials of the SA account
l
the file path of the SQL server database files on the SQL server machine
Oracle database:
l
l
l
an existing Oracle data source name
the credentials of the database user account that has creation permission on the specified Oracle
instance (see below for Oracle database installation parameters)
The name or IP address of the SMTP gateway (we recommend using the IIS SMTP gateway; see Using
IIS SMTP gateway on page 90).
l
The default sender email address for notifications
l
The authentication method you want to use for WorkflowGen web applications
Requirements for installation on Oracle 9i / 10g / 11g databases
WorkflowGen and Oracle 9i on the same server
l
National and Database character sets are both UTF8
l
Oracle Database 9i Release 2 (9.2.0.3) Standard with Client software installed
l
.NET Framework 2.0, 3.0, 3.5 SP1
WorkflowGen and Oracle 9i on separate servers
l
National and Database character sets are both UTF8
l
Oracle Server: Oracle Database 9i Release 2 (9.2.0.3) Standard
15
WorkflowGen 5.7.4 Technical Reference Guide
l
WorkflowGen Server: Oracle Database 9i Release 2 Client for Microsoft Windows 98/2000/NT/XP
l
.NET Framework 2.0, 3.0, 3.5 SP1
WorkflowGen and Oracle 10g on the same server
l
National and Database character sets are both UTF8
l
Oracle Database 10g Release 2 (10.2.0.3/10.2.0.4) Standard
l
.NET Framework 2.0, 3.0, 3.5 SP1
WorkflowGen and Oracle 10g on separate servers
l
National and Database character sets are both UTF8
l
Oracle Server: Oracle Database 10g Release 2 (10.2.0.3/10.2.0.4) Standard
l
WorkflowGen Server:
l
Oracle Database 10g Client Release 2 (10.2.0.3)
l
.NET Framework 2.0, 3.0, 3.5 SP1
WorkflowGen and Oracle 11g on the same server
l
National and Database character sets are both UTF8
l
Oracle Database 11g Release 1 (11.1.0.6.0) Enterprise with Client software installed
l
.NET Framework 2.0, 3.0, 3.5 SP1
WorkflowGen and Oracle 11g on separate servers
l
National and Database Character Set are both UTF8
l
Oracle Server: Oracle Database 11g Release 1 (11.1.0.6.0) Enterprise
l
WorkflowGen Server:
l
Oracle Database 11g Release 1 Client (11.1.0.6.0)
l
.NET Framework 2.0, 3.0, 3.5 SP1
Authentication method
Check that the SQLNET.AUTHENTICATION_SERVICES parameter of
"DISK:\OraHome\network\ADMIN\SQLNET.ORA" is set to NONE. This file is located on your web server.
Create a new tablespace (if WorkflowGen is set up on a blank tablespace)
1. In DBA studio or from SQL Plus, create a new tablespace called WFGEN with the following settings:
l
File size: 100 MB minimum
16
WorkflowGen 5.7.4 Technical Reference Guide
2. Once the tablespace is created, you should specify the Database and National character sets to UTF-8.
3. Create a user account with the following settings:
l
l
Temporary and default tablespace: WFGEN
Role: DBA or a more restrictive access. Initially, the user must have creation rights on the structure
schema (tables, index, constraints, etc.). However, once the structure is created, only read/write
rights are necessary.
Optimizer mode
To dramatically increase WorkflowGen database performance, check your database optimizer mode. If the
optimizer_mode is set to "CHOOSE" (by default in Oracle 9i and 10g), you have to frequently (weekly, for
example) "ANALYZE" all the tables of your databases. This operation will generate statistics used by the
optimizer to select the best mode ("RULE" instead of "all_rows") to run an SQL query. Another solution is to
set the optimizer_mode to "RULE".
WorkflowGen setup (InstallShield Wizard installation)
The following procedure applies to the setup using the WorkflowGen 5.7 InstallShield Wizard installation
pack. To start the installation wizard, double-click on the setup execution file and follow the instructions on the
screen. The installation can be cancelled at any time by clicking Cancel.
The InstallShield Wizard will perform the following actions:
l
Install the web application.
l
Install the Windows services.
l
Create the SQL Server database structure and contents and associated database user account if MS
SQL Server is chosen.
l
Create the Oracle database structure and contents if Oracle is chosen.
l
Create the Windows NT or Domain user account (default WorkflowGen administrator).
l
Create a log file in the directory where the WorkflowGen setup execution file is located. In case of any
problems, the error will be detailed in it. We recommend launching the setup program from your web
server.
Notes:
l
For the manual installation procedure, skip to WorkflowGen setup (manual installation) on page 29.
l
Version 5.7.0 dialog boxes displayed in this section are unchanged in version 5.7.4.
17
WorkflowGen 5.7.4 Technical Reference Guide
Welcome screen
Click Next to continue. The setup program will suggest that you stop IIS services as well as any anti-virus
software during the installation.
WorkflowGen files and folders architecture
The recommended physical directory structure for WorkflowGen web application files and folders should be
under \Inetpub\wwwroot\wfgen. This folder contains static resources such as images, HTML files and
process data, and the applications used by WorkflowGen.
18
WorkflowGen 5.7.4 Technical Reference Guide
Click Next to continue.
Disk space requirements
The application will ask you to define the local disk for the installation of WorkflowGen. A minimum of 71 MB
of disk space is required.
19
WorkflowGen 5.7.4 Technical Reference Guide
Verify the available disk space for the destination drive, then click Next to continue.
Web application folder specification
Define the physical path for the web application root folder. By default, the suggested physical path is
"DRIVE:\Inetpub\wwwroot\wfgen".
20
WorkflowGen 5.7.4 Technical Reference Guide
1. Specify the web application root files and folder path. Make sure to include the \wfgen sub-folder.
2. Click Change to choose another destination folder. A new window will open to let you choose another
destination folder.
3. Click Next to continue.
21
WorkflowGen 5.7.4 Technical Reference Guide
4. Specify the new destination folder path. Make sure to include the \wfgen sub-folder.
5. Click OK to confirm.
WorkflowGen services folder specification
Define the physical path for the WorkflowGen services folder. By default, the suggested physical path is
"DRIVE:\Program Files\Advantys\WorkflowGen".
22
WorkflowGen 5.7.4 Technical Reference Guide
1. Specify the Windows services files and folder path. Make sure to include the sub-folders
"Advantys\WorkflowGen".
2. Click Change to choose another destination folder. A new dialog window will open to let you choose
another destination folder.
3. Click Next to continue.
Database configuration
Important: If you choose to create a new database using an existing database name all data will be erased
and overwritten with an empty database. To prevent unintentional data loss, make sure to choose a unique
name for the database. As well, you should back up your existing database before proceeding with the
installation.
MS SQL Server requirements
l
l
You cannot use the InstallShield Wizard with SQL Server in Windows authentication mode only.
The SQL Server must support SQL authentication. Enable this security setting in your SQL Server
configuration if it isn’t already enabled.
MS SQL Server authentication
The application will ask for information about the parameters of the connection to the MS SQL Server
database.
23
WorkflowGen 5.7.4 Technical Reference Guide
Parameter
Definition
Create a new database instance
This option will create a new database structure and content
Install on a previously created
database instance
This option will only create the database content to an existing
empty database structure
SQL Server
Name of the MS SQL server
Login ID
DBMS Administrator login name
Password
DBMS Administrator password
Database name
Name of the database to be used or created
1. Choose to create a new database or install to a previously created database instance.
2. Specify the MS SQL server name or click Browse to choose from a list of MS SQL servers.
Important: If you use the same database name as an existing database, the installation will erase all
existing data.
3. The default name of the server is "machine name\instance name". Specify the SA login ID and
password, and the database instance name.
Important: In SQL server, it is important that passwords for database users match the server’s
password strategy, otherwise a 5110 error will occur.
4. Click Next to continue.
24
WorkflowGen 5.7.4 Technical Reference Guide
Note: The login WFGEN_USER (password: "Admin123!") will be automatically created with the roles
datareader and datawriter to the WorkflowGen database. This login will be used in the connection string to
access to the WorkflowGen database.
WorkflowGen Database Data and Log Files configuration
Important:
l
l
The path you enter for the data file and the log file must be the local path to the SQL Server, even if the
SQL Server is distant from the Web server on which the installation is executed.
The specified path must already exist, otherwise you will receive the error message "Error 5110: An error
occurred while connecting to database ‘WFGEN’ …"
Parameter
Definition
File name
Data and log file name
Path
Physical file path that the files are stored
Size
Initial file size (MB)
Max Size
Maximum file size (MB)
File Growth
File growth size (MB)
Important: The default physical path of SQL Server is "C:\Program Files\Microsoft SQL Server\MSSQL[X]
\MSSQL\Data".
25
WorkflowGen 5.7.4 Technical Reference Guide
Specify the data and log file parameters (filename, path, size, maximum size, and file growth), then click Next
to continue.
Oracle database configuration (for installation under Oracle only)
Note: An Oracle database instance will NOT be created during the installation. It is required to provide an
existing empty Oracle database instance prior to the installation of WorkflowGen. See Setup on page 14 for
Oracle database installation parameters.
Parameter
Definition
Data source
Name of the Oracle instance
User ID
Login of a user account that has creation permission on the specified
Oracle instance
Password
Password of the user account that has creation permission on the
specified Oracle instance
1. Specify the Oracle data source name.
2. Specify the administrator user ID and password.
3. Click Next to continue.
WorkflowGen administrator account setup
WorkflowGen requires a valid Windows NT or Active Directory account. This account will be used by the
WorkflowGen administrator, but it is not necessary to define it as an NT or Active Directory Administrator.
26
WorkflowGen 5.7.4 Technical Reference Guide
1. Specify a domain name if the WorkflowGen administrator user will be created as part of a domain;
otherwise, this user will be created on the local machine.
2. Specify the WorkflowGen administrator username and password.
3. Choose to create the NT account for this user or to skip the creation by using an existing account
(username and password are required).
4. Click Next to continue.
27
WorkflowGen 5.7.4 Technical Reference Guide
WorkflowGen general configuration
Parameter
Definition
Web site URL
The basic web site URL will be used to generate the full web site URL
for WorkflowGen
SMTP Server
The default SMTP Server will be used to send email notifications
Default Email Sender
The default email sender will be used to send automatic email
notifications
1. Specify the WorkflowGen website URL, the SMTP server, and the default email sender.
2. Click Next to continue.
Ready to install
You are now ready to begin the installation of WorkflowGen 5.7.2. If there are any changes to make before the
installation, you can always go back to previous screens.
28
WorkflowGen 5.7.4 Technical Reference Guide
Click Install to begin the installation.
Setup completed
29
WorkflowGen 5.7.4 Technical Reference Guide
Click Finish to exit the installation wizard.
The installation Wizard is now complete. The log file WorkflowGen-5-0-setup.txt containing all of the
installation steps has been generated in the folder where the installation pack is located.
To continue this InstallShield Wizard installation procedure, skip to Server-side COM components on page
33.
WorkflowGen setup (manual installation)
The following procedure applies to the setup using the WorkflowGen 5.7 manual installation pack. You can
obtain the manual installation pack by requesting it over your WorkflowGen software provider.
Note: For the InstallShield Wizard installation procedure, see the previous section, WorkflowGen setup
(InstallShield Wizard installation).
Installation pack
Start by extracting the manual installation pack (.zip) to a temporary folder on the WorkflowGen web server
(e.g. "DRIVE:\temp").
The installation pack contains:
l
\pack\Databases: contains the database creation scripts for both SQL Server and Oracle
l
\pack\Inetpub: contains the WorkflowGen application files
l
\pack\Program Files: contains the WorkflowGen Windows services application file
WorkflowGen files and folders architecture
The recommended physical directory structure for WorkflowGen web application files and folders should be
under "\Inetpub\wwwroot\wfgen". This folder contains static resources such as images, HTML files and
process data, and the applications used by WorkflowGen.
1. Copy the source Inetpub folder (DRIVE:\temp\pack\Inetpub) to your destination DRIVE:\ (e.g.
"DRIVE:\Inetpub\wwwroot\wfgen").
2. Copy the source Advantys folder (DRIVE:\temp\pack\Program Files\Advantys) to your destination
DRIVE:\Program Files (e.g. "DRIVE:\Program Files\Advantys\WorkflowGen\Services\bin").
Database creation
MS SQL Server (CreateWFGSQLDatabase.vbs)
1. Run the database creation script
"DRIVE:\temp\pack\Databases\MsSQLServer\CreateWFGSQLDatabase.vbs".
2. Choose Yes to confirm the database creation.
3. Choose No for SQL Server 2005/2008/2008 R2/2012.
30
WorkflowGen 5.7.4 Technical Reference Guide
4. Choose Yes for SQL Server 2005 or No for SQL Server 2008/2008 R2/2012.
5. Choose Yes for SQL Server 2008 or No for SQL Server 2008 R2/2012.
6. Choose Yes for SQL Server 2008 R2 or No for SQL Server 2012.
7. Enter the MS SQL Server instance name.
8. Enter a Catalog name (e.g. "WFGEN").
9. Enter an MS SQL Server administrator account name (e.g. "sa").
10. Enter the administrator password.
11. Enter a database data (mdf) and logging (ldf) destination folder (e.g. "DRIVE:\Program Files\Microsoft
SQL Server\MSSQL[X]\MSSQL\DATA").
12. Enter a maximum size for the data and log files (e.g. 1000). We suggest changing this later to
unrestricted growth for both data and logging files in MS SQL Server Management Studio tool.
13. Click OK to create the database.
Note: An SQL server user account WFGEN_USER with the password "Admin123!" will be created as part of
this script. This account will only have the db_datareader and db_datawriter permissions on the WorkflowGen
database, and can be used in the WorkflowGen web application database connection.
MS SQL Server (manual)
1. Open the MS SQL Server Management Studio tool.
2. Connect to your MS SQL Server instance with an administrator account.
3. Under Databases, choose New Database…
4. Enter a database name (e.g. "WFGEN").
5. Specify unrestricted growth for both data and logging files.
6. Click OK to create the database.
7. Under Security / Logins / New Login… enter a login name (e.g. "WFGEN_USER").
8. Choose Windows authentication or SQL server authentication.
9. If you choose SQL server authentication, enter a password for this account (e.g. "Admin123!").
10. In User mapping, select the new database "WFGEN".
11. Assign the permissions "db_datareader" and "db_datawriter" to this account.
12. Click OK to create the user.
13. Open the source folder "DRIVE:\temp\pack\Databases\MsSQLServer" and run the following database
creation SQL scripts on the new database instance in the following order:
31
WorkflowGen 5.7.4 Technical Reference Guide
i. Create_WFG-V5-0_SQL_Tables.sql
ii. Create_WFG-V5-0_SQL_PKeys.sql
iii. Create_WFG-V5-0_SQL_FKeys.sql
iv. Create_WFG-V5-0_SQL_Indexes.sql
v. Create_WFG-V5-0_SQL_Triggers.sql
vi. Create_WFG-V5-0_SQL_Const.sql
Oracle (CreateWFGOracleDatabase.vbs)
Note: An Oracle database instance will NOT be created with this script. It is required to provide an existing
empty Oracle database instance prior to the installation of WorkflowGen.
1. Run the database creation script
"DRIVE:\temp\pack\Databases\Oracle\CreateWFGOracleDatabase.vbs".
2. Click Yes to confirm the database creation.
3. Enter the Oracle database instance name created in Setup on page 14 (e.g. "WFGEN").
4. Enter the administrator account name created in Setup on page 14 (e.g. "WFGEN_USER").
5. Enter the administrator password.
6. Click OK to create the database.
Oracle (manual)
Note: An Oracle database instance will NOT be created with this script. It is necessary to provide an existing
empty Oracle database instance prior to the installation of WorkflowGen. See Setup on page 14 for Oracle
database installation parameters.
1. Open DBA studio, SQL Plus, or SQL Developer.
2. Connect to your Oracle database instance with the administrator account created in Server-side COM
components on page 33.
3. Open the source folder DRIVE:\temp\pack\Databases\Oracle and run the following database creation
SQL scripts on the new database instance in the following order:
i. Create_WFG-V5-0_Oracle_Crebas.sql
ii. Create_WFG-V5-0_Oracle_Const.sql
WorkflowGen Administrator account setup
WorkflowGen requires a valid Windows NT or Active Directory account. This account will be used by the
WorkflowGen administrator, but it is not necessary to define it as a NT or Active Directory administrator.
l
You can use an existing user account or create a new user account with the name "Domain\wfgen_
admin".
32
WorkflowGen 5.7.4 Technical Reference Guide
l
If you use a different account name other than "wfgen_admin", then you MUST change the
"WorkflowGen Administrator" username in the WorkflowGen database. To do this, in the Users table,
find the record with the column "USERNAME" value "wfgen_admin", then change it to your custom user
account name.
WorkflowGen web configuration
1. Open and edit the WorkflowGen web configuration file "DRIVE:\Inetpub\wwwroot\wfgen\web.config".
2. Update the database connection string:
l
l
MS SQL Server: <add name="MainDbSource" connectionString="Data Source=localhost;Initial
Catalog=WFGEN;User ID=WFGEN_USER;Password=Admin123!;"
providerName="System.Data.SqlClient" />
Oracle: <add name="MainDbSource" connectionString="Data Source=WFGEN;User
ID=WFGEN_USER;Password=Admin123!;" providerName="System.Data.OracleClient" />
3. Update the "WorkflowGen Administrator" username to allow access to the configuration panel (e.g. <add
key="ApplicationConfigAllowedUsersLogin" value="wfgen_admin" />).
4. Set an SMTP server or SMTP gateway name (e.g. <add key="ApplicationSmtpServer"
value="smtpservername" />).
5. Update the application URL (e.g. <add key="ApplicationUrl" value="http://yoursite/wfgen" />).
6. Set a default email sender for the notification (e.g. <add key="EngineNotificationDefaultSender"
value="workflowgen@company.com" />).
WorkflowGen Windows Services installation
1. Open and edit the Engine service configuration file "DRIVE:\Program
Files\Advantys\WorkflowGen\Services\bin\WfgWorkflowEngineService.exe.config".
2. Update the WorkflowGen web configuration path (e.g. <add key="WebConfigPath"
value="DRIVE:\inetpub\wwwroot\wfgen\web.config" />).
3. Open and edit the Directory Synchronization service configuration file "DRIVE:\Program
Files\Advantys\WorkflowGen\Services\bin\WfgDirectoriesSyncService.exe.config".
4. Update the WorkflowGen’s web configuration path (e.g. <add key="WebConfigPath"
value="DRIVE:\inetpub\wwwroot\wfgen\web.config" />).
Note: "WfgWorkflowEngineService.exe " and "WfgDirectoriesSyncService.exe" might be blocked. To
check this, right-click on them and choose Properties. If the Security section is displayed at the bottom
of the General tab, these executables have been blocked; in this case, click Unblock.
5. Run "DRIVE:\Program Files\Advantys\WorkflowGen\Services\bin\winsvc-install.cmd" as
administrator.
33
WorkflowGen 5.7.4 Technical Reference Guide
Server-side COM components
Overview
These server-side ActiveX components are used in WorkflowGen’s core application and the eFormPDF
workflow application to manage PDF forms.
Component
Function
Version
Copyright
Windows Script
Control
The Microsoft® Windows® Script Control is an
ActiveX® control that provides developers with an
easy way to make their applications scriptable.
1.0.9200.16384
Microsoft
Corporation
FDFACX
FdfAcX.dll is a Win32 in-process ActiveX server
component. This dll must be registered on the Web
server. This ActiveX is registered by the setup with
the regsvr32.exe program.
6.0.0.0
Adobe Systems
Incorporated
FDFTK
This toolkit is used for creating and/or parsing FDF
files. This dll does not need to be registered. It only
needs to be copied and then it can be referenced
and used freely.
6.0.0.0
Adobe Systems
Incorporated
Installation
Windows Script Control
This component is required for Windows Vista and later versions of Windows. Download this from
https://app.box.com/s/u1cciagwrhas75utwmjrr3jmcoqoen24, then run the "sct10en.exe" file to install the
component.
FDFACX and FDFTK
Note: These are required for the manual installation procedure only because the InstallShield Wizard already
handles the FDFACX and FDFTK installation.
Download these from https://app.box.com/s/u1cciagwrhas75utwmjrr3jmcoqoen24.
l
l
For 32-bit Windows:
l
Copy both the FDFACX.DLL and FDFTK.DLL files to "C:\Windows\System32".
l
Run regsvr32 "C:\Windows\System32\FDFACX.DLL" to register the DLL.
For 64-bit Windows:
l
Copy both the FDFACX.DLL and FDFTK.DLL files to "C:\Windows\SysWOW64".
l
Run "regsvr32 C:\Windows\SysWOW64\FDFACX.DLL" to register the DLL.
34
WorkflowGen 5.7.4 Technical Reference Guide
Application files access configuration
File permissions
File permission settings can be configured as follows for the WorkflowGen application identity:
l
Folder: \Inetpub\wwwroot\wfgen: Modify all.
According to your authentication method (see Security on page 45), the WorkflowGen application identity can
be:
l
The corresponding Windows users
l
The ASP.NET or IIS application pool identity
Server-side COM components
You only need to verify that the WorkflowGen application Identity has read/execute rights for the
"Windows\System32" (32-bit) or "Windows\SysWOW64" (64-bit) folder.
Configuring IIS
Creating a MIME type (required for PDF forms only)
You should create the following MIME type: ".fdf <=> application/vnd.fdf".
1. Launch the Internet services manager to display the properties of the server on which the application is
installed.
2. Select the Internet Services (IIS) tab and click Modify under Computer MIME map. Click New type
and save the new type with the following parameters:
l
Associated extension: "fdf"
l
Content type (MIME): "application/vnd.fdf"
Creating the application pool
It is recommended that WorkflowGen be isolated from other applications by creating its own application pool
and associating all declared applications with the new application pool.
IIS 6
1. In IIS Manager, double-click the local computer, right-click Application pools and select New /
Application pool.
2. In the Application pool ID box, enter the name of the new application pool.
3. Under Application pool settings, click either Use default settings for new application pool or Use
existing application pool as template.
35
WorkflowGen 5.7.4 Technical Reference Guide
4. If you selected Use existing application pool as template, click the application pool to be used as a
template.
5. Click OK.
IIS 7 / 7.5 / 8.0
1. Click Application pools. In the right-hand pane, right-click and select Add application pool, and give
it a name (e.g. WorkflowGen).
2. Select the .NET 2 framework version.
3. Select Integrated pipeline mode.
4. Click OK.
Creating the website (if WorkflowGen is set up on a new website)
IIS 6
1. Launch the Internet IIS Manager and expand the tree structure under Internet Information Server.
2. Right-click the icon of the server on which you want to create the site and select New / Web site. Enter
the name of the site and click Next. Select the site’s IP address and port 80 and click Next.
3. Click Browse and select the wwwroot folder ("DISK:\inetpub\YOURSITE\wwwroot") for the site, then
click Next and uncheck the Anonymous access option. Uncheck all the authorization options and click
Finish to confirm the creation of the site.
IIS 7 / 7.5 / 8.0
1. Launch the IIS Manager and expand the tree structure under the IIS server name where you want to
create the new site.
2. Right-click the Web Sites icon and select Add Web Site. Enter the name of the site, select its
application pool (if other than the default), and enter the physical path of the root directory (click Browse
and select the wwwroot folder, usually "DISK:\inetpub\YOURSITE\wwwroot").
3. Select the binding as being http or https (https requires an SSL certificate). Select a port (the default is
80) and/or a host header. Please contact your IIS administrator to review your options regarding setting
up appropriate web site settings.
Configuring the website
IIS 6
Default document
The default document type "default.aspx" must be created if it does not exist. By default, this default
document should exist on an IIS server running .NET.
36
WorkflowGen 5.7.4 Technical Reference Guide
To verify this, right-click the icon of the site and select the Properties menu. If it is missing, select the
Documents tab, click Add, then enter the value "default.aspx" in the dialog box text zone. To improve
performance you may move "default.aspx" to the top of the list if it is not already there.
Authentication
Select the Folder security tab and click Modify in the Anonymous connections & authentication zone.
Uncheck the Authorize anonymous connections and Integrated Windows authentication boxes. Check
the Basic authentication box. You will be able to change the authentication method by following the
instructions in Security on page 45.
IIS 7 / 7.5 / 8.0
Default document
The default document type "default.aspx" must be created if it does not exist. By default, this default
document should exist on an IIS server running .NET.
To verify this, click the icon of the site, and ensure that the pane on the right-hand side shows the Features
view (the tab at the bottom of the pane allows you to switch between Features and Content). Double-click
the Default document icon. If "default.aspx" is missing from the list, add it to the beginning of the commaseparated list displayed. To improve performance you can move "default.aspx" to the beginning of the list if it
is not already there.
Authentication
1. Click the icon of the site, and ensure that the pane on the right hand side shows the Features view.
2. Double-click the Authentication icon.
3. Right-click on Anonymous authentication and select Disable.
4. Right-click on Basic authentication and select Enable. You will be able to change the authentication
method by following the instructions in Security on page 45.
Creating the WorkflowGen application
IIS 6
1. Right-click on wfgen under the "wwwroot" folder and select Properties.
2. Select the Directory security tab, click the Edit button, and select Basic authentication.
3. Select the Documents tab and add "default.aspx" if doesn’t already exist in the list.
4. Select the Directory tab and click Create to create the application.
5. Set Execute permissions to Scripts only.
6. Select the ASP.NET tab and choose ASP.NET version 2.0.50727 if it’s not already selected.
IIS 7 / 7.5 / 8.0
To create an application you must always select the parent of the application folder to declare. For example, if
you have a structure "site1\myfolder\wfgen" and you want to declare the wfgen application, you must
37
WorkflowGen 5.7.4 Technical Reference Guide
navigate to and click "myfolder", then follow the instructions below. Do not click on the application folder itself
(e.g. "wfgen") to declare it as in the method traditionally used in IIS 5 or 6.
For WorkflowGen, the "wfgen" folder should be seen directly below the root of the site if the site was correctly
created.
1. Right-click on the website icon and select Add application.
2. Enter "wfgen" as the application name.
3. Browse to the physical path of the wfgen folder under the root "DISK:\inetpub\YOURSITE\wfgen".
4. Select the WorkflowGen application pool if it is not the default.
Creating workflow applications and services
Each web application within WorkflowGen must be created. The following list shows all the web applications
that must be created using the procedures shown below.
Application name
Application path
ws
\wfgen\ws
webforms
\wfgen\WfApps/WebForms
eFormAspx
\wfgen\WfApps\WebApps\eFormAspx
eFormPdf
\wfgen\WfApps\WebApps\eFormPdf
DocApproval
\wfgen\WfApps\WebApps\DocApproval
DocUpload
\wfgen\WfApps\WebApps\DocApproval
FdfToXml
\wfgen\WfApps\WebServices\FdfToXml
GetUsersFromDir
\wfgen\WfApps\WebServices\GetUsersFromDir
PdfToDatabase
\wfgen\WfApps\WebServices\PdfToDatabase
XmlToDatabase
\wfgen\WfApps\WebServices\XmlToDatabase
XmlTrans
\wfgen\WfApps\WebServices\XmlTrans
IIS 6
For each application listed above:
1. Right-click on Application name (in the path as shown above) under the "/wfgen" folder and select the
Properties context menu.
2. Select the Directory tab and click Create to create the application.
3. Set Execute permissions to Scripts only.
4. Select the ASP.NET tab and choose ASP.NET version 2.0.50727 if it’s not already selected.
IIS 7 / 7.5 / 8.0
For each application listed above:
38
WorkflowGen 5.7.4 Technical Reference Guide
1. Navigate to the path one level up from the Application path shown under the "/wfgen" folder.
2. Right-click on the folder and select Add application.
3. Provide the Application name.
4. Browse to the associated Application path.
5. Select the WorkflowGen application pool if it is not the default.
IIS file size restrictions
IIS 6
Increase the allowable file upload size
By default, IIS 6 will restrict files from being uploaded if they are larger than 204800 bytes. To increase this,
you must edit the "metabase.xml" file.
1. On the web server, navigate to the "Windows\system32\inetsrv" folder.
2. Find and edit the AspMaxRequestEntityAllowed parameter in the Metabase.xml file to allow more than
204800 bytes.
3. For IIS 6 you will need to modify (in IIS) the Enable direct metabase edit property for the web server. To
do this:
i. In IIS, right-click on the server, and select Properties.
ii. Check the Enable direct metabase edit box.
iii. Edit the "metabase.xml" file.
iv. Uncheck the Enable direct metabase edit box in the IIS server properties.
Additional configuration for Windows in 64-bit
When configuring WorkflowGen on IIS in 32-bit compatibility mode
Requirements
l
l
l
IIS running in 32-bit compatibility mode using the .NET framework 2.0 (32-bit) in WOW64.
WebForms uses the latest WorkflowGen.My.dll (compatible with both 32-bit and 64-bit included in
"DRIVE:\Inetpub\wwwroot\wfgen\bin").
MS Script Control (msscript.ocx) and FDF ACX (FDFACX.DLL) must be installed and registered in
"C:\Windows\SysWOW64".
You must enable IIS to run 32-bit applications since WorkflowGen still interferes with 32-bit DLLs such as the
Adobe FDF Toolkit and MS Script Control.
For IIS 6, please see the Microsoft link below for instructions:
39
WorkflowGen 5.7.4 Technical Reference Guide
http://www.microsoft.com/technet/prodtechnol/WindowsServer2003/Library/IIS/55cd5e11-49a9-4158-8b1f7f2aa4ad2f07.mspx?mfr=true
For IIS 7 / 7.5 / 8, perform the following steps:
1. Open Internet Information Services (IIS) manager.
2. Select the appropriate application pool.
3. Right-click on the application pool and select Advanced settings.
4. Locate the property Enable 32-bit applications and set the value to True.
5. Install the .NET Framework 2.0 32-bit if not already installed. If it is already installed, you must register
IIS to use the .NET Framework 2.0 32-bit by running the following command:
"C:\Windows\Microsoft.NET\Framework\v2.0.50727\aspnet_regiis.exe -i" (reference:
http://msdn.microsoft.com/en-us/library/k6h9cz8h(VS.80).aspx).
6. Restart the Windows machine.
When configuring WorkflowGen on IIS in 64-bit native mode
Requirements
l
l
l
l
IIS running in 64-bit using the .NET framework64 2.0.
WebForms MUST use the latest WorkflowGen.My.dll (compatible with both 32-bit and 64-bit included in
"DRIVE:\Inetpub\wwwroot\wfgen\bin").
MS Script Control ("msscript.ocx") and FDF ACX ("FDFACX.DLL") must be installed and registered in
"C:\Windows\SysWOW64".
New WorkflowGen COM+ applications MUST be created for both MS Script Control and FDFACX.
Creating the WorkflowGen COM+ applications
1. In your Windows machine, open the Component Services Console.
2. Navigate to Console Root / Component Services / Computers / My Computer / COM+
Applications.
3. Right-click on COM+ Applications then choose New / Application.
4. Click Next in the Wizard.
5. Choose Create an empty application.
6. Enter "WorkflowGen" as the new application name.
7. Select Server application for the activation type, then click Next.
8. For Application identity, use the built-in Network service account or provide a specific user account,
then click Next.
9. Leave the Application roles with the default setting, then click Next.
40
WorkflowGen 5.7.4 Technical Reference Guide
10. Leave the User roles with the default setting.
11. Click Next then Finish. This will create the COM+ Applications "WorkflowGen".
12. Right-click on WorkflowGen COM+ applications.
13. Select Properties, then select the Security tab.
14. Uncheck the Enforce access check for this application option, then click OK.
Adding the MS Script Control component into WorkflowGen COM+ Applications
1. Browse to WorkflowGen / Components.
2. Right-click on Components then choose New / Component.
3. Click Next in the Wizard.
4. Choose Install new component(s).
5. Browse to and select "C:\Windows\SysWOW64\msscript.ocx".
6. Click Next then Finish.
This will create the component "MSScriptControl.ScriptControl.1".
Adding the FDFACX component into WorkflowGen COM+ applications
1. Browse to WorkflowGen / Components.
2. Right-click on Components and choose New / Component, then click Next in the Wizard.
3. Select Install new component(s).
4. Browse to and select "C:\Windows\SysWOW64\FDFACX.DLL".
5. Click Next then Finish.
This will create the component "FdfApp.FdfApp.1".
Note: For existing clients wishing to migrate to this new 64-bit native mode, you have to apply the latest
WorkflowGen update, change the configuration according to the requirements above, and then manually
create the WorkflowGen COM+ Applications.
WorkflowGen Windows services
WorkflowGen engine service
Automatic task execution (e.g. overdue exceptions and notifications management) is provided by this
Windows service. This service is installed by the setup InstallShield Wizard and is started automatically after
installation. (Refer to WorkflowGen Windows services on page 40 if the manual installation procedure is
used.)
41
WorkflowGen 5.7.4 Technical Reference Guide
If errors occurred while the service is running, those errors will be shown in the Event Viewer accessible in the
Windows Administrative tools. A section called "Engine Service" is created in the Event Viewer. All
messages relative to this service will be displayed in this section.
To manage this Windows service execution, open Administrative Tools / Services, then select and open
WorkflowGen Engine.
WorkflowGen directory synchronization service
The automatic users and groups synchronization is provided by this Windows service, which is installed by
the setup InstallShield Wizard and is started automatically after installation. (Refer to WorkflowGen
Windows services on page 40 if the manual installation procedure is used.)
If errors occurred while the service is running, those errors will appear in the Event Viewer accessible in the
Windows Administrative Tools. All the messages related to this service will be displayed in the Application
section.
To manage this Windows service execution, open Administrative Tools / Services, then choose and open
WorkflowGen Directory Sync.
Tests
Web app addresses
Check the following URLs with "wfgen_admin" user account:
l
User module: http://YOURSITE/wfgen
l
Administration module: http://YOURSITE/wfgen/admin
If you are unable to login as expected, verify the web.config file in the root folder of the WorkflowGen
application (usually "inetpub\wwwroot\wfgen") and validate that the connection string (shown as
"MainDbSource") contains the correct database connection information including server, database name,
user, and password.
Test sample processes
You can create a new process based on the list of built-in process samples or you can download and install
some sample processes from the WorkflowGen community website:
1. Log on to http://community.workflowgen.com/.
2. Register a username and password to access the Downloads section.
3. Browse to the Download process templates section.
4. Select a process template to download and follow the instructions in the setup document to import the
different samples.
42
WorkflowGen 5.7.4 Technical Reference Guide
Additional configurations
You can change the security configuration (such as the authentication method) by following the instructions in
Security on page 45.
Notes:
l
l
l
l
Not all of the required configuration parameters of WorkflowGen are defined in this setup. It is
recommended to update all other parameters in the Configuration panel of the WorkflowGen
Administration module after this setup. For more information, please refer to the WorkflowGen 5.7.2
Administration module documentation.
You can configure the time zone and language of new users through the Configuration panel of the
Administration module. You can also access the Configuration panel directly through the URL
"http://YOURSITE/wfgen/admin/Config.aspx" once the setup is complete and the website is running.
The New User Time Zone settings can be changed in the General tab of the Configuration Panel.
The New User Default Language can be changed in the Administration tab of the Configuration
panel.
License activation
Overview
Activation is required within 30 days from the first day that you start WorkflowGen. If you want to activate
WorkflowGen on a day later than the day that you install it, a message appears in the homepage of the portal.
This message reminds you how much time remains before you must activate. After the 30 days have expired,
you must activate to continue using WorkflowGen.
You must have a serial number to activate WorkflowGen. If you do not have one, please contact
your reseller.
How to activate WorkflowGen
Install the license file
You should have received your license file (.lic) after contacting your reseller.
1. Remove all current .lic files from the folder "/wfgen/bin".
2. Copy your .lic file into the folder "/wfgen/bin".
3. According to your security settings, you should have to reapply security of the "wfgen/bin" folder on the
.lic file.
Important: If you copy/paste the .lic file, be sure to set the same permissions as the "/wfgen/bin" folder.
43
WorkflowGen 5.7.4 Technical Reference Guide
Activating WorkflowGen by the WorkflowGen configuration panel
This method doesn’t require you to directly access the web server, but it can only be used if the trial period has
not yet expired and you have the rights to change the settings of WorkflowGen (refer to the Administration
Module documentation for more information).
1. Open the Administration module: http://YOURSITE/wfgen/admin.
2. Click the Configuration panel icon.
3. In the Product tab, enter your serial number.
Activating WorkflowGen by the web.config file
This method requires you to edit the web.config file located in the folder "\inetpub\wwwroot\wfgen". Use this
method when the trial period has expired or you are not authorized to access the Configuration panel.
1. Edit the file "\inetpub\wwwroot\wfgen\web.config".
2. Set your serial number as the value of the parameter "ApplicationSerialNumber".
Activating WorkflowGen after the trial period
Once the trial period has expired it is not possible to continue using WorkflowGen without entering a valid
serial number.
44
WorkflowGen 5.7.4 Technical Reference Guide
License per user
If you have a license per user, you cannot exceed the maximum of users supported by your license, otherwise
an error message will be displayed for all users. However, user management in the Administration module
will still be enabled.
If you want to import several users from your enterprise directory (Active Directory, LDAP, etc.), and since
only active users are considered, you can choose between the following cases:
l
l
If your enterprise directory has fewer users than the maximum number of users supported by your
WorkflowGen license, then you can import all of your users with the option New user default status set
to Active.
If your enterprise directory has more users than the maximum of users supported by your WorkflowGen
license, then you should import all your users with New user default status set to Inactive and set the
Self activation option as follows:
l
l
If you want to manually activate users authorized to use WorkflowGen, you have to uncheck the
Self activation option. No users will be able to access to WorkflowGen until you activate his or her
account from the administration module of WorkflowGen.
If you don’t want to worry about account activation, you can keep the Self activation option
checked. New users connecting for the first time will be activated until the maximum of users
supported by your WorkflowGen license is reached.
45
WorkflowGen 5.7.4 Technical Reference Guide
Security
Overview
This section details the different methods to authenticate WorkflowGen users, which are:
l
Integrated Windows authentication (ensured by IIS)
l
IIS HTTP Basic authentication (ensured by IIS)
l
WorkflowGen HTTP Basic authentication (ensured by HttpModule)
l
Custom HTTP Basic authentication (ensured by HttpModule)
l
Form authentication (ensured by .NET)
Choose one of these according to your needs, and apply the required settings to implement it with your
WorkflowGen instance.
Which authentication mode to choose?
If you don’t know which authentication mode to choose, follow the procedures below based on your situation:
1. If all WorkflowGen users are managed in Active Directories, which is accessible from the web server
hosting WorkflowGen, then you can choose one of these authentication modes:
l
Integrated Windows authentication (ensured by IIS)
l
IIS HTTP Basic authentication (ensured by IIS)
2. If item 1 above applies to your situation, and you want to provide transparent authentication by using the
current Windows session of the users, choose the following authentication mode:
l
Integrated Windows authentication (ensured by IIS)
3. If item 1 above does not apply to your situation, and all WorkflowGen users are managed in an external
application such a database or authenticated by a SSO solution choose one of these authentication
modes:
l
Custom HTTP Basic authentication (ensured by HttpModule)
l
Form authentication (ensured by .NET)
4. If neither item 1 nor item 3 applies to your situation because you do not have any directory or other
authentication solutions, you can choose only the following authentication mode:
l
WorkflowGen HTTP Basic authentication (ensured by HttpModule)
Note: For all HTTP Basic and Form authentication modes, it is strongly recommended to use SSL because
passwords are not encrypted.
46
WorkflowGen 5.7.4 Technical Reference Guide
Authentication methods
Integrated Windows authentication
IIS and WorkflowGen settings
1. Enable Integrated Windows authentication access on the WorkflowGen website and disable all builtin access mechanisms. Apply this setting on all sub-applications.
2. Open the WorkflowGen Configuration Panel. In the Authentication section, select IIS mode.
IIS HTTP basic authentication
IIS and WorkflowGen settings
1. Enable Basic authentication access on the WorkflowGen website and disable all built-in access
mechanisms. Apply this setting to all sub-applications.
2. Open the WorkflowGen Configuration panel. In the Authentication section, select IIS Mode.
47
WorkflowGen 5.7.4 Technical Reference Guide
WorkflowGen HTTP basic authentication
IIS and WorkflowGen settings
1. Enable Anonymous access on the WorkflowGen website and disable all built-in access mechanisms.
Apply this setting to all sub-applications.
2. Open the WorkflowGen Control Panel, under the Authentication section, select the Applicative mode,
the WorkflowGen method, and enter a valid NT account used to impersonate users.
48
WorkflowGen 5.7.4 Technical Reference Guide
3. "Advantys.My.dll" and "Advantys.Security.dll" must be copied to all "/Bin" directories of the various
applications under WorkflowGen, such as eformASPX, eFormPDF, and all your Webform and WebApps
folders. WebServices must continue to use Basic or Integrated Authentication.
4. The HttpModule nodes must be removed from all web.config files in the WorklfowGen WebServices
directory such as XmlToDatabase.
Custom HTTP basic authentication
IIS and WorkflowGen settings
1. Enable anonymous access on the WorkflowGen website and disable all built-in access mechanisms.
Apply this setting on all sub-applications.
2. Using the sample code in Sample code for an HTTP module on page 92, create a new class for the
HttpModule you are creating.
3. Modify the sample code to validate the credentials passed over HTTP Basic against the external
configuration repository.
4. Build your module and copy the DLL into the bin directory of WorkflowGen and all .NET applications
(chartsvc, eFormAspx, XmlToDatabase, etc.) under "/wfgen/".
5. Open the WorkflowGen Configuration panel and change the settings in the authentication section as
follows:
Alternately, you can register the HttpModule you created in the web.config of WorkflowGen.
49
WorkflowGen 5.7.4 Technical Reference Guide
The following are examples for a class named "MyCompany.Hosting.Samples.CustomAuthModule":
For II6 or IIS 7.x / IIS 8.0 using an application pool in classic Managed pipeline mode
<system.web>
<httpModules>
<add name="AuthModule" type="MyCompany.Hosting.Samples.CustomAuthModule/>\
</httpModules>
</system.web>
For IIS 7.x / IIS 8.0 using an application pool in Integrated Managed pipeline mode
<system.webServer>
<modules>
<add name="AuthModule" type="MyCompany.Hosting.Samples.CustomAuthModule"/>
</modules>
</system.webServer>
Form authentication
IIS and WorkflowGen settings
1. Enable anonymous access on the WorkflowGen website and disable all built-in access mechanisms.
Apply this setting on all sub-applications.
2. Modify the login.aspx code to validate the credentials passed over HTTP Basic against the external
configuration repository. If you don’t have any external configuration repository, you can add users
directly in the web.config of WorkflowGen (please refer to the .NET documentation).
3. The login.aspx file must be copied to all application directories under WorkflowGen such as eformAspx,
eFormPdf, and all your Webforms folders. This should only be applied to WebApps and WebForms.
WebServices must continue to use either Basic or Integrated authentication and therefore the login.aspx
page cannot be used for them.
4. In the WorkflowGen web.config, register the authentication form:
<configuration>
<system.web>
<authentication mode="Forms">
<forms name="401kApp" timeout="30" loginUrl="/wfgen/login.aspx"
cookieless="AutoDetect" defaultUrl="/wfgen/default.aspx" protection="None" />
</authentication>
<authorization>
<deny users="?"/>
</authorization>
</system.web>
</configuration>
Note: Set the attribute protection="None" or protection="All" to the "forms" node. If "All" is used, the
machineKey attribute and value must be added as well. (For more information about forms-based
authentication see http://quickstarts.asp.net/QuickStartv20/aspnet/doc/security/formsauth.aspx.)
50
WorkflowGen 5.7.4 Technical Reference Guide
5. Set the authentication to "Windows" for each WorkflowGen WebService application web.config file and
reset the security settings to Basic or Integrated in IIS for these folders.
HTTPS: Using SSL with WorkflowGen
Overview
This section describes how to configure WorkflowGen to use SSL connection security level on the website.
IIS configuration
Activate SSL authentication (see Configuring IIS on page 34).
Application parameters to update
You must update the following parameter in the WorkflowGen configuration (click on the Configuration
panel from the Administration module home page):
l
Web application URL: you must update the protocol of the base URL of the application to "https://".
Links to WorkflowGen
Change the links to WorkflowGen: use "https://" instead of "http://".
51
WorkflowGen 5.7.4 Technical Reference Guide
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 configuration file ("web.config") parameter
"ApplicationDataPath". For example: "add key="ApplicationDataPath" value="\\SERVER\SHARE" />".
The default value is empty and thus will point to the physical directory "DISK:\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:
l
High volume (large attachments, document archiving, high usage level)
l
Web Farm architecture implementation (see Web Farm architecture on page 53)
Basic configuration allows you to easily move these files but with a low security level.
Note: File storage configuration is available only in the Enterprise, Archive, and Developer editions of
WorkflowGen.
Basic configuration
Overview
Each WorkflowGen application can have its own specified file storage path specified in their individual
web.config files by modifying its "ApplicationDataPath" parameters with the desired storage path. If no path is
specified, then the default path for the WorkflowGen application is used.
Default application data path
Workflow Web Applications:
l
DISK:\Inetpub\wwwroot\wfgen\WfApps\WebApps\[application_name]\App_Data
Workflow Web Services:
l
DISK:\Inetpub\wwwroot\wfgen\WfApps\WebServices\[application_name]\App_Data
Custom application data path examples
DocApproval web.config settings:
l
< add key="ApplicationDataPath" value="\\SERVER\SHARE$\WfApps\WebApps\DocApproval\App_
Data" />
52
WorkflowGen 5.7.4 Technical Reference Guide
PdfToDatabase web.config settings:
l
< add key="ApplicationDataPath"
value="\\SERVER\SHARE$\WfApps\Webservices\PdfToDatabase\App_Data" />
Based on this setting:
l
l
The transactions.xml file should be in:
"\\SERVER\SHARE$\WfApps\WebServices\PdfToDatabase\App_Data\transactions.xml".
The logs will be created in: "\\SERVER\SHARE$\WfApps\WebServices\PdfToDatabase\App_
Data\LogFiles".
The following steps must be followed to configure your web server:
1. Create the storage folder on the file server "DISK:\FOLDER" (e.g. "D:\filepub").
2. Re-create the folder tree structure relative to the file storage location:
l
DISK:\FOLDER\wwwroot\wfgen\App_Data
l
DISK:\FOLDER\wwwroot\wfgen\WfApps\WebApps\DocApproval\App_Data\Files
l
DISK:\FOLDER\wwwroot\wfgen\WfApps\WebApps\DocUpload\App_Data\Files
l
DISK:\FOLDER\wwwroot\wfgen\WfApps\WebApps\eFormASPX\App_Data\Files
l
DISK:\FOLDER\wwwroot\wfgen\WfApps\WebApps\eFormPDF\App_Data\Files
l
DISK:\FOLDER\wwwroot\wfgen\WfApps\WebServices\FdfToXml\App_Data\LogFiles
l
DISK:\FOLDER\wwwroot\wfgen\WfApps\WebServices\PdfToDatabase\App_Data\LogFiles
l
DISK:\FOLDER\wwwroot\wfgen\WfApps\WebServices\xmlToDatabase\App_Data\LogFiles
l
DISK:\FOLDER\wwwroot\wfgen\WfApps\WebServices\XmlTrans\App_Data\LogFiles
3. Copy the existing files and folders from their original locations to the new locations, which should still be
following the same structure.
4. Create a share on the folder DISK:\FOLDER. This folder should then be accessible by a UNC name of
type "\\SERVER\SHARE$".
5. Finally, you must give NTFS modify permissions on the share as well as all of its folders and sub-folders
for all users of WorkflowGen.
WorkflowGen parameterization
The WorkflowGen configuration must now be modified to reflect the change in the file storage location. The
parameter ApplicationDataPath can be edited manually in web.config.
e.g. < add key="ApplicationDataPath" value="\\SERVER\SHARE$" />
Based on the path examples in step 2, the value for the ApplicationDataPath should be:
53
WorkflowGen 5.7.4 Technical Reference Guide
WorkflowGen:
l
\\SERVER\SHARE$\wwwroot\wfgen\App_Data
Workflow Web Applications and Services:
l
\\SERVER\SHARE$\wwwroot\wfgen\WfApps\WebApps\[application_name]\App_Data
l
\\SERVER\SHARE$\wwwroot\wfgen\WfApps\WebServices\[application_name]\App_Data
The reason for this is because WorkflowGen will use the specified path in ApplicationDataPath to store the
"\Files", "\LogFiles", and "\Templates" folders.
Note: WorkflowGen will not automatically add \wwwroot\wfgen\App_Data as a prefix to those folders, which
is why it must be explicitly specified. This also applies to web applications.
Web Farm architecture
Overview
To allow higher availability and scalability of the application, it is possible to install the Enterprise or Developer
edition of WorkflowGen in a Web Farm architecture. The application is therefore installed on many servers,
but the database and file storage directory are centralized to one dedicated server.
User requests are automatically routed to different servers depending on the load and availability of the
different servers. You can choose between different methods of "load balancing" such as DNS Round Robin
or setup a hardware Load Balancer.
54
WorkflowGen 5.7.4 Technical Reference Guide
Implementation method
Prerequisites
l
WorkflowGen Enterprise Edition on all Web servers
l
Externalization and centralization of the file storage location
l
Identical configuration on all sites
File storage location
The externalization of the file storage location is detailed in Advanced configuration on page 51. Apply the
basic configuration explained in this section before modifying the WorkflowGen configuration.
WorkflowGen configuration
Some parameters must be centralized, and all versions of WorkflowGen must use the same configuration
parameters. WorkflowGen Web Farm configuration is done in four steps:
1. We'll assume that the file storage directory is defined as "DISK:\FOLDER" and its UNC path as
"\\SERVER\SHARE$". Copy the following configuration files keeping the relative directory tree
structure. You must apply the file storage settings in order to centralize certain common files such as
request data, emails template, and transactions.xml files that are used by the different WorkflowGen
web servers (for more information, see Advanced configuration on page 51).
2. You must manually modify the WorkflowGen configuration parameter "ApplicationDataPath" to define
the path for all resources.
l
You can set up one ApplicationDataPath in WFG web.config file and remove the node/parameter
from the web.config file for all web applications and webservices. They will then inherit the
ApplicationDataPath from the main WorkflowGen parameter.
OR
l
You can set up the ApplicationDataPath for each web application and webservice with its own
ApplicationDataPath setting (for more information, see Advanced configuration on page 51).
3. Verify that all web servers have the same configuration for the WorkflowGen application and for all
workflow applications. The web configuration files (web.config) must be identical.
The WorkflowGen Engine Service is a Windows Service that is installed with WorkflowGen v5 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 the data of
type file) and one web server since they have identical configurations (with regards to the applications).
55
WorkflowGen 5.7.4 Technical Reference Guide
Online database backup
Overview
This new feature allows process file data (including attachments) to be stored in the database. It provides a
solution to perform online WorkflowGen data backup without interrupting service (during the backup,
WorkflowGen users can continue to work). This feature is available only in the Enterprise edition.
Setup and configuration (not required if running version 5.1 or greater)
Database server
l
l
SQL Server: Run "\pack\Databases\MsSQLServer\Update.sql" from the database server management
SQL command tool.
Oracle: Run "\pack\Databases\Oracle\Update.sql" from the database server management SQL
command tool.
WorkflowGen web configuration
l
New parameter: ApplicationDefaultProcessDataFileStorageMethod
This parameter will define the default process data file storage method when creating a new process or
importing a process XPDL of previous version.
<add key="ApplicationDefaultProcessDataFileStorageMethod" value="File" />
Values:
l
l
File: Process data files are stored in the file system. This option offers the same storage method used in
previous 5.0 releases.
Database: Process data files are stored in the database.
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
In the Process information tab:
l
l
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
In the Process information tab:
56
WorkflowGen 5.7.4 Technical Reference Guide
l
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:
l
l
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 process data of type "FILE" 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
parameters in Advanced configuration on page 51 and Web Farm architecture on page 53 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 be used by requests and actions at the initialization time.
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 solution will ensure 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
(applicable only to WorkflowGen version 5.1.6 and later). Each instance of WorkflowGen also requires a
dedicated license. This section assumes that you have already installed separate instances of WorkflowGen
as described in Setup on page 14.
Setup and configuration
To configure multiple instances of WorkflowGen on a single server, perform the steps outlined below. While
more than two installs 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. Be sure to run it as the administrator of the server.
57
WorkflowGen 5.7.4 Technical Reference Guide
C:\Program Files\Advantys\WorkflowGen1\Services\bin\winsvc-uninstall.cmd
WorkflowGen directory synchronization service
For both instances of WorkflowGen, add a new configuration parameter to the WorkflowGen Directory Sync
Service configuration file "WfgDirectoriesSyncService.exe.config", assuming the following installation paths:
Instance 1:
C:\Program Files\Advantys\WorkflowGen1\Services\bin\WfgDirectoriesSyncService.exe.config
<add key="ServiceName" value="WorkflowGenDirSyncService1"/>
Instance 2:
C:\Program Files\Advantys\WorkflowGen2\Services\bin\WfgDirectoriesSyncService.exe.config
<add key="ServiceName" value="WorkflowGenDirSyncService2"/>
WorkflowGen Engine service
For both instances of WorkflowGen, add a new configuration parameter to the WorkflowGen engine service
configuration file "WfgWorkflowEngineService.exe.config", assuming the following installation paths:
Instance 1:
C:\Program Files\Advantys\WorkflowGen1\Services\bin\WfgWorkflowEngineService exe.config
<add key="ServiceName" value="WorkflowGenEngineService1"/>
Instance 2:
C:\Program Files\Advantys\WorkflowGen2\Services\bin\WfgWorkflowEngineService exe.config
<add key="ServiceName" value="WorkflowGenEngineService2"/>
Windows NT 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 Windows services "WfgDirectoriesSyncService" and "WfgWorkflowEngineService" as
described above.
Instance 1:
Install script
C:\Program Files\Advantys\WorkflowGen1\Services\bin\winsvc-install.cmd
Based on the value given for the "ServiceName" parameter defined in the WorkflowGen directory
synchronization service section above, your winsvc-install.cmd file should appear as follows:
58
WorkflowGen 5.7.4 Technical Reference Guide
SC query WorkflowGenDirSyncService1 |Find.exe "does not exist"
IF %ERRORLEVEL% EQU 0 (
%windir%\Microsoft.NET\Framework\v2.0.50727\InstallUtil.exe /i "C:\Program
Files\Advantys\WorkflowGen1\Services\bin\WfgDirectoriesSyncService.exe"
net start WorkflowGenDirSyncService1
) ELSE (
%windir%\Microsoft.NET\Framework\v2.0.50727\InstallUtil.exe /u "C:\Program
Files\Advantys\WorkflowGen1\Services\bin\WfgDirectoriesSyncService.exe"
)
SC query WorkflowGenEngineService1 |Find.exe "does not exist"
IF %ERRORLEVEL% EQU 0 (
%windir%\Microsoft.NET\Framework\v2.0.50727\InstallUtil.exe /i "C:\Program
Files\Advantys\WorkflowGen1\Services\bin\WfgWorkflowEngineService.exe"
net start WorkflowGenEngineService1
) ELSE (
%windir%\Microsoft.NET\Framework\v2.0.50727\InstallUtil.exe /u "C:\Program
Files\Advantys\WorkflowGen1\Services\bin\WfgWorkflowEngineService.exe"
)
pause
Uninstall script
C:\Program Files\Advantys\WorkflowGen1\Services\bin\winsvc-uninstall.cmd
Based on the value given for the "ServiceName" parameter defined in the WorkflowGen directory
synchronization service section above, your "winsvc-uninstall.cmd" file should appear as follows:
%windir%\Microsoft.NET\Framework\v2.0.50727\InstallUtil.exe /u "C:\Program
Files\Advantys\WorkflowGen1\Services\bin\WfgDirectoriesSyncService.exe" /LogFile=
%windir%\Microsoft.NET\Framework\v2.0.50727\InstallUtil.exe /u "C:\Program
Files\Advantys\WorkflowGen1\Services\bin\WfgWorkflowEngineService.exe" /LogFile=
pause
Instance 2:
Install script
Based on the value given for the "ServiceName" parameter defined in the WorkflowGen directory
synchronization service section above, your "winsvc-install.cmd" file should appear as follows:
C:\Program Files\Advantys\WorkflowGen2\Services\bin\winsvc-install.cmd
59
WorkflowGen 5.7.4 Technical Reference Guide
SC query WorkflowGenDirSyncService2 |Find.exe "does not exist"
IF %ERRORLEVEL% EQU 0 (
%windir%\Microsoft.NET\Framework\v2.0.50727\InstallUtil.exe /i "C:\Program
Files\Advantys\WorkflowGen2\Services\bin\WfgDirectoriesSyncService.exe"
net start WorkflowGenDirSyncService2
) ELSE (
%windir%\Microsoft.NET\Framework\v2.0.50727\InstallUtil.exe /u "C:\Program
Files\Advantys\WorkflowGen2\Services\bin\WfgDirectoriesSyncService.exe"
)
SC query WorkflowGenEngineService2 |Find.exe "does not exist"
IF %ERRORLEVEL% EQU 0 (
%windir%\Microsoft.NET\Framework\v2.0.50727\InstallUtil.exe /i "C:\Program
Files\Advantys\WorkflowGen2\Services\bin\WfgWorkflowEngineService.exe"
net start WorkflowGenEngineService2
) ELSE (
%windir%\Microsoft.NET\Framework\v2.0.50727\InstallUtil.exe /u "C:\Program
Files\Advantys\WorkflowGen2\Services\bin\WfgWorkflowEngineService.exe"
)
pause
Uninstall script
Based on the value given for the "ServiceName" parameter defined in the WorkflowGen directory
synchronization service section above, your "winsvc-uninstall.cmd" file should appear as follows:
C:\Program Files\Advantys\WorkflowGen2\Services\bin\winsvc-uninstall.cmd
%windir%\Microsoft.NET\Framework\v2.0.50727\InstallUtil.exe /u "C:\Program
Files\Advantys\WorkflowGen2\Services\bin\WfgDirectoriesSyncService.exe" /LogFile=
%windir%\Microsoft.NET\Framework\v2.0.50727\InstallUtil.exe /u "C:\Program
Files\Advantys\WorkflowGen2\Services\bin\WfgWorkflowEngineService.exe" /LogFile=
pause
Install the Windows services
For both instances, you must run the install scripts that have been modified as described above.
Instance 1:
C:\Program Files\Advantys\WorkflowGen1\Services\bin\winsvc-install.cmd
Instance 2:
C:\Program Files\Advantys\WorkflowGen2\Services\bin\winsvc-install.cmd
60
WorkflowGen 5.7.4 Technical Reference Guide
Database scaling
Overview
The database scaling feature (available only in the Enterprise edition 5.1.7 and later) allows for the addition of
database servers in order to dramatically improve server performance and response times. The additional
"Slave" database servers will be used as dedicated read-only servers (SELECT SQL queries). The "Slave"
database servers are replicated from the existing Master database using the SQL Server Replication service.
Note: Oracle replication capability will be supported at a later date.
Below is an example of a typical (current architecture) WorkflowGen instance (Figure 1), followed by a
WorkflowGen Enterprise instance configured to use one "Master" database and two "Slave" database servers
(Figure 2).
Figure 1
61
WorkflowGen 5.7.4 Technical Reference Guide
Figure 2
Requirements
Overview
l
WorkflowGen Release 5.1.7 or higher
l
WorkflowGen Enterprise edition license on all web servers
l
SQL Server 2005 or 2008 Standard or higher for all database servers
l
SQL Server Replication feature must be installed on all SQL Server instances
l
SQL Server Agent must be installed and configured on all SQL Server instances
Note: Oracle database will be supported at a later date.
62
WorkflowGen 5.7.4 Technical Reference Guide
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 (see the IIS
Web Server 1 example in Figure 2 above).
If your current architecture differs from this example, you can adapt the procedure and some specific
configuration options according to your specific needs.
We assume your current WorkflowGen environment meets the following prerequisites:
l
The initial WFGEN database is already installed in the "Master" database instance
l
The "Slave" database instance does not contain an existing WFGEN database
l
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 and not the default value of 65536.
Run the following SQL statements in the source (master) and destination (slaves) SQL Server database
instances:
EXEC sp_configure "max text repl size", 2147483647;
GO
RECONFIGURE;
GO
For more information, refer to http://msdn.microsoft.com/en-us/library/ms186225.aspx.
SQL Server replication services
To set up a Publication on the "Master" database:
1. Open SQL Server Management Studio 2008.
2. Connect to the "Master" database instance.
3. Open the Replication node.
4. Right-click on Local Publications and choose New Publication… The New Publication Wizard will
open.
63
WorkflowGen 5.7.4 Technical Reference Guide
5. Click Next.
64
WorkflowGen 5.7.4 Technical Reference Guide
6. Select WFGEN in the Publication Database list.
7. Click Next.
65
WorkflowGen 5.7.4 Technical Reference Guide
8. Select Transactional publication in the Publication type list.
9. Click Next.
66
WorkflowGen 5.7.4 Technical Reference Guide
10. Check all Tables and Views (optional if the WorkflowGen Reporting Module is installed in the current
database instance) in the Articles list.
11. Click Next.
67
WorkflowGen 5.7.4 Technical Reference Guide
Note: This is optional if the WorkflowGen Reporting Module is installed in the current database instance.
12. Click Next.
68
WorkflowGen 5.7.4 Technical Reference Guide
Note: There is no need to filter the data in the publication.
13. Click Next.
69
WorkflowGen 5.7.4 Technical Reference Guide
14. Check Create a snapshot immediately and keep the snapshot available to initialize
subscriptions.
15. Click Next.
70
WorkflowGen 5.7.4 Technical Reference Guide
71
WorkflowGen 5.7.4 Technical Reference Guide
16. In Agent Security / Security Settings… provide valid service or administrator credentials for the
Windows account.
17. Click Next.
18. Check Create the publication.
19. Click Next.
72
WorkflowGen 5.7.4 Technical Reference Guide
20. Enter the Publication name "WFGEN_PUB".
21. Click Finish. If all is successful, close the New Publication Wizard.
To set up a subscription on the "Slave" database:
1. Open SQL Server Management Studio 2008.
2. Connect to the "Slave" database instance.
3. Open the Replication node.
4. Right-click on Local Subscriptions and choose New Subscription… The New Subscription Wizard
will open.
73
WorkflowGen 5.7.4 Technical Reference Guide
5. Click Next.
74
WorkflowGen 5.7.4 Technical Reference Guide
6. Select <Find SQL Server Publisher…>.
7. Connect to the "Master" database instance.
75
WorkflowGen 5.7.4 Technical Reference Guide
8. Select WFGEN_PUB in the Databases and publications list.
9. Click Next.
76
WorkflowGen 5.7.4 Technical Reference Guide
10. Select Run each agent at its Subscriber (pull subscriptions).
11. Click Next.
77
WorkflowGen 5.7.4 Technical Reference Guide
12. In the Subscription Database column, select <New database…>.
78
WorkflowGen 5.7.4 Technical Reference Guide
13. Enter the Database name "WFGEN" and click OK.
79
WorkflowGen 5.7.4 Technical Reference Guide
14. Click Next.
80
WorkflowGen 5.7.4 Technical Reference Guide
15. In Distribution Agent Security, provide valid service or administrator credentials for the Windows
account.
16. Click Next.
81
WorkflowGen 5.7.4 Technical Reference Guide
17. In Synchronization Schedule, select Run continuously.
18. Click Next.
82
WorkflowGen 5.7.4 Technical Reference Guide
19. In Initialize Subscriptions, select Immediately.
20. Click Next.
83
WorkflowGen 5.7.4 Technical Reference Guide
21. Select Create the subscription(s).
22. Click Next.
84
WorkflowGen 5.7.4 Technical Reference Guide
23. Click Finish. If all is successful, close the New Subscription Wizard.
85
WorkflowGen 5.7.4 Technical Reference Guide
24. Create and add the SQL user "WFGEN_USER" to the WFGEN "Slave" database security with db_
datareader and db_datawriter permissions.
Note: The WFGEN_USER account will be used in the connection string for the WFGEN "Slave" database in
WorkflowGen.
Database scaling in WorkflowGen
Enable the multi-database mode in WorkflowGen:
1. Connect to the WorkflowGen Administration module.
2. Open the Configuration panel and select the General tab.
3. In the Read-only database connection string field, enter the WFGEN connection string of the "Slave"
database instance.
86
WorkflowGen 5.7.4 Technical Reference Guide
4. Check Enable on Multi-database to turn on the database scaling feature.
5. Check each of the specific Portal pages and Modules:
l
If unchecked, it will use the "Master" database.
l
If checked, it will use the "Read-only" database.
6. Save and close.
References
l
SQL Server 2008 Books Online Replication: http://msdn.microsoft.com/en-us/library/ms151198.aspx
l
SQL Server "max text repl size" Option: http://msdn.microsoft.com/en-us/library/ms186225.aspx
87
WorkflowGen 5.7.4 Technical Reference Guide
Operations
Backup
Overview
The data and database files should be backed up regularly to preserve the reliability of the processes and their
associated data.
Note: It is strongly recommended to perform the backup of the database and the files at the same time. To
enforce data integrity, it is also recommended to stop IIS and Database services.
Full (data + applications)
Application and data files
"... /wfgen"
Database
Standard SQL database backup provided with your DBMS.
If the file storage path is not standard (App_Data), you have to back up the corresponding folder.
Data only
Database
Standard SQL database backup provided with your DBMS.
Data files
".../wfgen/App_Data/Files/Dataset" (files associated with requests and actions).
Moving the WorkflowGen database
SQL Server database
To move the WorkflowGen SQL Server database from one server to another:
1. Stop IIS services on the production server.
2. Detach the WorkflowGen database.
3. Copy the .MDF and .LDF files to the new location.
4. Attach the file to the new database server.
88
WorkflowGen 5.7.4 Technical Reference Guide
5. Update the connection string from the configuration module.
6. Restart your IIS services.
Oracle database
Please refer to your DBA for a database move.
Moving the WorkflowGen application
To move the WorkflowGen installation from one server to another:
1. Stop IIS services on the production server.
2. Set up the same version of WorkflowGen on the new server.
3. Copy the "\wfgen\App_Data" directory content of the old server to the new one.
4. If you have created your own web forms, SDK applications, or Web services:
i. Copy their folders in the corresponding tree structure of the new server. For example, if you have
created a Web service named "MyWebService" that is situated in
"\wfgen\wfapps\WebServices\MyWebServices" then you need to copy the entire folder to the
same place on the new server.
ii. Create the IIS application with the same directory security options on the new server for the
applications you have copied.
iii. For Web services or SDK Applications, make sure to update the application URL in the
Administration module.
iv. For Web forms, be sure to update the FORM_URL data in the process definition to point to the
new URL.
v. Repeat this process for every custom application you have created.
5. Update the application URL from the configuration module.
6. If you have PDF forms, you need to replace the old server address with the new one in the FDF files in
the entire "\wfgen\App_Data\Files" folder.
Monitoring
Storage space
File data
The only directory that you need to monitor for storage space is the "/wfgen/App_Data" directory. The other
directories should always keep the same size because everything that is generated over the time is placed in
this directory.
89
WorkflowGen 5.7.4 Technical Reference Guide
Database
The database size can be monitored by watching the .MDF and .LDF files if you are using SQL Server, or it
can be done with your DBMS tools.
Storage space needs may vary depending on whether or not the Store file content in database process data
storage option is selected during the process definition.
Directory synchronization
The directory synchronization log files can be found in the "wfgen/App_Data/LogFiles/Dir/Synchro" directory.
You can consult and manage the logs history directly in the Administration module of WorkflowGen instead of
browsing the files directly.
Windows service
The Windows service should always be running automatically when the server starts. Periodically, the
Windows service will perform the following necessary tasks:
l
Raise overdue exceptions
l
Send overdue notifications
l
Delete inactive delegations
l
Delete ghost activities (activities initialized but never started)
Usage
Requests/actions by day
A statistics module is provided in the portal module to see very detailed reports on the requests and actions.
Many filters can be applied to the different reports, and a charting service is also provided.
Attachment file size
Attachments that will be made to your processes by using Web forms or PDF forms will be saved to the App_
Data directory of the eFormASPX or eFormPDF application respectively. Later, WorkflowGen copies those
files to a permanent location. If the Store file content in database process data storage option is selected,
then attachments are stored directly to the database in real time.
The files that are created in eFormASPX and eFormPDF are temporary and are automatically deleted every
day, after which the attachments will be in the App_Data directory of WorkflowGen only
("wfgen/AppData/Files/…"). This is not applicable to processes for which the option to store file content in the
database is selected.
If you know that a process takes too much space on the disk because of the process data, or too much space
in the database because of file attachments, you can turn off the Archive action associated data option in
the process definition. This will prevent the attached file from being stored for each action of every request.
Only the data after the last action will be kept on the disk or in the database.
90
WorkflowGen 5.7.4 Technical Reference Guide
Using IIS SMTP gateway
For best performance, the IIS SMTP gateway should be used. In this configuration all emails are redirected to
a "Smart host".
On the WorkflowGen web server:
1. In IIS, Edit the properties of the Default SMTP virtual server.
2. In the Access tab, click Relay...
3. Click the All except the list below radio button.
4. Click Apply and close this window. (For an increased security level, grant access only to the web server
IP.)
5. In the Delivery tab, click the Advanced... button.
6. In the Smart host field enter your SMTP gateway address (IP or hostname).
7. Click Apply.
For more information, see Configuring IIS on page 34.
91
WorkflowGen 5.7.4 Technical Reference Guide
Synchronizing a directory in
command line
The automatic users and groups synchronization is provided by this Windows service. This service is
installed by the setup pack and started automatically after installation.
The default suggested installation path is
"C:\Program Files\Advantys\WorkflowGen\Services\bin\WfgDirectoriesSyncService.exe".
The synchronization service can also be executed from a command line.
You must specify the "/c" or "/console" parameter.
The following parameters are optional:
l
/p[ath]:location Location of the web.config file use to synchronize (usually the web.config file of
WorkflowGen).
l
/d[irectories]:list List of directories to synchronize (, or ; for separator).
l
/s[ilence] No output will be generated in the console.
l
l
/f[orce] Synchronization will ignore the scheduling information and the automatic/manual parameter of
the directory.
/h[elp] or /? Displays the help for console execution.
Note: If an error occurs the exit code 1 is returned, otherwise 0 is returned.
Example 1:
This sample launches the directory synchronization of the WorkflowGen instance installed on the folder
"d:\inetpub\wwwroot\wfgen":
WfgDirectoriesSyncService.exe /c /p:d:\inetpub\wwwroot\wfgen\web.config
Example 2:
This sample forces the synchronization of the directory MyDir of the WorkflowGen instance installed in the
folder "d:\inetpub\wwwroot\wfgen":
WfgDirectoriesSyncService.exe /c /p:d:\inetpub\wwwroot\wfgen\web.config /d:MyDir /f
92
WorkflowGen 5.7.4 Technical Reference Guide
Sample code for an HTTP module
Overview
This sample is an HTTP module that uses an HTTP authentication. You must insert your own method to
authenticate users.
For more information about Custom HTTP module development, please refer to the .NET documentation.
Source code
//*********************************************************************
// Copyright ©.
//
// Purpose:
// Sample code for an HTTP module
//
//*********************************************************************
using System;
using System.Web;
using System.Security.Principal;
using System.Text;
using System.Diagnostics;
namespace MyCompany.Hosting.Samples
{
/// <summary>
/// Summary description for CustomAuthModule
/// </summary>
public class CustomAuthModule : IHttpModule
{
/// <summary>
/// Constructor
/// </summary>
public CustomAuthModule()
{
}
#region IHttpModule Members
/// <summary>
93
WorkflowGen 5.7.4 Technical Reference Guide
/// Release any resources
/// </summary>
public void Dispose()
{
}
/// <summary>
/// Initialization of module
/// </summary>
/// <param name="context"></param>
public void Init(HttpApplication application)
{
application.AuthenticateRequest += new EventHandler(application_
AuthenticateRequest);
}
/// <summary>
/// Delegate for authenticating a request
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
void application_AuthenticateRequest(object sender, EventArgs e)
{
HttpApplication application = sender as HttpApplication;
Debug.Assert(application != null);
// Has the client sent Authorization information
//
if (application.Context.Request.ServerVariables["HTTP_AUTHORIZATION"] == null)
{ // Redirects client to send HTTP Basic credentials
//
application.Response.StatusCode = 401;
application.Response.AddHeader("WWW-Authenticate", "Basic");
application.Response.End();
}
else
{
// Retrieve authentication string
//
string authString = application.Request.ServerVariables["HTTP_
AUTHORIZATION"];
// If the authentication method is basic
//
if (authString.Substring(0, 5).ToLowerInvariant().Equals("basic"))
94
WorkflowGen 5.7.4 Technical Reference Guide
{
string[] credentials;
bool isValidUser = false;
// Decode credentials
//
credentials = DecodeBase64String(authString.Substring(6)).Split(':');
// Credentials should have two cells
//
// credentials[0] is the username
// credentials[1] is the password
Debug.Assert(credentials.Length == 2);
//
// ****************************
// Perform your check here
// ****************************
//
// isValidUser = YourAuthenticationMethod(credentials[0], credentials
[1]);
if (isValidUser)
{
// Create a user
//
GenericPrincipal user =
new GenericPrincipal(
new GenericIdentity(credentials[0], "Basic"),
new string[] { "role_name" });
// Set this user for the session
//
application.Context.User = user;
}
}
}
}
/// <summary>
/// Decodes a Base64-encoded string
/// </summary>
95
WorkflowGen 5.7.4 Technical Reference Guide
/// <param name="base64EncodedString"> </param>
/// <returns></returns>
private string DecodeBase64String(string base64EncodedString)
{
try
{
UTF8Encoding encoder = new UTF8Encoding();
Decoder decoder = encoder.GetDecoder();
byte[] bytesToDecode = Convert.FromBase64String(base64EncodedString);
int charCount = decoder.GetCharCount(bytesToDecode, 0,
bytesToDecode.Length);
char[] decodedChars = new char[charCount];
decoder.GetChars(bytesToDecode, 0,
bytesToDecode.Length, decodedChars, 0);
return new String(decodedChars);
}
catch (Exception e)
{
throw new Exception("Error in DecodeBase64String: " + e.Message);
}
}
#endregion
}
}