16.10 - SendEvent - Teradata Ecosystem Manager

Teradata Ecosystem Manager API Reference

prodname
Teradata Ecosystem Manager
vrm_release
16.10
created_date
June 2017
category
Programming Reference
featnum
B035-3204-067K

Syntax

The SendEvent command sends an event to the Ecosystem Manager Publisher.

sendevent [-g] [--tds TDPID] [-e Ecosystem ID] [-s System] [-u user][--et Event Type] [-r Resource] [-t Resource Type] [-w UoW ID] [--wss UoW Source System] [--wdb UoW Database] [--wtb UoW Table Name] [--wts UoW Timestamp] [--wft UoW From Timestamp][--whs UoW Health String] [--app Application ID] [--st State] [-v UoW Value] [-j Job Step Name] [--js Job Sub-Step Name][--jid Job ID] [--sid Server ID][--wid Workflow ID][-m Message] [-a Alert Code] [-l severity] [--log logfile] [--gt UOW Token File] [-d DML Mode]
[--o1 Arg1] [--o2 Arg2] [--o3 Arg3] [--ets Event Timestamp][--sc Resource sub-category]

Required arguments:

  • -g can be used alone or in combination with other flags.
  • For normal events, --tds or -e, --et, -r, -t are all required.

where

Argument Description
-g Request a unit of work identifier (UOW ID). If not provided, one is automatically generated and output to standard out [console out]. The value generated is a standard universally unique identifier.
--tds TDPID. Supersedes the ecosystem identifier. The maximum length is 64 characters. Required for all events.
-e Ecosystem identifier. Typically, this is the data warehouse or the data center. The maximum length is 20 characters. Required if --tds is not used.
-et Event type. Domain of values: START, STEP, END, RESTART, ALERT, HCHK, CLEAR, STEPCLEAR, STATE, RQ_STATE, APPSTATE, RQ_APPST TBLSTATE, RQ_TBLST, and UNITYSTATE
-r Resource. Resource name. Required. The maximum length is 72 characters. Required for START, STEP, ALERT, END, STATE, RQ_STATE, CLEAR, STEPCLEAR, and HCHK events.
-t Resource type. Implementation-specific resource type. The maximum length is 50 characters. Required for START, STEP, ALERT, END, STATE, RQ_STATE, CLEAR, STEPCLEAR, and HCHK events.
-w Unit of work identifier. A transaction ID to be used instead of an auto-generated identifier. The maximum length is 300 characters.
-gt Get UnitOfWork ID – Get unit of work from filename specified.

Following are three use cases:

-g --gt < filename > sendevent generates a universally unique identifier, returns it on the stdout stream (current feature), and writes it to the filename specified by the --gt flag. If these arguments are used in a complete sendevent command, the generated universally unique identifier is set as the unit of work identifier for the event.

-w <uowid> --gt < filename > sendevent sends an event using the uowid specified by the -w flag and writes the uowid to the file name specified by the --gt flag.

--gt < filename > sendevent sends an event using the uowid from the filename specified by the --gt flag.

-v Required with END and STEP events. Unit of work health check value. The maximum length is 38 total digits, with no more than 36 digits to the left of the decimal point.
--st Required with STATE, RQ_STATE, APPSTATE, RQ_APPST, TBLSTATE, RQ_TBLST, and UNITYSTATE events. Specifies to what state to which you want to change a resource.

Valid values: 10 is active, 20 is standby, 25 is passive, 30 is restore, 40 is out-of-service (OOS), 15 is read-only, 35 is interrupted, 50 is unrecoverable, and 60 is disconnected.

-a Alert code. (Required if this is an alert type of message.)
--app Application identifier. The maximum length is 20 characters. Required for APPSTATE and RQ_APPST events.
-l Severity level defaults to one domain. Valid values: 1 is normal, 5 is warning, and 10 is critical.
-s System identifier. Typically, the system where the event originated, but it can be the system for which an event is being reported. This is a descriptive name and does not have to be an actual DNS name. The maximum length is 72 characters.
-u User identifier. The maximum length is 30 characters.
--wde Unit of work description. The maximum length is 200 characters.
--wts Unit of work time stamp.
--wtd Unit of work date marker.
--wss Unit of work source system. Used for reporting purposes only. The maximum length is 72 characters.
--wdb Affected database name. The maximum length is 128 characters. Required for TBLST and RQ_TBLST events.
--wtb Affected table name. The maximum length is 128 characters. Required for TBLST and RQ_TBLST events.
--wnm Unit of work name. The maximum length is 30 characters.
--wft Unit of work ‘From’ time stamp.
--whs Unit of work health string. The maximum length is 500 characters.
--wct Unit of work class. The maximum length is 72 characters.
-j Job step name. Identifies an individual jobstep within a job where the job is identified by -r and -t flags. This optional flag is used for the STEP events to identify a second level of granularity within a job and required for RESTART events to specify the failed node from which the workflow is restarted. The maximum length is 255 characters.
-js Job sub-step name. Step within a multiple step load stream used to identify distinct steps within a job. Use this flag when using STEP events to identify a third level of granularity within a job. The maximum length is 255 characters.
--jid Job Id. This is used interchangeably with resource id for START, STEP, END, ALERT, CLEAR events. This flag takes priority if resourceid is also specified. The maximum length is 72 characters.
--sid Server Id. This is used interchangeably with resource id for ALERT, CLEAR, HCHK, STATE events. This flag takes priority if resourceid is also specified. The maximum length is 72 characters.
--wid Workflow ID. This is used interchangeably with Resource ID for START, ALERT, CLEAR, and END events. This flag takes priority if the Resource ID is also specified. The maximum length is 72 characters.
-m Message. A text message. The maximum length is 1000 characters.
--log Log file. The maximum length is 500 characters.
-d Data Manipulation Language (DML) code. Values: INSERT, DELETE, and UPDATE. This value is used in conjunction with --wdb and --wtb to report on individual table change activity. This flag identifies the type of change to the database table. The maximum length is 50 characters.
--o1 Optional Arg 1. Optional argument with implementation-specific data. The maximum length is 50 characters.
--o2 Optional Arg 2. Optional argument with implementation-specific data. The maximum length is 50 characters.
--o3 Optional Arg 3. Optional argument with implementation-specific data. The maximum length is 50 characters.
--sts Event time stamp. Overwrite the generated time stamp of the event with a preset value. By default, sendevent generates a time stamp that is set to the current time. This flag is optional and should not be used frequently.

Valid formats are yyyy-mm-ddThh:mm:ss and yyyy-mm-dd hh:mm:ss.

-sc Resource subcategory that identifies a server or job. The maximum value is 10 characters.

Valid values for servers are LAG, RS, BI, BAR, LS, USL, APP, ETL, BUS, DMC, VP, UNKNOWN.

Valid values for jobs are CONT, VAL, BAR, REPL, DM, BATCH.