Skip Headers
Oracle® Fusion Middleware WebLogic Scripting Tool Command Reference
11g Release 1 (10.3.6)

Part Number E13813-12
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Feedback page
Contact Us

Go to previous page
Previous
PDF · Mobi · ePub

20 Enterprise Scheduler Custom WLST Commands

Use the Oracle Enterprise Scheduler commands in the categories listed in Table 20-1 to manage Enterprise Scheduler configuration, servers, logs, and job requests.

Note:

To use these Enterprise Scheduler custom WLST commands, you must invoke the WLST script from the Oracle Common home. See "Using Custom WLST Commands" in the Oracle Fusion Middleware Administrator's Guide.

When running these WLST commands, you must have the following JARs on your classpath:

Enterprise Scheduler Custom Commands

Use the Enterprise Scheduler commands listed in Table 20-1 to manage the Enterprise Scheduler server, configuration, job requests, and logs. In the Use with WLST column, "online" means the command can only be used when connected to a running administration server. "Offline" means the command can only be used when not connected to a running server.

Table 20-1 Oracle Enterprise Scheduler Management Commands

Use this command... To... Use with WLST...

essGetRequestContent

Get the log and output data files for a request after its execution is completed.

Online

essManageRequest

Cancel, recover, or complete request state manually.

Online

essManageRuntimeConfig

Add, modify, delete and display various configuration parameters.

Online

essManageServer

Start, stop or get status of the Enterprise Scheduler application running on the server.

Online

essQueryRequests

Search and list requests based upon hosting application name, state or elapsed time of execution.

Online


essGetRequestContent

Command Category: ESS

Use with WLST: Online

Description

Get the log and output data files for a request after its execution is completed.

Syntax

essGetOutputContent(requestId, contentType, logLines, outDir)
Argument Definition

requestId

The request ID.

contentType

Type of the content to handle. Can be LOG, OUTPUT, BINARY_OUTPUT or TEXT_OUTPUT. By default, the OUTPUT contentType checks for both BINARY_OUTPUT and TEXT_OUTPUT contents.

logLines

Optional. The number of lines to be read form the request log. Default is 1000.

outDir

Optional. The absolute path of the output directory to dump the output files into. Default is the current directory.


Examples

To get the request log for request ID 123.

essGetOutputContent(123, "LOG")

To get all the output of request 123.

essGetOutputContent(123, "OUTPUT")

To get all the output of request 123 and save it in directory /tmp.

essGetOutputContent(123, "OUTPUT", outDir="/tmp")

To get all the text output of request 123 and save it in directory /tmp.

essGetOutputContent(123, "TEXT_OUTPUT", outDir="/tmp")

To get all the binary output of request 123 and save it in directory /tmp.

essGetOutputContent(123, "BINARY_OUTPUT", outDir="/tmp")

To get first 100 lines of the request log for request id 123.

essGetOutputContent(123, "LOG", logLines=100)

essManageRequest

Command Category: ESS

Use with WLST: Online

Description

Cancel, recover, or complete request state manually.

Syntax

essManageRequest(requestId, operation, asyncStatus, statusMessage)
Argument Definition

requestId

The request ID.

operation

The operation to perform: CANCEL, RECOVER, or COMPLETE.

asyncStatus

Mandatory when the COMPLETE operation is specified. The status to set for the given request. Must be one of the following:

  • BIZ_ERROR

  • CANCEL

  • ERROR

  • ERROR_MANUAL_RECOVERY

  • PAUSE

  • SUCCESS

  • UPDATE

  • WARNING

statusMessage

Optional. The qualifying status message to describe the operation.


Examples

To cancel request 123.

essManageRequest(123, "CANCEL")

To recover request 123.

essManageRequest(123, "RECOVER")

To complete request 123.

essManageRequest(123, "COMPLETE", asyncStatus="ERROR", statusMessage="Completed by Admin")

essManageRuntimeConfig

Command Category: ESS

Use with WLST: Online

Description

Add, modify, delete and display various configuration parameters.

Syntax

essManageRuntimeConfig(app, type, operation, name, val)
Argument Definition

app

The hosting application name for managing runtime configuration.

type

The type of configuration property. Can be either APP or ESS.

operation

Optional. The operation to perform. Value can be one of the following: add (add), mod (modify), del (delete), get (get), or getall (get all). The default is getall.

name

Optional when the getall value is used for operation. The name of the configuration parameter.

val

Optional when the del, get, or getall value is used for operation. The value to set for the parameter.


Examples

To add an ENV parameter "foo" with value "bar".

essManageRuntimeConfig("myapp", "APP", operation="add", name="foo", val="bar")

To get the value of the ENV parameter "foo".

essManageRuntimeConfig("myapp", "APP", operation="get", name="foo")

To get the list of all the ENV parameters.

essManageRuntimeConfig("myapp", "APP", operation="getall")
essManageRuntimeConfig("myapp", "APP")

To modify the value of the ENV parameter "foo" to "barone".

essManageRuntimeConfig("myapp", "APP", operation="mod", name="foo", val="barone")

To delete the ENV parameter "foo".

essManageRuntimeConfig("myapp", "APP", operation="del", name="foo")

To show all parameters of type ESS.

essManageRuntimeConfig("myapp", "ESS")

essManageServer

Command Category: ESS

Use with WLST: Online

Description

Start, stop or get status of the Enterprise Scheduler application running on the server. Starting the Enterprise Scheduler application means to start the Enterprise Scheduler processor thread so that request processing can start. Stopping Enterprise Scheduler means to stop or quiesce the Enterprise Scheduler processor so that no new requests are processed.

If connected to the WLS Administration Server in a cluster, this command would operate upon all nodes in the cluster.

Syntax

essManageServer(operation)
Argument Definition

operation

The operation to perform. One of START, STOP, or STATUS.


Examples

To stop Enterprise Scheduler.

essManageServer("STOP")

To get the current state of the Enterprise Scheduler processor.

essManageServer("STATUS")

essQueryRequests

Command Category: ESS

Use with WLST: Online

Description

Search and list requests based on hosting application name, state or elapsed time of execution. This command can be used to find long running requests.

Syntax

essQueryRequests(app, state, days, hours, minutes)
Argument Definition

app

Optional. The name of the hosting application.

state

Optional. The request state. Can be one of the following (default is RUNNING):

  • BLOCKED

  • CANCELLED

  • CANCELLING

  • COMPLETED

  • ERROR

  • ERROR_AUTO_RETRY

  • ERROR_MANUAL_RECOVERY

  • EXPIRED

  • FINISHED

  • HOLD

  • PAUSED

  • PENDING_VALIDATION

  • READY

  • RUNNING

  • SCHEDULE_ENDED

  • SUCCEEDED

  • VALIDATION_FAILED

  • WAIT

  • WARNING

days

Optional. Specifies the time in days.

hours

Optional. Specifies the time in hours.

minutes

Optional. Specifies the time in minutes.


Examples

To get all the requests in RUNNING state.

essQueryRequests()
essQueryRequests(state="RUNNING")

To get all CANCELLED requests.

essQueryRequests(state="CANCELLED")

To get all requests running for more than 2 days.

essQueryRequests(days=2)

To get all requests running for more than 10 hours.

essQueryRequests(hours=10)

To get all requests running for the application "myapp".

essQueryRequests(appName="myapp")