Class TransWebSocketEngineAdapter
- java.lang.Object
-
- org.pentaho.di.trans.Trans
-
- org.pentaho.di.trans.ael.websocket.TransWebSocketEngineAdapter
-
- All Implemented Interfaces:
ExecutorInterface,org.pentaho.di.core.ExtensionDataInterface,HasLogChannelInterface,org.pentaho.di.core.logging.LoggingObjectInterface,org.pentaho.di.core.logging.LoggingObjectLifecycleInterface,org.pentaho.di.core.parameters.NamedParams,org.pentaho.di.core.variables.VariableSpace
public class TransWebSocketEngineAdapter extends Trans
Created by fcamara on 8/17/17.
-
-
Field Summary
Fields Modifier and Type Field Description protected MessageEventServicemessageEventService-
Fields inherited from class org.pentaho.di.trans.Trans
arguments, class_nr, CONFIGURATION_IN_EXPORT_FILENAME, containerObjectId, counters, log, logCommitSize, metaStore, REPLAY_DATE_FORMAT, repository, resultFiles, resultRows, rowsets, STRING_FINISHED, STRING_FINISHED_WITH_ERRORS, STRING_HALTING, STRING_INITIALIZING, STRING_PAUSED, STRING_PREPARING, STRING_RUNNING, STRING_STOPPED, STRING_STOPPED_WITH_ERRORS, STRING_WAITING, transMeta, TYPE_DISP_1_1, TYPE_DISP_1_N, TYPE_DISP_N_1, TYPE_DISP_N_M, TYPE_DISP_N_N
-
-
Constructor Summary
Constructors Constructor Description TransWebSocketEngineAdapter(TransMeta transMeta, String host, int port, boolean ssl)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RowProduceraddRowProducer(String stepname, int copynr)This adds a row producer to the transformation that just got set up.voidcloseSessionMonitor()voidfinishProcess(boolean emitToAllSteps)DaemonMessagesClientEndpointgetDaemonEndpoint()intgetErrors()Gets the number of errors that have occurred during execution of the transformation.org.pentaho.di.core.ResultgetResult()Gets the result of the transformation.voidkillAll()Attempts to stops all running steps and subtransformations.voidprepareExecution(String[] arguments)Prepares the transformation for execution.voidsafeStop()Stops only input steps so that all downstream steps can finish processing rows that have already been inputvoidsetLogLevel(org.pentaho.di.core.logging.LogLevel logLogLevel)Sets the log level.voidstartThreads()Starts the threads prepared by prepareThreads().voidstopAll()Stops all steps from running, and alerts any registered listeners.voidwaitUntilFinished()Waits until all RunThreads have finished.-
Methods inherited from class org.pentaho.di.trans.Trans
activateParameters, addActiveSubTransformation, addDelegationListener, addParameterDefinition, addStepPerformanceSnapShot, addTransListener, addTransStoppedListener, beginProcessing, calculateBatchIdAndDateRange, calculateTransactionId, callAfterLog, callBeforeLog, cleanup, cleanupCluster, cleanupSlaveServer, clearError, clearParameters, copyParametersFrom, copyVariablesFrom, createDataBase, doTopologySortOfSteps, environmentSubstitute, environmentSubstitute, eraseParameters, execute, executeClustered, executeClustered, fieldSubstitute, findBaseSteps, findDataInterface, findMappingInput, findMappingOutput, findRowSet, findRowSet, findRunThread, findStepInterface, findStepInterfaces, fireTransFinishedListeners, fireTransStartedListeners, getActiveSubjobs, getActiveSubTransformation, getActiveSubtransformations, getArguments, getBatchId, getBooleanValueOfVariable, getClusteredTransformationResult, getClusteredTransformationResult, getContainerObjectId, getCounters, getCurrentDate, getDelegationListeners, getDepDate, getEndDate, getEnded, getExecutingServer, getExecutingUser, getExtensionDataMap, getFilename, getJobEndDate, getJobStartDate, getLastProcessed, getLogChannel, getLogChannelId, getLogDate, getLoggingHierarchy, getLogLevel, getMappingStepName, getMetaStore, getName, getObjectCopy, getObjectId, getObjectName, getObjectRevision, getObjectType, getParameterDefault, getParameterDescription, getParameterValue, getParent, getParentJob, getParentTrans, getParentVariableSpace, getPassedBatchId, getPreviousResult, getRegistrationDate, getReplayDate, getRepository, getRepositoryDirectory, getResultFiles, getResultRows, getRowsets, getRunThread, getRunThread, getServletPrintWriter, getServletRequest, getServletResponse, getSocketRepository, getStartDate, getStatus, getStepDataInterface, getStepInterface, getStepPerformanceSnapShots, getSteps, getThreadName, getTransactionId, getTransListeners, getTransMeta, getTransStepExecutionStatusLookup, getTransStepIsRunningLookup, getTransStoppedListeners, getVariable, getVariable, hasHaltedSteps, hasStepStarted, initializeVariablesFrom, injectVariables, isExecutingClustered, isFinished, isFinishedOrStopped, isForcingSeparateLogging, isGatheringMetrics, isInitializing, isMonitored, isPaused, isPreparing, isPreview, isReadyToStart, isResultRowsSet, isRunning, isSafeModeEnabled, isStopped, listParameters, listVariables, logSummary, mergeParametersWith, monitorClusteredTransformation, monitorClusteredTransformation, monitorRemoteTransformation, monitorRemoteTransformation, notifyStoppedListeners, nrActiveSteps, nrSteps, pauseRunning, printStats, removeActiveSubTransformation, resumeRunning, sendToSlaveServer, setArguments, setBatchId, setContainerObjectId, setCounters, setDelegationListeners, setExecutingClustered, setExecutingServer, setExecutingUser, setFinished, setForcingSeparateLogging, setGatheringMetrics, setInitializing, setInternalEntryCurrentDirectory, setInternalKettleVariables, setJobEndDate, setJobStartDate, setLog, setMappingStepName, setMetaStore, setMonitored, setParameterValue, setParent, setParentJob, setParentTrans, setParentVariableSpace, setPassedBatchId, setPaused, setPreparing, setPreview, setPreviousResult, setReadyToStart, setReplayDate, setRepository, setResultFiles, setResultRows, setResultRowSet, setRunning, setSafeModeEnabled, setServletPrintWriter, setServletReponse, setServletRequest, setSocketRepository, setStepPerformanceSnapShots, setSteps, setStopped, setThreadName, setTransactionId, setTransListeners, setTransMeta, setTransStoppedListeners, setVariable, shareVariablesWith, shutdownHeartbeat, startHeartbeat, stopStep, toString, writeLogChannelInformation, writeMetricsInformation, writeStepLogInformation
-
-
-
-
Field Detail
-
messageEventService
protected final MessageEventService messageEventService
-
-
Method Detail
-
getDaemonEndpoint
public DaemonMessagesClientEndpoint getDaemonEndpoint() throws org.pentaho.di.core.exception.KettleException
- Throws:
org.pentaho.di.core.exception.KettleException
-
setLogLevel
public void setLogLevel(org.pentaho.di.core.logging.LogLevel logLogLevel)
Description copied from class:TransSets the log level.- Overrides:
setLogLevelin classTrans- Parameters:
logLogLevel- the new log level
-
killAll
public void killAll()
Description copied from class:TransAttempts to stops all running steps and subtransformations. If all steps have finished, the transformation is marked as Finished.
-
stopAll
public void stopAll()
Description copied from class:TransStops all steps from running, and alerts any registered listeners.
-
safeStop
public void safeStop()
Description copied from class:TransStops only input steps so that all downstream steps can finish processing rows that have already been input
-
prepareExecution
public void prepareExecution(String[] arguments) throws org.pentaho.di.core.exception.KettleException
Description copied from class:TransPrepares the transformation for execution. This includes setting the arguments and parameters as well as preparing and tracking the steps and hops in the transformation.- Overrides:
prepareExecutionin classTrans- Parameters:
arguments- the arguments to use for this transformation- Throws:
org.pentaho.di.core.exception.KettleException- in case the transformation could not be prepared (initialized)
-
startThreads
public void startThreads() throws org.pentaho.di.core.exception.KettleExceptionDescription copied from class:TransStarts the threads prepared by prepareThreads(). Before you start the threads, you can add RowListeners to them.- Overrides:
startThreadsin classTrans- Throws:
org.pentaho.di.core.exception.KettleException- if there is a communication error with a remote output socket.
-
closeSessionMonitor
public void closeSessionMonitor()
-
waitUntilFinished
public void waitUntilFinished()
Description copied from class:TransWaits until all RunThreads have finished.- Overrides:
waitUntilFinishedin classTrans
-
getErrors
public int getErrors()
Description copied from class:TransGets the number of errors that have occurred during execution of the transformation.
-
getResult
public org.pentaho.di.core.Result getResult()
Description copied from class:TransGets the result of the transformation. The Result object contains such measures as the number of errors, number of lines read/written/input/output/updated/rejected, etc.
-
finishProcess
public void finishProcess(boolean emitToAllSteps)
-
addRowProducer
public RowProducer addRowProducer(String stepname, int copynr) throws org.pentaho.di.core.exception.KettleException
Description copied from class:TransThis adds a row producer to the transformation that just got set up. It is preferable to run this BEFORE execute() but after prepareExecution()- Overrides:
addRowProducerin classTrans- Parameters:
stepname- The step to produce rows forcopynr- The copynr of the step to produce row for (normally 0 unless you have multiple copies running)- Returns:
- the row producer
- Throws:
org.pentaho.di.core.exception.KettleException- in case the thread/step to produce rows for could not be found.- See Also:
Trans.execute(String[]),Trans.prepareExecution(String[])
-
-