Setting the Name and Editing the Process Definition Source
Naming and Location
Every process definition requires a unique name and should be part of an application. Applications are there to store your process definition in containers along with other objects, that belong together. This allows you to migrate your processes or back them up easily with the Import/Export module.
Waiting on a File
You can specify a file that is used to trigger the process by choosing Start this process when a file arrives. The following table describes the different settings that are at your disposal:
Field | Description |
---|---|
Process Server | The process server on which the file arrives |
Directory | The directory where the file arrives |
Pattern | A GLOB pattern (use * and ?) that will be used to match the file |
Move Directory | Allows you to move the file out of the way into another directory |
Overwrite File | Should the file overwrite an existing file when it is moved? |
Default Queue | Since the process is started automatically, you must set a default queue for it to run in |
Script Type
The following job definition types allow you to specify a source, if the corresponding license key is enabled:
- BASH - For writing Bourne Again SHell scripts. BASH is installed on all Linux systems and optionally on all UNIX (compatible) platforms that Redwood Server runs on.
- CL - For writing IBM AS/400 CL definitions submitted to AS/400 systems via the AS/400 connector.
- CMD - For writing Microsoft Windows Command scripts.
- CSH - For writing C Shell scripts. Available on most UNIX systems.
- JCL_FTP - For writing JCL scripts submitted via FTP to remote IBM zSeries servers running the MVS or z/OS operating system controlled by JES2 or JES3.
- KSH - For writing Korn shell script, for OS processes that run on UNIX (compatible) servers.
- OS Native - For writing OS-independent scripts. The default shell of the Run As User defines the target shell.
- PERL - For writing Perl scripts.
- PERL (Unicode) - For writing Perl scripts with UNICODE characters in your script source.
- PS1 - For writing Microsoft Windows PowerShell language scripts. PowerShell is delivered with Microsoft Server 2008 and later.
- Python - For writing Python scripts.
- R - For writing R scripts.
- RedwoodScript - The RedwoodScript definition type allows you to write server based scripts that interact with the repository using the RedwoodScript language.
- VBScript - For writing Microsoft Windows Visual Basic Script OS processes.
Library
The library allows you to use your classes across all process definitions, which is especially useful for RedwoodScript process definitions. It can also be used for parameter validation, you need to setup Redwood Expression Entry points in the library for the methods you would like to expose to Redwood Expression Language. See the Redwood Expression Language for more information.
Run As User
Some definition types allow you to specify a user under which the code is executed, the user needs to exist and not be locked for the code to be executed on the target system.
Redwood recommends the use of Credentials as you only have one object to change when the password changes, for example. When you use credentials there must be a credential for the user or virtual user on the node, also known as endpoint, where the OS process will be running. See the Assign Users from External Platforms to OS Processes with Credentials section for more information.
The Remote Run As User is used in process definition of types FTP as well as SQLPLUS and is the user used to log into the remote FTP server or Oracle database. The Run As User will be the account used to run the client software (jftp or sqlplus) on the process server.
You can override the values of the [Remote] Run As User fields with JCS_[REMOTE_]USER
parameters, see the Assign Users from External Platforms to OS Processes with Credentials section for more information.
You can specify [<domain>\]<suer>/<password>@<server>
in a Run As User field, however, this syntax does not allow you to use '/', '\', or '@'
in passwords and is not recommended.
The syntax for a credential is as follows:
[[<domain>\]<useranme>
Where <domain>
is the LAN Manager domain name found in the domain drop-down when you log into Microsoft Windows Domains and <username>
matches the Username field of the credential.
Example
A credential for user oracle exists for all process servers of the queue where you submitted the job:
oracle
All process servers of the queue where you submitted the process have a credential for EXAMPLE\jdoe
and the servers trust users from the EXAMPLE
domain:
EXAMPLE\jdoe
The syntax for a credential with virtual user:
{virtual}:<user>
Where <user>
is the value of the Virtual User field of the credential.
Example
Every process server in the queue where you submitted the process have a credential which has the Virtual User field set to erpuser
.
{virtual}:erpuser
Values
The source tab contains the following fields:
Field | Description | Default Value |
---|---|---|
Type | The definition type | |
Library | The library containing your JAVA classes | Custom |
Run As User | The user that will execute the source on the process server | |
Remote Run As User | The remote user that will be used in the source | |
Source | The code to be executed |
Exceptions
The following definition types do not allow you to change/edit the source code:
- JOBCHAIN
- SAPPI
- SAPR3
- SYSTEM
See Also
Run as User RunAsUser JobChain JobDefinition ProcessDefinition