Oracle Fusion Middleware extensions for Logging and Diagnostics
11g Release 1 (11.1.2)

E22565-02

oracle.apps.fnd.appltest.diagfwk.engine.impl
Class StepExecutorBase

java.lang.Object
  extended by oracle.apps.fnd.appltest.diagfwk.engine.impl.StepExecutorBase
All Implemented Interfaces:
DiagConstants, DiagImplConstants, StepExecutor
Direct Known Subclasses:
StepExecutorJava, StepExecutorPLSQL, StepExecutorTestRef

public abstract class StepExecutorBase
extends java.lang.Object
implements StepExecutor, DiagImplConstants

Abstract base class for execution of steps within the diagnostics tests.

Since:
release specific (what release of product did this appear in)
Version:
$Header: atgpf/appltest/applications/Diagnostics/Engine/src/oracle/apps/fnd/appltest/diagfwk/engine/impl/StepExecutorBase.java /main/18 2010/11/29 15:21:53 lwong Exp $
Author:
ppradhan

Nested Class Summary
static class StepExecutorBase.TokenEvaluator
          Helper class for evaluating tokens
static class StepExecutorBase.TokenEvaluatorStepOutput
          Evaluates tokens of type ${step:[stepname].outputs.[paramname]}
static class StepExecutorBase.TokenEvaluatorTestInput
          Evaluates tokens of type ${test.inputs.[paramname]}
static class StepExecutorBase.TokenEvaluatorTestOutput
          Evaluates tokens of type ${test.outputs.[paramname]}
 
Nested classes/interfaces inherited from interface oracle.apps.fnd.appltest.diagfwk.common.DiagConstants
DiagConstants.ExecutionMode, DiagConstants.Format, DiagConstants.LinkType, DiagConstants.Status
 
Field Summary
protected  DiagContextExtn mContext
           
protected  TestStepType mStep
           
 
Fields inherited from interface oracle.apps.fnd.appltest.diagfwk.engine.impl.DiagImplConstants
KEY_I_PARAM_DEF_REF, KEY_O_PARAM_DEF_REF, KEY_REF_TEST_DEF_TABLE, KEY_STEP_INPUT_PARAM_SECRET, SECRET_MASK, STEP_REP_EXEC_NAME_ENGINE, STEP_REP_NAME_ENGINE_LOG, TOKEN_DELIM, TOKEN_OUTPUTS, TOKEN_STEP, TOKEN_TEST_INPUTS, TOKEN_TEST_OUTPUTS
 
Fields inherited from interface oracle.apps.fnd.appltest.diagfwk.common.DiagConstants
APPS_MSG_ID_TAG_NAME, CFG_ADR_PROVIDER_CLASS, CFG_CACHE_PROVIDER_CLASS, CFG_CRED_PROVIDER_CLASS, CFG_DAO_FACTORY_CLASS, CFG_DB_CONN_INFO_PROVIDER_CLASS, CFG_DB_CONN_PROVIDER_CLASS, CFG_NLS_PROVIDER_CLASS, CFG_PLSQL_PROVIDER_CLASS, CFG_PROFILE_PROVIDER_CLASS, CFG_SECURITY_PROVIDER_CLASS, CFG_SESSION_INFO_PROVIDER_CLASS, CFG_URL_PROVIDER_FACTORY_CLASS, CFG_WLS_MBEANSRV_CONNINFO_PROVIDER_CLASS, DATA_SECURITY_PERMISSION_ALLOWED, DATA_SECURITY_PERMISSION_NOT_ALLOWED, DELIM_URL, EXEC_MODE_CLI, EXEC_MODE_ESS, EXEC_MODE_INCIDENT, EXEC_MODE_JAVA, EXEC_MODE_UI, EXECUTABLE_TYPE_JAVA, EXECUTABLE_TYPE_PLSQL, EXECUTABLE_TYPE_TESTREF, FORMAT_HTML, FORMAT_XML, GUID_ORACLE_MINUS1, GUID_ORACLE_ZERO, INPUTS_STATUS_ALL_OPT_INPUTS, INPUTS_STATUS_NO_INPUTS, INPUTS_STATUS_REQ_INPUTS_NO_DEFAULTS, INPUTS_STATUS_REQ_INPUTS_W_DEFAULTS, IO_FLAG_I, IO_FLAG_O, JMX_API_BASE_OBJECT_NAME, LINK_EXTERNAL, LINK_INTERNAL, LINK_METALINK, N, NLS_BUNDLE_JAVA_RES, NLS_BUNDLE_MSG_SVC, NLS_BUNDLE_RES_REF, NLS_BUNDLE_XLIFF, NO, NULL, ODF_MBEAN_DOMAIN_NAME, PARAM_MON_INTERVAL, PLSQL_DEBUG_ENABLED_SYSTEM_PROP, PREREQ_TYPE_TAG_VALUE, PREREQ_TYPE_TEST, SECONDS_IN_ONE_DAY, SECONDS_IN_ONE_HOUR, STATUS_CANCELED, STATUS_EXECERROR, STATUS_FAILURE, STATUS_RUNNING, STATUS_SUCCESS, STATUS_WARNING, SYS_PROP_MAX_MONITOR_INTERNVAL, SYS_PROP_MAX_NUM_THREADS, SYSPROP_APPCONNFILE, SYSPROP_DIAG_CONFIG_FILE, TAG_TYPE_DIAG, TAG_TYPE_TAXONOMY, TEST_TYPE_DECL, TEST_TYPE_JAVA, USER_NAME, WEB_APP_NAME_TAG_NAME, Y, YES
 
