User Guide > Objects > Alphabetical Listing > Process Tab

Process Tab

The Process tab is an object typeAn individual object is provided for the individual activities: There are User, UserGroup, Notification, Cockpit, CodeTable, Documentation, Event, Agent, FileTransfer, Group, Include, Job, Workflow, Calendar, Login, Client, RemoteTaskManager, Schedule, Script, Server, Sync, Variable and TimeZone objects-specific tab in which the processing commands of AE's scripting language are stored.

Object: Job
Object class:
Executable objectAutomation Engine controlled activities and processes are structured in the form of objects. See also: Task
Object type (short name):
JOBS

Description

The scriptA particular Automation Engine object type. is either processed at jobAn Automation Engine object type for a process that runs on a target system. activation or start. This point in time depends on the Generate-at-runtimeThe duration of a task's execution. It refers to the period between a task's start and end. It does not include its activation period (see also: activation and start). setting which can be defined in the Attributes tab.

Processing commands that should be processed in the header (such as setting specific host attributesPlatform-independent attributes of the Job object.) or executed before the Job Messenger starts, must be defined in the Pre Process tab.

Processing commands that should be processed after the job has ended are stored in the Post Process tab. In doing so, you can influence the final end of this job.

These lines correspond to the particular JCL (Job Control LanguageShort form of "Job Control Language". It refers to applications that are processing steps executed on computers.) of the target system and are transferred to the target system exactly as they are. DATA lines can, for example, contain BS2000 commands or MS DOS commands for batch processing.

Special Functions for Guardian/NSK

Special functions are provided for theautomated handling of input requests.

JCL for z/OS

The actual JCL is indicated here. Do NOT specify a job card (to be specified through the attributes) or an end card.

SAP JCL Interpreted By the SAP Agent

Because there is no JCL in SAP, AE supplies a SAP JCL which is interpreted by the SAP agentA program that enables the de-centralized execution of processes (such as deployments) on target systems (computers or business solutions) or a service that provides connectivity to a target system (such as for databases or middleware). An agent is also an object type in the Automation Engine. [Formerly called "Executor."] See also: host and converted to processing statements for the target system.

Enabling an Interpreter for Windows

You may also enter a script for use with an external interpreter. To enable the interpretation of that script, use :BEGIN_EXT_INTERPRETER and :END_EXT_INTERPRETER
In addition the Storage object's binary files may be attached and transferred to the Windows agent, using the Script functionPre-defined run book template in the Automation Engine. One single step only, e.g. Start Windows Service, Copy file,… :ATTACH_RES to attach and transfer these binary files.
For details on using these functions see the respective topics.

In order to use these functions, you have to configure the variables UC_EXT_INTERPRETERS_WINDOWS and :REGISTER_VARIABLE.

Enabling an Interpreter for UNIX

The same condition as above applies to UNIX: You may enter a script for use with an external interpreter. To enable the interpretation of that script, use :BEGIN_EXT_INTERPRETER and :END_EXT_INTERPRETER
In addition the Storage object's binary files may be attached and transferred to the UNIX agent, using the Script function :ATTACH_RES to attach and transfer these binary files.
For details on using these functions see the respective topics.

In order to use these functions, you have to configure the variables UC_EXT_INTERPRETERS_UNIX and :REGISTER_VARIABLE.

Windows BAT and Powershell Examples

The Windows BAT script below puts the output of the C:\Temp directory into a file and checks whether the command ran successfully. If the command does not complete successfully, the job will end with the return codeThe value that represents the result of tasks and script functions. from the dir command:

dir C:\temp /S >> C:\temp\test.txt
@set retcode=%errorlevel%
@if NOT %ERRORLEVEL% == 0 goto :retcode

The Windows Powershell script below gets content of the C:\Temp directory and puts the output into a file. Then the error code from Powershell will be checked and if is not equal to 0, the job aborts with $LastExitCode, which is the equivalent to %ERRORLEVEL% in the CMD.EXE/.BAT script.

Get-ChildItem C:\Temp > C:\Temp\test.txt
if( $LastExitCode -ne 0 )
{ __uc_return $LastExitCode }

The __uc_return function is provided in the HEADER.WINDOWS include object and can be used for ending of Powershell jobs.

 

See also:

Script Editor
About AE Scripts
Sample Collection
Configure Include Objects for External Interpreter Calls

 


Automic Documentation - Tutorials - Automic Blog - Resources - Training & Services - Automic YouTube Channel - Download Center - Support

Copyright © 2016 Automic Software GmbH