Top
Systemwalker Runbook Automation Reference Guide
Systemwalker

3.13.1 Obtain current date

Description

This operation component outputs the current date in the specified format.

Options

Basic Options

(1) dateformat

The output format of the current date.

Y: The year of our Lord (four digits) is output.

M: The month (two digits) is output.

D: The day (two digits) is output.

H: The hour (two digits) is output.

N: The minute (two digits) is output.

S: The second (two digits) is outputs.

It is possible to be used the above in combination. This option is not case sensitive.

For example: When the year of our Lord, the month, the day, and the hour is output: YMDH

An argument error occurs if the dateformat is omitted.

An argument error also occurs if the same character is specified more than once or if any character other than those above is specified.

Advanced Options

(1) timeout

This is the completion timeout (seconds) for the execution of operation components.

Values between 0 and 86400 (1 day) can be specified.

For example: When timeout is to occur every 10 minutes: 600

When the execution of the operation components is not completed even if the specified time passes, the processing of the operation components is stopped in return value 201.

(2) retry

This is the retry count for the execution of operation components.

Specify the count that will be retried when the operation component is finished in return value 161. Values between 0 and 5 can be specified.

When the operation components is terminated in return values other than 161 as a result of the retrying, the operation components will be terminated even if it doesn't reach the specified retry counts. The return value of the operation components returns the value executed at the end.

For example: When retries are to be performed twice: 2

(3) retry_interval

This is the retry interval (seconds) for operation components.

Specify the interval that will be retried when the operation component is terminated in return value 161. Values between 1 and 14400 can be specified.

For example: When retries are to be performed at 300 seconds interval: 300


If the specification of the "timeout", "retry", and "retry_interval" is omitted and a value beyond the limits of the above-mentioned is input, the value specified with the operation components definition file becomes effective. Refer to "2.5 Definition File for Operation Components" for details.

Return Values

Icon

Name

Return value

Description

Success

0

Acquisition of the current date was successful.

Failure

161

Failed the acquisition of the current date. When the retry count is specified, it will be retried.

197

There is an error in the input information.

198

There is an error in the specification of the option.

-

-

201

Execution of operation component timed out.

202

The operation component was not executed. There is a problem in the setting to execute the operation components.

203

The operation components were not able to be executed normally. There is a problem in the Management Server environment.

205

The operation component was not executed. There is a problem with the input information specification of the operation component.

206

The operation component was not executed normally. There is a problem with the output information specification of the operation component.

207

The operation component was not executed. There is a possibility that the operation components have not been registered in the Management Server.

208

The Automated Operation Process has been canceled because the Automated Operation Process was recovered while the operation component was executing.

Output information

Variable

Description

message

This variable will be set to the following message if the current date/time is obtained successfully.

The operation component was successful.

If an attempt to obtain the current date/time fails, the content of the error will be set as a string.

current_time

This variable is set to the current date and time, using the specified format.

Example: If "YMDHMS" has been specified and the date/time obtained was 10:30:30 on January 1, 2010 then this variable will be set to "20100101103030".

returnCode

This variable is set to the return value.

Notes

Confirm the message in any of the above-mentioned place, and execute appropriate measures. Refer to the Systemwalker Runbook Automation Message Guide for details.