Constructor Summary
StepExecutorBase()
           
 
Method Summary
protected  void completeStep()
          Performs any finishing activities to complete the step report.
 void execute(TestStepType pStep, DiagContextExtn pContext)
          Executes the given step within the given execution context.
protected abstract  void executeStep()
          Executes the step definition for this step.
protected abstract  java.lang.String getExecutableName()
          Gets the name of the executable for this step
protected abstract  java.lang.String getExecutableType()
          Gets the type of the executable for this step.
protected static StepExecutorBase.TokenEvaluator getTokenEvaluator(java.lang.String pToken, DiagContextExtn pCtx)
          Returns an instance of the Token Evaluator based on the given token.
protected  void initializeStep(TestStepType pStep, DiagContextExtn pContext)
          Initializes the execution of the step.
protected  void initializeStepReport()
          Initializes the step report for this step.
protected  void prepareContextForStepExecution()
          Prepares the context for step execution.
protected  void resolveParameterBindings()
          Resolves parameter bindings if any are defined in the step metadata.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

mStep

protected TestStepType mStep

mContext

protected DiagContextExtn mContext
Constructor Detail

StepExecutorBase

public StepExecutorBase()
Method Detail

execute

public void execute(TestStepType pStep,
                    DiagContextExtn pContext)
Description copied from interface: StepExecutor
Executes the given step within the given execution context.

Specified by:
execute in interface StepExecutor
Parameters:
pStep - the diagnostics test step to be executed
pContext - context for the execution.

initializeStep

protected void initializeStep(TestStepType pStep,
                              DiagContextExtn pContext)
Initializes the execution of the step.


completeStep

protected void completeStep()
Performs any finishing activities to complete the step report. This includes copying any output parameters from the step level to current execution level and also publishing those output parameters to report


prepareContextForStepExecution

protected void prepareContextForStepExecution()
Prepares the context for step execution. This involves resolving parameter bindings and updating the context with step level parameters.


resolveParameterBindings

protected void resolveParameterBindings()
Resolves parameter bindings if any are defined in the step metadata. After resolution the values for the bounded parameters are set into the context under the scope of the current step.

The bindings that are currently resolved are:

  1. ${test.inputs.[paramname]} - this binding is resolved to the value of input parameter [paramname] in the current execution context.
  2. ${test.outputs.[paramname]} - this binding is resolved to the value of output parameter [paramname] in the current execution context.
  3. ${step:[stepname].outputs.[paramname]} - this binding is resolved to the value of output parameter [paramname] generated by step [stepname] in this execution.


initializeStepReport

protected void initializeStepReport()
Initializes the step report for this step.


executeStep

protected abstract void executeStep()
Executes the step definition for this step.


getExecutableName

protected abstract java.lang.String getExecutableName()
Gets the name of the executable for this step

Returns:
the name of the executable for this step

getExecutableType

protected abstract java.lang.String getExecutableType()
Gets the type of the executable for this step. Type could be 'J' for Java step, or 'T' for Test Reference step or 'P' for PLSQL

Returns:
type of the executable for this step.

getTokenEvaluator

protected static StepExecutorBase.TokenEvaluator getTokenEvaluator(java.lang.String pToken,
                                                                   DiagContextExtn pCtx)
Returns an instance of the Token Evaluator based on the given token. Returns null if the given token is unrecognized.

Parameters:
pToken - token to evaluate
pCtx - context of execution
Returns:
an instance of TokenEvaluator that can be used to evaluate the given token

Oracle Fusion Middleware extensions for Logging and Diagnostics
11g Release 1 (11.1.2)

E22565-02

Copyright © 2011 Oracle. All Rights Reserved.