public class Trans extends Object implements org.pentaho.di.core.variables.VariableSpace, org.pentaho.di.core.parameters.NamedParams, HasLogChannelInterface, org.pentaho.di.core.logging.LoggingObjectInterface, ExecutorInterface, org.pentaho.di.core.ExtensionDataInterface
| Modifier and Type | Field and Description |
|---|---|
int |
class_nr
The class number.
|
static String |
CONFIGURATION_IN_EXPORT_FILENAME
Constant specifying a filename containing XML to inject into a ZIP file created during resource export.
|
static String |
REPLAY_DATE_FORMAT
The replay date format.
|
static String |
STRING_FINISHED
Constant indicating a transformation status of Finished.
|
static String |
STRING_HALTING
Constant indicating a transformation status of Halting.
|
static String |
STRING_INITIALIZING
Constant indicating a transformation status of Initializing.
|
static String |
STRING_PAUSED
Constant indicating a transformation status of Paused.
|
static String |
STRING_PREPARING
Constant indicating a transformation status of Preparing for execution.
|
static String |
STRING_RUNNING
Constant indicating a transformation status of Running.
|
static String |
STRING_STOPPED
Constant indicating a transformation status of Stopped.
|
static String |
STRING_WAITING
Constant indicating a transformation status of Waiting.
|
static int |
TYPE_DISP_1_1
Constant indicating a dispatch type of 1-to-1.
|
static int |
TYPE_DISP_1_N
Constant indicating a dispatch type of 1-to-N.
|
static int |
TYPE_DISP_N_1
Constant indicating a dispatch type of N-to-1.
|
static int |
TYPE_DISP_N_M
Constant indicating a dispatch type of N-to-M.
|
static int |
TYPE_DISP_N_N
Constant indicating a dispatch type of N-to-N.
|
| Constructor and Description |
|---|
Trans()
Instantiates a new transformation.
|
Trans(TransMeta transMeta)
Initializes a transformation from transformation meta-data defined in memory.
|
Trans(TransMeta transMeta,
org.pentaho.di.core.logging.LoggingObjectInterface parent)
Initializes a transformation from transformation meta-data defined in memory.
|
Trans(org.pentaho.di.core.variables.VariableSpace parentVariableSpace,
Repository rep,
String name,
String dirname,
String filename)
Instantiates a new transformation using any of the provided parameters including the variable
bindings, a repository, a name, a repository directory name, and a filename.
|
| Modifier and Type | Method and Description |
|---|---|
void |
activateParameters()
Activates all parameters by setting their values.
|
void |
addDelegationListener(DelegationListener delegationListener) |
void |
addParameterDefinition(String key,
String defValue,
String description)
Adds a parameter definition to this transformation.
|
RowProducer |
addRowProducer(String stepname,
int copynr)
This adds a row producer to the transformation that just got set up.
|
void |
addTransListener(TransListener transListener)
Adds a transformation listener.
|
void |
addTransStoppedListener(TransStoppedListener transStoppedListener)
Adds a stop-event listener to the transformation.
|
void |
beginProcessing()
Begin processing.
|
void |
calculateBatchIdAndDateRange()
Calculate the batch id and date range for the transformation.
|
String |
calculateTransactionId()
Calculates the transaction ID for the transformation.
|
void |
cleanup()
This method performs any cleanup operations, typically called after the transformation has finished.
|
static int |
cleanupCluster(org.pentaho.di.core.logging.LogChannelInterface log,
TransSplitter transSplitter)
Cleanup the cluster, including the master and all slaves, and return the number of errors that occurred.
|
static void |
cleanupSlaveServer(TransSplitter transSplitter,
SlaveServer slaveServer,
TransMeta slaveTransMeta)
Cleanup the slave server as part of a clustered transformation.
|
void |
clearError()
Clear the error in the transformation, clear all the rows from all the row sets, to make sure the transformation can continue with other data.
|
void |
clearParameters()
Clear the values of all parameters.
|
void |
copyParametersFrom(org.pentaho.di.core.parameters.NamedParams params)
Copy parameters from a NamedParams object.
|
void |
copyVariablesFrom(org.pentaho.di.core.variables.VariableSpace space)
Copies variables from a given variable space to this transformation.
|
void |
doTopologySortOfSteps() |
String |
environmentSubstitute(String aString)
Substitutes any variable values into the given string, and returns the resolved string.
|
String[] |
environmentSubstitute(String[] aString)
Substitutes any variable values into each of the given strings, and returns an array containing
the resolved string(s).
|
void |
eraseParameters()
Remove all parameters.
|
void |
execute(String[] arguments)
Executes the transformation.
|
static TransSplitter |
executeClustered(TransMeta transMeta,
TransExecutionConfiguration executionConfiguration)
Execute the transformation in a clustered fashion.
|
static void |
executeClustered(TransSplitter transSplitter,
TransExecutionConfiguration executionConfiguration)
Executes an existing TransSplitter, with the transformation already split.
|
String |
fieldSubstitute(String aString,
org.pentaho.di.core.row.RowMetaInterface rowMeta,
Object[] rowData) |
List<StepInterface> |
findBaseSteps(String stepname)
Find the base steps for the step with the specified name.
|
StepDataInterface |
findDataInterface(String name)
Find the data interface for the step with the specified name.
|
MappingInput[] |
findMappingInput()
Gets the mapping inputs for each step in the transformation.
|
MappingOutput[] |
findMappingOutput()
Gets the mapping outputs for each step in the transformation.
|
org.pentaho.di.core.RowSet |
findRowSet(String rowsetname)
Finds the RowSet with the specified name.
|
org.pentaho.di.core.RowSet |
findRowSet(String from,
int fromcopy,
String to,
int tocopy)
Finds the RowSet between two steps (or copies of steps).
|
StepInterface |
findRunThread(String stepname)
Find the run thread for the step with the specified name.
|
StepInterface |
findStepInterface(String stepname,
int copyNr)
Find the executing step copy for the step with the specified name and copy number
|
List<StepInterface> |
findStepInterfaces(String stepname)
Find the available executing step copies for the step with the specified name
|
Map<String,Job> |
getActiveSubjobs()
Gets the active sub-jobs.
|
Map<String,Trans> |
getActiveSubtransformations()
Gets the active sub-transformations.
|
String[] |
getArguments() |
long |
getBatchId()
Gets the batch ID of the transformation.
|
boolean |
getBooleanValueOfVariable(String variableName,
boolean defaultValue)
Returns a boolean representation of the specified variable after performing any necessary substitution.
|
static org.pentaho.di.core.Result |
getClusteredTransformationResult(org.pentaho.di.core.logging.LogChannelInterface log,
TransSplitter transSplitter,
Job parentJob)
Gets the clustered transformation result.
|
static org.pentaho.di.core.Result |
getClusteredTransformationResult(org.pentaho.di.core.logging.LogChannelInterface log,
TransSplitter transSplitter,
Job parentJob,
boolean loggingRemoteWork)
Gets the clustered transformation result.
|
String |
getContainerObjectId()
Gets the container object ID.
|
Hashtable<String,org.pentaho.di.core.Counter> |
getCounters() |
Date |
getCurrentDate()
Gets the current date/time object.
|
List<DelegationListener> |
getDelegationListeners() |
Date |
getDepDate()
Gets the dependency date for the transformation.
|
Date |
getEndDate()
Gets the end date/time object for the transformation.
|
int |
getEnded()
Gets the number of steps in the transformation that are in an end state, such as Finished, Halted, or Stopped.
|
int |
getErrors()
Gets the number of errors that have occurred during execution of the transformation.
|
String |
getExecutingServer()
Gets the name of the executing server.
|
String |
getExecutingUser()
Gets the name of the executing user.
|
Map<String,Object> |
getExtensionDataMap() |
String |
getFilename()
Gets the filename of the transformation, or null if no filename exists
|
Date |
getJobEndDate()
Gets the job end date.
|
Date |
getJobStartDate()
Gets the job start date.
|
long |
getLastProcessed()
Gets a representable metric of the "processed" lines of the last step.
|
org.pentaho.di.core.logging.LogChannelInterface |
getLogChannel()
Gets the log channel interface for the transformation.
|
String |
getLogChannelId()
Gets the log channel ID.
|
Date |
getLogDate()
Gets the date the transformation was logged.
|
List<org.pentaho.di.core.logging.LoggingHierarchy> |
getLoggingHierarchy()
Gets the logging hierarchy.
|
org.pentaho.di.core.logging.LogLevel |
getLogLevel()
Gets the log level.
|
String |
getMappingStepName()
Gets the mapping step name.
|
org.pentaho.metastore.api.IMetaStore |
getMetaStore() |
String |
getName()
Gets the name of the transformation.
|
String |
getObjectCopy()
Gets the object copy.
|
org.pentaho.di.repository.ObjectId |
getObjectId()
Gets the object ID.
|
String |
getObjectName()
Gets the object name.
|
org.pentaho.di.repository.ObjectRevision |
getObjectRevision()
Gets the object revision.
|
org.pentaho.di.core.logging.LoggingObjectType |
getObjectType()
Gets the object type.
|
String |
getParameterDefault(String key)
Gets the default value of the specified parameter.
|
String |
getParameterDescription(String key)
Gets the description of the specified parameter.
|
String |
getParameterValue(String key)
Gets the value of the specified parameter.
|
org.pentaho.di.core.logging.LoggingObjectInterface |
getParent()
Gets the parent logging object interface.
|
Job |
getParentJob()
Gets the parent job, or null if there is no parent.
|
Trans |
getParentTrans()
Gets the parent transformation, which is null if no parent transformation exists.
|
org.pentaho.di.core.variables.VariableSpace |
getParentVariableSpace()
Gets the parent variable space.
|
long |
getPassedBatchId()
Get the batch ID that is passed from the parent job to the transformation.
|
org.pentaho.di.core.Result |
getPreviousResult() |
Date |
getRegistrationDate()
Gets the registration date.
|
Date |
getReplayDate()
Gets the replay date.
|
Repository |
getRepository()
Gets the repository object for the transformation.
|
org.pentaho.di.repository.RepositoryDirectoryInterface |
getRepositoryDirectory()
Gets the repository directory.
|
org.pentaho.di.core.Result |
getResult()
Gets the result of the transformation.
|
List<org.pentaho.di.core.ResultFile> |
getResultFiles() |
List<org.pentaho.di.core.RowMetaAndData> |
getResultRows() |
List<org.pentaho.di.core.RowSet> |
getRowsets()
Gets the rowsets for the transformation.
|
StepInterface |
getRunThread(int i)
Gets the run thread for the step at the specified index.
|
StepInterface |
getRunThread(String name,
int copy)
Gets the run thread for the step with the specified name and copy number.
|
PrintWriter |
getServletPrintWriter()
Gets the servlet print writer.
|
javax.servlet.http.HttpServletRequest |
getServletRequest() |
javax.servlet.http.HttpServletResponse |
getServletResponse() |
SocketRepository |
getSocketRepository()
Gets the socket repository.
|
Date |
getStartDate()
Gets the start date/time object for the transformation.
|
String |
getStatus()
Gets the status of the transformation (Halting, Finished, Paused, etc.)
|
StepDataInterface |
getStepDataInterface(String stepname,
int stepcopy)
Finds the StepDataInterface (currently) associated with the specified step.
|
StepInterface |
getStepInterface(String stepname,
int copy)
Find the StepInterface (thread) by looking it up using the name.
|
Map<String,List<StepPerformanceSnapShot>> |
getStepPerformanceSnapShots()
Gets a named list (map) of step performance snapshots.
|
List<StepMetaDataCombi> |
getSteps()
Gets a list of steps in the transformation.
|
String |
getThreadName()
Deprecated.
please use getTransactionId() instead
|
String |
getTransactionId()
Gets the transaction ID for the transformation.
|
List<TransListener> |
getTransListeners()
Gets a list of the transformation listeners.
|
TransMeta |
getTransMeta()
Gets the meta-data for the transformation.
|
BaseStepData.StepExecutionStatus[] |
getTransStepExecutionStatusLookup()
Checks the execution status of each step in the transformations.
|
boolean[] |
getTransStepIsRunningLookup()
Checks whether the transformation steps are running lookup.
|
List<TransStoppedListener> |
getTransStoppedListeners()
Gets the list of stop-event listeners for the transformation.
|
String |
getVariable(String variableName)
Gets the value of the specified variable, or returns a default value if no such variable exists.
|
String |
getVariable(String variableName,
String defaultValue)
Gets the value of the specified variable, or returns a default value if no such variable exists.
|
boolean |
hasHaltedSteps()
Checks whether the transformation has any steps that are halted.
|
boolean |
hasStepStarted(String sname,
int copy)
Checks whether the specified step (or step copy) has started.
|
void |
initializeVariablesFrom(org.pentaho.di.core.variables.VariableSpace parent)
Sets the values of the transformation's variables to the values from the parent variables.
|
void |
injectVariables(Map<String,String> prop)
Injects variables using the given Map.
|
boolean |
isFinished()
Checks if the transformation is finished\.
|
boolean |
isForcingSeparateLogging() |
boolean |
isGatheringMetrics() |
boolean |
isInitializing()
Checks whether the transformation is initializing.
|
boolean |
isMonitored()
Checks whether the running transformation is being monitored.
|
boolean |
isPaused()
Checks if the transformation is paused.
|
boolean |
isPreparing()
Checks whether the transformation is preparing for execution.
|
boolean |
isPreview()
Checks whether the transformation is being previewed.
|
boolean |
isReadyToStart()
Checks whether the transformation is ready to start (i.e.
|
boolean |
isRunning()
Checks whether the transformation is running.
|
boolean |
isSafeModeEnabled()
Checks whether safe mode is enabled.
|
boolean |
isStopped()
Checks if the transformation is stopped.
|
void |
killAll()
Attempts to stops all running steps and subtransformations.
|
String[] |
listParameters()
Gets a list of the parameters for the transformation.
|
String[] |
listVariables()
Gets a list of variable names for the transformation.
|
void |
logSummary(StepInterface si)
Logs a summary message for the specified step.
|
static long |
monitorClusteredTransformation(org.pentaho.di.core.logging.LogChannelInterface log,
TransSplitter transSplitter,
Job parentJob)
Monitors a clustered transformation every second, after all the transformations in a cluster schema are running.
Now we should verify that they are all running as they should. If a transformation has an error, we should kill them all. This should happen in a separate thread to prevent blocking of the UI. When the master and slave transformations have all finished, we should also run a cleanup on those transformations to release sockets, etc. |
static long |
monitorClusteredTransformation(org.pentaho.di.core.logging.LogChannelInterface log,
TransSplitter transSplitter,
Job parentJob,
int sleepTimeSeconds)
Monitors a clustered transformation every second, after all the transformations in a cluster schema are running.
Now we should verify that they are all running as they should. If a transformation has an error, we should kill them all. This should happen in a separate thread to prevent blocking of the UI. When the master and slave transformations have all finished, we should also run a cleanup on those transformations to release sockets, etc. |
static void |
monitorRemoteTransformation(org.pentaho.di.core.logging.LogChannelInterface log,
String carteObjectId,
String transName,
SlaveServer remoteSlaveServer)
Monitors a remote transformation every 5 seconds.
|
static void |
monitorRemoteTransformation(org.pentaho.di.core.logging.LogChannelInterface log,
String carteObjectId,
String transName,
SlaveServer remoteSlaveServer,
int sleepTimeSeconds)
Monitors a remote transformation at the specified interval.
|
int |
nrActiveSteps()
Gets the number of active (i.e.
|
int |
nrSteps()
Gets the number of steps in this transformation.
|
void |
pauseRunning()
Pauses the transformation (pause all steps).
|
void |
prepareExecution(String[] arguments)
Prepares the transformation for execution.
|
void |
printStats(int seconds)
Logs the execution statistics for the transformation for the specified time interval.
|
void |
resumeRunning()
Resumes running the transformation after a pause (resume all steps).
|
static String |
sendToSlaveServer(TransMeta transMeta,
TransExecutionConfiguration executionConfiguration,
Repository repository,
org.pentaho.metastore.api.IMetaStore metaStore)
Send the transformation for execution to a Carte slave server.
|
void |
setArguments(String[] arguments) |
void |
setBatchId(long batchId)
Sets the batch ID of the transformation.
|
void |
setContainerObjectId(String containerObjectId)
Sets the container object ID.
|
void |
setCounters(Hashtable<String,org.pentaho.di.core.Counter> counters) |
void |
setDelegationListeners(List<DelegationListener> delegationListeners) |
void |
setExecutingServer(String executingServer)
Sets the name of the executing server.
|
void |
setExecutingUser(String executingUser)
Sets the name of the executing user.
|
void |
setForcingSeparateLogging(boolean forcingSeparateLogging) |
void |
setGatheringMetrics(boolean gatheringMetrics) |
void |
setInitializing(boolean initializing)
Sets whether the transformation is initializing.
|
void |
setInternalKettleVariables(org.pentaho.di.core.variables.VariableSpace var)
Sets the internal kettle variables.
|
void |
setJobEndDate(Date jobEndDate)
Sets the job end date.
|
void |
setJobStartDate(Date jobStartDate)
Sets the job start date.
|
void |
setLog(org.pentaho.di.core.logging.LogChannelInterface log)
Sets the log channel interface for the transformation.
|
void |
setLogLevel(org.pentaho.di.core.logging.LogLevel logLevel)
Sets the log level.
|
void |
setMappingStepName(String mappingStepName)
Sets the mapping step name.
|
void |
setMetaStore(org.pentaho.metastore.api.IMetaStore metaStore) |
void |
setMonitored(boolean monitored)
Sets whether the running transformation should be monitored.
|
void |
setParameterValue(String key,
String value)
Sets the value for the specified parameter.
|
void |
setParent(org.pentaho.di.core.logging.LoggingObjectInterface parent)
Sets the parent logging object.
|
void |
setParentJob(Job parentJob)
Sets the parent job for the transformation.
|
void |
setParentTrans(Trans parentTrans)
Sets the parent transformation.
|
void |
setParentVariableSpace(org.pentaho.di.core.variables.VariableSpace parent)
Sets the parent variable space.
|
void |
setPassedBatchId(long jobBatchId)
Sets the passed batch ID of the transformation from the batch ID of the parent job.
|
void |
setPreparing(boolean preparing)
Sets whether the transformation is preparing for execution.
|
void |
setPreview(boolean preview)
Sets whether the transformation is being previewed.
|
void |
setPreviousResult(org.pentaho.di.core.Result previousResult) |
void |
setReplayDate(Date replayDate)
Sets the replay date.
|
void |
setRepository(Repository repository)
Sets the repository object for the transformation.
|
void |
setResultFiles(List<org.pentaho.di.core.ResultFile> resultFiles) |
void |
setResultRows(List<org.pentaho.di.core.RowMetaAndData> resultRows) |
void |
setRunning(boolean running)
Sets whether the transformation is running.
|
void |
setSafeModeEnabled(boolean safeModeEnabled)
Turn on safe mode during running: the transformation will run slower but with more checking enabled.
|
void |
setServletPrintWriter(PrintWriter servletPrintWriter)
Sets the servlet print writer.
|
void |
setServletReponse(javax.servlet.http.HttpServletResponse response) |
void |
setServletRequest(javax.servlet.http.HttpServletRequest request) |
void |
setSocketRepository(SocketRepository socketRepository)
Sets the socket repository.
|
void |
setStepPerformanceSnapShots(Map<String,List<StepPerformanceSnapShot>> stepPerformanceSnapShots)
Sets the named list (map) of step performance snapshots.
|
void |
setThreadName(String threadName)
Deprecated.
please use setTransactionId() instead
|
void |
setTransactionId(String transactionId)
Sets the transaction ID for the transformation.
|
void |
setTransListeners(List<TransListener> transListeners)
Sets the list of transformation listeners.
|
void |
setTransMeta(TransMeta transMeta)
Sets the meta-data for the transformation.
|
void |
setTransStoppedListeners(List<TransStoppedListener> transStoppedListeners)
Sets the list of stop-event listeners for the transformation.
|
void |
setVariable(String variableName,
String variableValue)
Sets the value of the specified variable to the specified value.
|
void |
shareVariablesWith(org.pentaho.di.core.variables.VariableSpace space)
Shares a variable space from another variable space.
|
void |
startThreads()
Starts the threads prepared by prepareThreads().
|
void |
stopAll()
Stops all steps from running, and alerts any registered listeners.
|
String |
toString()
Gets a string representation of the transformation.
|
void |
waitUntilFinished()
Waits until all RunThreads have finished.
|
public static final String REPLAY_DATE_FORMAT
public int class_nr
public static final int TYPE_DISP_1_1
public static final int TYPE_DISP_1_N
public static final int TYPE_DISP_N_1
public static final int TYPE_DISP_N_N
public static final int TYPE_DISP_N_M
public static final String STRING_FINISHED
public static final String STRING_RUNNING
public static final String STRING_PAUSED
public static final String STRING_PREPARING
public static final String STRING_INITIALIZING
public static final String STRING_WAITING
public static final String STRING_STOPPED
public static final String STRING_HALTING
public static final String CONFIGURATION_IN_EXPORT_FILENAME
public Trans()
public Trans(TransMeta transMeta)
transMeta - the transformation meta-data to use.public Trans(TransMeta transMeta, org.pentaho.di.core.logging.LoggingObjectInterface parent)
transMeta - the transformation meta-data to use.parent - the parent job that is executing this transformationpublic Trans(org.pentaho.di.core.variables.VariableSpace parentVariableSpace,
Repository rep,
String name,
String dirname,
String filename)
throws org.pentaho.di.core.exception.KettleException
parentVariableSpace - the parent variable spacerep - the repositoryname - the name of the transformationdirname - the dirname the repository directory namefilename - the filename containing the transformation definitionorg.pentaho.di.core.exception.KettleException - if any error occurs during loading, parsing, or creation of the transformationpublic void setParent(org.pentaho.di.core.logging.LoggingObjectInterface parent)
parent - the new parentpublic org.pentaho.di.core.logging.LogChannelInterface getLogChannel()
getLogChannel in interface HasLogChannelInterfaceHasLogChannelInterface.getLogChannel()public void setLog(org.pentaho.di.core.logging.LogChannelInterface log)
log - the new log channel interfacepublic String getName()
public void execute(String[] arguments) throws org.pentaho.di.core.exception.KettleException
arguments - the argumentsorg.pentaho.di.core.exception.KettleException - if the transformation could not be prepared (initialized)public void prepareExecution(String[] arguments) throws org.pentaho.di.core.exception.KettleException
arguments - the arguments to use for this transformationorg.pentaho.di.core.exception.KettleException - in case the transformation could not be prepared (initialized)public void startThreads()
throws org.pentaho.di.core.exception.KettleException
org.pentaho.di.core.exception.KettleException - if there is a communication error with a remote output socket.public void cleanup()
public void logSummary(StepInterface si)
si - the step interfacepublic void waitUntilFinished()
public int getErrors()
public int getEnded()
public boolean isFinished()
public void killAll()
public void printStats(int seconds)
seconds - the time interval (in seconds)public long getLastProcessed()
public org.pentaho.di.core.RowSet findRowSet(String rowsetname)
rowsetname - the rowsetnamepublic org.pentaho.di.core.RowSet findRowSet(String from, int fromcopy, String to, int tocopy)
from - the name of the "from" stepfromcopy - the copy number of the "from" stepto - the name of the "to" steptocopy - the copy number of the "to" steppublic boolean hasStepStarted(String sname, int copy)
sname - the step namecopy - the copy numberpublic void stopAll()
public int nrSteps()
public int nrActiveSteps()
public boolean[] getTransStepIsRunningLookup()
public BaseStepData.StepExecutionStatus[] getTransStepExecutionStatusLookup()
public StepInterface getRunThread(int i)
i - the index of the desired steppublic StepInterface getRunThread(String name, int copy)
name - the step namecopy - the copy numberpublic void calculateBatchIdAndDateRange()
throws org.pentaho.di.core.exception.KettleTransException
org.pentaho.di.core.exception.KettleTransException - if there are any errors during calculationpublic void beginProcessing()
throws org.pentaho.di.core.exception.KettleTransException
org.pentaho.di.core.exception.KettleTransException - the kettle trans exceptionpublic org.pentaho.di.core.Result getResult()
public StepInterface findRunThread(String stepname)
stepname - the step namepublic List<StepInterface> findBaseSteps(String stepname)
stepname - the step namepublic StepInterface findStepInterface(String stepname, int copyNr)
stepname - the step namecopynr - public List<StepInterface> findStepInterfaces(String stepname)
stepname - the step namecopynr - public StepDataInterface findDataInterface(String name)
name - the step namepublic Date getStartDate()
public Date getEndDate()
public boolean isMonitored()
public void setMonitored(boolean monitored)
monitored - true if the running transformation should be monitored, false otherwisepublic TransMeta getTransMeta()
public void setTransMeta(TransMeta transMeta)
transMeta - The transformation meta-data to set.public Date getCurrentDate()
public Date getDepDate()
public Date getLogDate()
public List<org.pentaho.di.core.RowSet> getRowsets()
public List<StepMetaDataCombi> getSteps()
public String toString()
toString in class ObjectObject.toString()public MappingInput[] findMappingInput()
public MappingOutput[] findMappingOutput()
public StepInterface getStepInterface(String stepname, int copy)
stepname - The name of the step to look forcopy - the copy number of the step to look forpublic Date getReplayDate()
public void setReplayDate(Date replayDate)
replayDate - the new replay datepublic void setSafeModeEnabled(boolean safeModeEnabled)
safeModeEnabled - true for safe modepublic boolean isSafeModeEnabled()
public RowProducer addRowProducer(String stepname, int copynr) throws org.pentaho.di.core.exception.KettleException
stepname - The step to produce rows forcopynr - The copynr of the step to produce row for (normally 0 unless you have multiple copies running)org.pentaho.di.core.exception.KettleException - in case the thread/step to produce rows for could not be found.execute(String[]),
prepareExecution(String[])public Job getParentJob()
public void setParentJob(Job parentJob)
parentJob - The parent job to setpublic StepDataInterface getStepDataInterface(String stepname, int stepcopy)
stepname - The name of the step to look forstepcopy - The copy number (0 based) of the steppublic boolean hasHaltedSteps()
public Date getJobStartDate()
public Date getJobEndDate()
public void setJobEndDate(Date jobEndDate)
jobEndDate - the jobEndDate to setpublic void setJobStartDate(Date jobStartDate)
jobStartDate - the jobStartDate to setpublic long getPassedBatchId()
public void setPassedBatchId(long jobBatchId)
jobBatchId - the jobBatchId to setpublic long getBatchId()
public void setBatchId(long batchId)
batchId - the batch ID to set@Deprecated public String getThreadName()
@Deprecated public void setThreadName(String threadName)
threadName - the thread namepublic String getStatus()
public boolean isInitializing()
public void setInitializing(boolean initializing)
initializing - true if the transformation is initializing, false otherwisepublic boolean isPreparing()
public void setPreparing(boolean preparing)
preparing - true if the transformation is preparing for execution, false otherwisepublic boolean isRunning()
public void setRunning(boolean running)
running - true if the transformation is running, false otherwisepublic static final TransSplitter executeClustered(TransMeta transMeta, TransExecutionConfiguration executionConfiguration) throws org.pentaho.di.core.exception.KettleException
transMeta - the transformation's meta-dataexecutionConfiguration - the execution configurationorg.pentaho.di.core.exception.KettleException - the kettle exceptionpublic static final void executeClustered(TransSplitter transSplitter, TransExecutionConfiguration executionConfiguration) throws org.pentaho.di.core.exception.KettleException
transSplitter - the trans splitterexecutionConfiguration - the execution configurationorg.pentaho.di.core.exception.KettleException - the kettle exceptionorg.pentaho.di.ui.spoon.delegates.SpoonTransformationDelegatepublic static final long monitorClusteredTransformation(org.pentaho.di.core.logging.LogChannelInterface log,
TransSplitter transSplitter,
Job parentJob)
log - the log interface channeltransSplitter - the transformation splitter objectparentJob - the parent job when executed in a job, otherwise just set to nullpublic static final long monitorClusteredTransformation(org.pentaho.di.core.logging.LogChannelInterface log,
TransSplitter transSplitter,
Job parentJob,
int sleepTimeSeconds)
log - the subject to use for loggingtransSplitter - the transformation splitter objectparentJob - the parent job when executed in a job, otherwise just set to nullsleepTimeSeconds - the sleep time in seconds in between slave transformation status pollingpublic static int cleanupCluster(org.pentaho.di.core.logging.LogChannelInterface log,
TransSplitter transSplitter)
log - the log channel interfacetransSplitter - the TransSplitter objectpublic static void cleanupSlaveServer(TransSplitter transSplitter, SlaveServer slaveServer, TransMeta slaveTransMeta) throws org.pentaho.di.core.exception.KettleException
transSplitter - the TransSplitter objectslaveServer - the slave serverslaveTransMeta - the slave transformation meta-dataorg.pentaho.di.core.exception.KettleException - if any errors occur during cleanuppublic static final org.pentaho.di.core.Result getClusteredTransformationResult(org.pentaho.di.core.logging.LogChannelInterface log,
TransSplitter transSplitter,
Job parentJob)
log - the log channel interfacetransSplitter - the TransSplitter objectparentJob - the parent jobpublic static final org.pentaho.di.core.Result getClusteredTransformationResult(org.pentaho.di.core.logging.LogChannelInterface log,
TransSplitter transSplitter,
Job parentJob,
boolean loggingRemoteWork)
log - the log channel interfacetransSplitter - the TransSplitter objectparentJob - the parent jobloggingRemoteWork - log remote execution logs locallypublic static String sendToSlaveServer(TransMeta transMeta, TransExecutionConfiguration executionConfiguration, Repository repository, org.pentaho.metastore.api.IMetaStore metaStore) throws org.pentaho.di.core.exception.KettleException
transMeta - the transformation meta-dataexecutionConfiguration - the transformation execution configurationrepository - the repositoryorg.pentaho.di.core.exception.KettleException - if any errors occur during the dispatch to the slave serverpublic boolean isReadyToStart()
prepareExecution(String[])public void setInternalKettleVariables(org.pentaho.di.core.variables.VariableSpace var)
var - the new internal kettle variablespublic void copyVariablesFrom(org.pentaho.di.core.variables.VariableSpace space)
copyVariablesFrom in interface org.pentaho.di.core.variables.VariableSpacespace - the variable spaceVariableSpace.copyVariablesFrom(org.pentaho.di.core.variables.VariableSpace)public String environmentSubstitute(String aString)
environmentSubstitute in interface org.pentaho.di.core.variables.VariableSpaceaString - the string to resolve against environment variablesVariableSpace.environmentSubstitute(java.lang.String)public String[] environmentSubstitute(String[] aString)
environmentSubstitute in interface org.pentaho.di.core.variables.VariableSpaceaString - an array of strings to resolve against environment variablesVariableSpace.environmentSubstitute(java.lang.String[])public String fieldSubstitute(String aString, org.pentaho.di.core.row.RowMetaInterface rowMeta, Object[] rowData) throws org.pentaho.di.core.exception.KettleValueException
fieldSubstitute in interface org.pentaho.di.core.variables.VariableSpaceorg.pentaho.di.core.exception.KettleValueExceptionpublic org.pentaho.di.core.variables.VariableSpace getParentVariableSpace()
getParentVariableSpace in interface org.pentaho.di.core.variables.VariableSpaceVariableSpace.getParentVariableSpace()public void setParentVariableSpace(org.pentaho.di.core.variables.VariableSpace parent)
setParentVariableSpace in interface org.pentaho.di.core.variables.VariableSpaceparent - the new parent variable spaceVariableSpace.setParentVariableSpace(org.pentaho.di.core.variables.VariableSpace)public String getVariable(String variableName, String defaultValue)
getVariable in interface org.pentaho.di.core.variables.VariableSpacevariableName - the variable namedefaultValue - the default valueVariableSpace.getVariable(java.lang.String, java.lang.String)public String getVariable(String variableName)
getVariable in interface org.pentaho.di.core.variables.VariableSpacevariableName - the variable nameVariableSpace.getVariable(java.lang.String)public boolean getBooleanValueOfVariable(String variableName, boolean defaultValue)
getBooleanValueOfVariable in interface org.pentaho.di.core.variables.VariableSpacevariableName - the variable namedefaultValue - the default valueVariableSpace.getBooleanValueOfVariable(java.lang.String, boolean)public void initializeVariablesFrom(org.pentaho.di.core.variables.VariableSpace parent)
initializeVariablesFrom in interface org.pentaho.di.core.variables.VariableSpaceparent - the parentVariableSpace.initializeVariablesFrom(org.pentaho.di.core.variables.VariableSpace)public String[] listVariables()
listVariables in interface org.pentaho.di.core.variables.VariableSpaceVariableSpace.listVariables()public void setVariable(String variableName, String variableValue)
setVariable in interface org.pentaho.di.core.variables.VariableSpacevariableName - the variable namevariableValue - the variable valueVariableSpace.setVariable(java.lang.String, java.lang.String)public void shareVariablesWith(org.pentaho.di.core.variables.VariableSpace space)
shareVariablesWith in interface org.pentaho.di.core.variables.VariableSpacespace - the variable spaceVariableSpace.shareVariablesWith(org.pentaho.di.core.variables.VariableSpace)public void injectVariables(Map<String,String> prop)
injectVariables in interface org.pentaho.di.core.variables.VariableSpaceprop - the property mapVariableSpace.injectVariables(java.util.Map)public void pauseRunning()
public void resumeRunning()
public boolean isPreview()
public void setPreview(boolean preview)
preview - true if the transformation is being previewed, false otherwisepublic Repository getRepository()
public void setRepository(Repository repository)
repository - the repository object to setpublic Map<String,List<StepPerformanceSnapShot>> getStepPerformanceSnapShots()
public void setStepPerformanceSnapShots(Map<String,List<StepPerformanceSnapShot>> stepPerformanceSnapShots)
stepPerformanceSnapShots - a named list (map) of step performance snapshots to setpublic List<TransListener> getTransListeners()
public void setTransListeners(List<TransListener> transListeners)
transListeners - the transListeners to setpublic void addTransListener(TransListener transListener)
transListener - the trans listenerpublic void setTransStoppedListeners(List<TransStoppedListener> transStoppedListeners)
transStoppedListeners - the list of stop-event listeners to setpublic List<TransStoppedListener> getTransStoppedListeners()
public void addTransStoppedListener(TransStoppedListener transStoppedListener)
transStoppedListener - the stop-event listener to addpublic boolean isPaused()
public boolean isStopped()
public static void monitorRemoteTransformation(org.pentaho.di.core.logging.LogChannelInterface log,
String carteObjectId,
String transName,
SlaveServer remoteSlaveServer)
log - the log channel interfacecarteObjectId - the Carte object IDtransName - the transformation nameremoteSlaveServer - the remote slave serverpublic static void monitorRemoteTransformation(org.pentaho.di.core.logging.LogChannelInterface log,
String carteObjectId,
String transName,
SlaveServer remoteSlaveServer,
int sleepTimeSeconds)
log - the log channel interfacecarteObjectId - the Carte object IDtransName - the transformation nameremoteSlaveServer - the remote slave serversleepTimeSeconds - the sleep time (in seconds)public void addParameterDefinition(String key, String defValue, String description) throws org.pentaho.di.core.parameters.DuplicateParamException
addParameterDefinition in interface org.pentaho.di.core.parameters.NamedParamskey - the name of the parameterdefValue - the default value for the parameterdescription - the description of the parameterorg.pentaho.di.core.parameters.DuplicateParamException - the duplicate param exceptionNamedParams.addParameterDefinition(java.lang.String, java.lang.String, java.lang.String)public String getParameterDefault(String key) throws org.pentaho.di.core.parameters.UnknownParamException
getParameterDefault in interface org.pentaho.di.core.parameters.NamedParamskey - the name of the parameterorg.pentaho.di.core.parameters.UnknownParamException - if the parameter does not existNamedParams.getParameterDefault(java.lang.String)public String getParameterDescription(String key) throws org.pentaho.di.core.parameters.UnknownParamException
getParameterDescription in interface org.pentaho.di.core.parameters.NamedParamskey - the name of the parameterorg.pentaho.di.core.parameters.UnknownParamException - if the parameter does not existNamedParams.getParameterDescription(java.lang.String)public String getParameterValue(String key) throws org.pentaho.di.core.parameters.UnknownParamException
getParameterValue in interface org.pentaho.di.core.parameters.NamedParamskey - the name of the parameterorg.pentaho.di.core.parameters.UnknownParamException - if the parameter does not existNamedParams.getParameterValue(java.lang.String)public String[] listParameters()
listParameters in interface org.pentaho.di.core.parameters.NamedParamsNamedParams.listParameters()public void setParameterValue(String key, String value) throws org.pentaho.di.core.parameters.UnknownParamException
setParameterValue in interface org.pentaho.di.core.parameters.NamedParamskey - the name of the parametervalue - the name of the valueorg.pentaho.di.core.parameters.UnknownParamException - if the parameter does not existNamedParams.setParameterValue(java.lang.String, java.lang.String)public void eraseParameters()
eraseParameters in interface org.pentaho.di.core.parameters.NamedParamsNamedParams.eraseParameters()public void clearParameters()
clearParameters in interface org.pentaho.di.core.parameters.NamedParamsNamedParams.clearParameters()public void activateParameters()
activateParameters in interface org.pentaho.di.core.parameters.NamedParamsNamedParams.activateParameters()public void copyParametersFrom(org.pentaho.di.core.parameters.NamedParams params)
copyParametersFrom in interface org.pentaho.di.core.parameters.NamedParamsparams - the NamedParams object from which to copy the parametersNamedParams.copyParametersFrom(org.pentaho.di.core.parameters.NamedParams)public Trans getParentTrans()
public void setParentTrans(Trans parentTrans)
parentTrans - the parentTrans to setpublic String getMappingStepName()
public void setMappingStepName(String mappingStepName)
mappingStepName - the name of the mapping step that created this transformationpublic void setSocketRepository(SocketRepository socketRepository)
socketRepository - the new socket repositorypublic SocketRepository getSocketRepository()
public String getObjectName()
getObjectName in interface org.pentaho.di.core.logging.LoggingObjectInterfaceLoggingObjectInterface.getObjectName()public String getObjectCopy()
getObjectCopy in interface org.pentaho.di.core.logging.LoggingObjectInterfaceLoggingObjectInterface.getObjectCopy()public String getFilename()
getFilename in interface org.pentaho.di.core.logging.LoggingObjectInterfaceLoggingObjectInterface.getFilename()public String getLogChannelId()
getLogChannelId in interface org.pentaho.di.core.logging.LoggingObjectInterfaceLoggingObjectInterface.getLogChannelId()public org.pentaho.di.repository.ObjectId getObjectId()
getObjectId in interface org.pentaho.di.core.logging.LoggingObjectInterfaceLoggingObjectInterface.getObjectId()public org.pentaho.di.repository.ObjectRevision getObjectRevision()
getObjectRevision in interface org.pentaho.di.core.logging.LoggingObjectInterfaceLoggingObjectInterface.getObjectRevision()public org.pentaho.di.core.logging.LoggingObjectType getObjectType()
getObjectType in interface org.pentaho.di.core.logging.LoggingObjectInterfaceLoggingObjectInterface.getObjectType()public org.pentaho.di.core.logging.LoggingObjectInterface getParent()
getParent in interface org.pentaho.di.core.logging.LoggingObjectInterfaceLoggingObjectInterface.getParent()public org.pentaho.di.repository.RepositoryDirectoryInterface getRepositoryDirectory()
getRepositoryDirectory in interface org.pentaho.di.core.logging.LoggingObjectInterfaceLoggingObjectInterface.getRepositoryDirectory()public org.pentaho.di.core.logging.LogLevel getLogLevel()
getLogLevel in interface org.pentaho.di.core.logging.LoggingObjectInterfaceLoggingObjectInterface.getLogLevel()public void setLogLevel(org.pentaho.di.core.logging.LogLevel logLevel)
logLevel - the new log levelpublic List<org.pentaho.di.core.logging.LoggingHierarchy> getLoggingHierarchy()
public Map<String,Trans> getActiveSubtransformations()
public Map<String,Job> getActiveSubjobs()
public String getContainerObjectId()
getContainerObjectId in interface org.pentaho.di.core.logging.LoggingObjectInterfacepublic void setContainerObjectId(String containerObjectId)
containerObjectId - the Carte object ID to setpublic Date getRegistrationDate()
getRegistrationDate in interface org.pentaho.di.core.logging.LoggingObjectInterfacepublic void setServletPrintWriter(PrintWriter servletPrintWriter)
servletPrintWriter - the new servlet print writerpublic PrintWriter getServletPrintWriter()
public String getExecutingServer()
getExecutingServer in interface ExecutorInterfacepublic void setExecutingServer(String executingServer)
setExecutingServer in interface ExecutorInterfaceexecutingServer - the executingServer to setpublic String getExecutingUser()
getExecutingUser in interface ExecutorInterfacepublic void setExecutingUser(String executingUser)
setExecutingUser in interface ExecutorInterfaceexecutingUser - the executingUser to setpublic boolean isGatheringMetrics()
isGatheringMetrics in interface org.pentaho.di.core.logging.LoggingObjectInterfacepublic void setGatheringMetrics(boolean gatheringMetrics)
setGatheringMetrics in interface org.pentaho.di.core.logging.LoggingObjectInterfacepublic boolean isForcingSeparateLogging()
isForcingSeparateLogging in interface org.pentaho.di.core.logging.LoggingObjectInterfacepublic void setForcingSeparateLogging(boolean forcingSeparateLogging)
setForcingSeparateLogging in interface org.pentaho.di.core.logging.LoggingObjectInterfacepublic List<org.pentaho.di.core.ResultFile> getResultFiles()
public void setResultFiles(List<org.pentaho.di.core.ResultFile> resultFiles)
public List<org.pentaho.di.core.RowMetaAndData> getResultRows()
public void setResultRows(List<org.pentaho.di.core.RowMetaAndData> resultRows)
public org.pentaho.di.core.Result getPreviousResult()
public void setPreviousResult(org.pentaho.di.core.Result previousResult)
public String[] getArguments()
public void setArguments(String[] arguments)
public void clearError()
public String getTransactionId()
public void setTransactionId(String transactionId)
transactionId - the transactionId to setpublic String calculateTransactionId()
public org.pentaho.metastore.api.IMetaStore getMetaStore()
public void setMetaStore(org.pentaho.metastore.api.IMetaStore metaStore)
public void setServletReponse(javax.servlet.http.HttpServletResponse response)
public javax.servlet.http.HttpServletResponse getServletResponse()
public void setServletRequest(javax.servlet.http.HttpServletRequest request)
public javax.servlet.http.HttpServletRequest getServletRequest()
public List<DelegationListener> getDelegationListeners()
public void setDelegationListeners(List<DelegationListener> delegationListeners)
public void addDelegationListener(DelegationListener delegationListener)
public void doTopologySortOfSteps()