code
stringlengths
23
201k
docstring
stringlengths
17
96.2k
func_name
stringlengths
0
235
language
stringclasses
1 value
repo
stringlengths
8
72
path
stringlengths
11
317
url
stringlengths
57
377
license
stringclasses
7 values
private void configureJobLevelMetrics(final JobRunner jobRunner) { this.logger.info("Configuring Azkaban metrics tracking for jobrunner object"); if (MetricReportManager.isAvailable()) { final MetricReportManager metricManager = MetricReportManager.getInstance(); // Adding NumRunningJobMetric liste...
Configure Azkaban metrics tracking for a new jobRunner instance
configureJobLevelMetrics
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public void pause(final String user) throws IllegalStateException { synchronized (this.mainSyncObj) { this.logger.info("Execution pause requested by " + user); if (!this.isKilled() && !this.flowFinished) { this.flowPaused = true; this.flow.setStatus(Status.PAUSED); // Record the ...
Configure Azkaban metrics tracking for a new jobRunner instance
pause
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public void resume(final String user) { synchronized (this.mainSyncObj) { if (!this.flowPaused) { this.logger.info("Cannot resume flow that isn't paused"); } else { this.logger.info("Flow resumed by " + user); this.flowPaused = false; if (this.flowFailed) { this...
Configure Azkaban metrics tracking for a new jobRunner instance
resume
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public void kill(final String user) { this.logger.info("Flow killed by " + user); this.getExecutableFlow().setModifiedBy(user); kill(); }
Configure Azkaban metrics tracking for a new jobRunner instance
kill
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public void kill() { synchronized (this.mainSyncObj) { if (isKilled() || this.flowFinished) { this.logger.info( "Dropping Kill action as execution " + this.execId + " is already finished."); return; } this.logger.info("Kill has been called on execution " + this.execId);...
Configure Azkaban metrics tracking for a new jobRunner instance
kill
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public void retryFailures(final String user) { synchronized (this.mainSyncObj) { this.logger.info("Retrying failures invoked by " + user); this.retryFailedJobs = true; interrupt(); } }
Configure Azkaban metrics tracking for a new jobRunner instance
retryFailures
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
private void resetFailedState(final ExecutableFlowBase flow, final List<ExecutableNode> nodesToRetry) { // bottom up final LinkedList<ExecutableNode> queue = new LinkedList<>(); for (final String id : flow.getEndNodes()) { final ExecutableNode node = flow.getExecutableNode(id); queue.add(n...
Configure Azkaban metrics tracking for a new jobRunner instance
resetFailedState
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
private void interrupt() { if (this.flowRunnerThread != null) { this.flowRunnerThread.interrupt(); } }
Configure Azkaban metrics tracking for a new jobRunner instance
interrupt
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public boolean isKilled() { return this.flowKilled; }
Configure Azkaban metrics tracking for a new jobRunner instance
isKilled
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public boolean isRamping() { return this.flowIsRamping; }
Configure Azkaban metrics tracking for a new jobRunner instance
isRamping
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public ExecutableFlow getExecutableFlow() { return this.flow; }
Configure Azkaban metrics tracking for a new jobRunner instance
getExecutableFlow
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public File getFlowLogFile() { return this.logFile; }
Configure Azkaban metrics tracking for a new jobRunner instance
getFlowLogFile
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public File getJobLogFile(final String jobId, final int attempt) { final ExecutableNode node = this.flow.getExecutableNodePath(jobId); final File path = new File(this.execDir, node.getJobSource()); final String logFileName = JobRunner.createLogFileName(node, attempt); final File logFile = new File(path...
Configure Azkaban metrics tracking for a new jobRunner instance
getJobLogFile
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public File getJobAttachmentFile(final String jobId, final int attempt) { final ExecutableNode node = this.flow.getExecutableNodePath(jobId); final File path = new File(this.execDir, node.getJobSource()); final String attachmentFileName = JobRunner.createAttachmentFileName(node, attempt); final...
Configure Azkaban metrics tracking for a new jobRunner instance
getJobAttachmentFile
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public File getJobMetaDataFile(final String jobId, final int attempt) { final ExecutableNode node = this.flow.getExecutableNodePath(jobId); final File path = new File(this.execDir, node.getJobSource()); final String metaDataFileName = JobRunner.createMetaDataFileName(node, attempt); final File metaData...
Configure Azkaban metrics tracking for a new jobRunner instance
getJobMetaDataFile
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
@VisibleForTesting protected boolean isRunnerThreadShutdown() { return this.flowRunnerThread != null && !this.flowRunnerThread.isAlive(); }
Configure Azkaban metrics tracking for a new jobRunner instance
isRunnerThreadShutdown
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public int getExecutionId() { return this.execId; }
Configure Azkaban metrics tracking for a new jobRunner instance
getExecutionId
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public Set<JobRunner> getActiveJobRunners() { return ImmutableSet.copyOf(this.activeJobRunners); }
Configure Azkaban metrics tracking for a new jobRunner instance
getActiveJobRunners
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public FlowRunnerEventListener getFlowRunnerEventListener() { return this.flowListener; }
Configure Azkaban metrics tracking for a new jobRunner instance
getFlowRunnerEventListener
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public void setEffectiveUser(final String jobId, final String effectiveUser, final Optional<String> jobType) { if (StringUtils.isBlank(jobId)) { logger.error("Job effective user can't be set as jobId string is blank."); return; } if (StringUtils.isBlank(effectiveUser)) { ...
@param jobId @param effectiveUser @param jobType
setEffectiveUser
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public void setCpuUtilization(final Double cpuUtilized) { FlowRunner.this.cpuUtilized = Optional.ofNullable(cpuUtilized); }
@param cpuUtilized measured in cpu Units. One cpu is equivalent to 1 vCPU/Core for cloud providers and 1 hyperthread on bare-metal Intel processors. Fractional values are allowed.
setCpuUtilization
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public void setMemoryUtilization(final Long memoryUtilizedInBytes) { FlowRunner.this.memoryUtilizedInBytes = Optional.ofNullable(memoryUtilizedInBytes); }
@param memoryUtilizedInBytes by the Azkaban flow.
setMemoryUtilization
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
@VisibleForTesting synchronized Map<String, String> getFlowMetadata(final FlowRunner flowRunner, final ExecutableFlowBase flow) { final ExecutableFlow rootFlow = flowRunner.getExecutableFlow(); final Props props = ServiceProvider.SERVICE_PROVIDER.getInstance(Props.class); final Map<String,...
@param memoryUtilizedInBytes by the Azkaban flow.
getFlowMetadata
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
@Override public synchronized void handleEvent(final Event event) { if (event.getType().isFlowEventType()) { final FlowRunner flowRunner = (FlowRunner) event.getRunner(); final ExecutableFlow rootFlow = flowRunner.getExecutableFlow(); final ExecutableFlowBase flow = (ExecutableFlowBase...
@param memoryUtilizedInBytes by the Azkaban flow.
handleEvent
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
@VisibleForTesting static void propagateMetadataFromProps(final Map<String, String> metaData, final Props inputProps, final String nodeType, final String nodeName, final Logger logger) { if (null == metaData || null == inputProps || null == logger || Strings.isNullOrEmpty(nodeType) || Strings.isNul...
Propagate properties (specified in {@code AZKABAN_EVENT_REPORTING_PROPERTIES_TO_PROPAGATE}) to metadata for event reporting. @param metaData Metadata map to update with properties. @param inputProps Input properties for flow or job. @param nodeType Flow or job. @param nodeName Flow or job name. @param logger Logger fro...
propagateMetadataFromProps
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunner.java
Apache-2.0
public boolean changePollingInterval(final long pollingIntervalMillis) { final long oldVal = this.azkabanProps.getLong(ConfigurationKeys.AZKABAN_POLLING_INTERVAL_MS, Constants.DEFAULT_AZKABAN_POLLING_INTERVAL_MS); if (!this.pollingService.restart(pollingIntervalMillis)) { return false; } ...
Change the polling interval to the newly specified value and also update the value that's specified in the props @param pollingIntervalMillis The new polling interval. @return true if the Polling interval has changed successfully
changePollingInterval
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private void addStartupDependencyPathToProps(final Props props) { if (this.storage.getDependencyRootPath() != null) { props.put(ThinArchiveUtils.DEPENDENCY_STORAGE_ROOT_PATH_PROP, this.storage.getDependencyRootPath()); } }
Add the startup dependency path to props if the current storage instance returns a non-null dependencyRootPath. @param props Props to add the startup dependency path to.
addStartupDependencyPathToProps
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private void setgidPermissionOnExecutionDirectory() throws IOException { LOGGER.info("Creating subprocess to run shell command: chmod g+s " + this.executionDirectory.toString()); Runtime.getRuntime().exec("chmod g+s " + this.executionDirectory.toString()); }
Setting the gid bit on the execution directory forces all files/directories created within the directory to be a part of the group associated with the azkaban process. Then, when users create their own files, the azkaban cleanup thread can properly remove them. <p> Java does not provide a standard library api for setti...
setgidPermissionOnExecutionDirectory
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private TrackingThreadPool createExecutorService(final int nThreads) { final boolean useNewThreadPool = this.azkabanProps.getBoolean(EXECUTOR_USE_BOUNDED_THREADPOOL_QUEUE, false); LOGGER.info("useNewThreadPool: " + useNewThreadPool); if (useNewThreadPool) { this.threadPoolQueueSize = ...
Setting the gid bit on the execution directory forces all files/directories created within the directory to be a part of the group associated with the azkaban process. Then, when users create their own files, the azkaban cleanup thread can properly remove them. <p> Java does not provide a standard library api for setti...
createExecutorService
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public void setExecutorActive(final boolean isActive, final String host, final int port) throws ExecutorManagerException, InterruptedException { final Executor executor = this.executorLoader.fetchExecutor(host, port); Preconditions.checkState(executor != null, "Unable to obtain self entry in DB"); if ...
Setting the gid bit on the execution directory forces all files/directories created within the directory to be a part of the group associated with the azkaban process. Then, when users create their own files, the azkaban cleanup thread can properly remove them. <p> Java does not provide a standard library api for setti...
setExecutorActive
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public void setActiveInternal(final boolean isActive) { this.active = isActive; }
Setting the gid bit on the execution directory forces all files/directories created within the directory to be a part of the group associated with the azkaban process. Then, when users create their own files, the azkaban cleanup thread can properly remove them. <p> Java does not provide a standard library api for setti...
setActiveInternal
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private void waitUntilFlowPreparationFinish() throws InterruptedException { final Duration SLEEP_INTERVAL = Duration.ofSeconds(5); while (this.preparingFlowCount.intValue() != 0) { LOGGER.info(this.preparingFlowCount + " flow(s) is/are still being setup before complete " + "deactivation."); ...
Wait until ongoing flow preparation work finishes.
waitUntilFlowPreparationFinish
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public long getLastFlowSubmittedTime() { // Note: this is not thread safe and may result in providing dirty data. // we will provide this data as is for now and will revisit if there // is a string justification for change. return this.lastFlowSubmittedDate; }
Wait until ongoing flow preparation work finishes.
getLastFlowSubmittedTime
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public Props getGlobalProps() { return this.globalProps; }
Wait until ongoing flow preparation work finishes.
getGlobalProps
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public void setGlobalProps(final Props globalProps) { this.globalProps = globalProps; }
Wait until ongoing flow preparation work finishes.
setGlobalProps
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public void submitFlow(final int execId) throws ExecutorManagerException { if (isAlreadyRunning(execId)) { return; } final FlowRunner runner = createFlowRunner(execId); // Check again. if (isAlreadyRunning(execId)) { return; } submitFlowRunner(runner); }
Wait until ongoing flow preparation work finishes.
submitFlow
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private boolean isAlreadyRunning(final int execId) throws ExecutorManagerException { if (this.runningFlows.containsKey(execId)) { LOGGER.info("Execution " + execId + " is already in running."); if (!this.submittedFlows.containsValue(execId)) { // Execution had been added to running flows but not...
Wait until ongoing flow preparation work finishes.
isAlreadyRunning
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private boolean isExecutorSpecified(final ExecutableFlow flow) { return flow.getExecutionOptions().getFlowParameters() .containsKey(ExecutionOptions.USE_EXECUTOR); }
return whether this execution has useExecutor defined. useExecutor is for running test executions on inactive executor.
isExecutorSpecified
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private FlowRunner createFlowRunner(final int execId) throws ExecutorManagerException { final ExecutableFlow flow = this.executorLoader.fetchExecutableFlow(execId); if (flow == null) { throw new ExecutorManagerException("Error loading flow with exec " + execId); } // Sets up the project files and...
return whether this execution has useExecutor defined. useExecutor is for running test executions on inactive executor.
createFlowRunner
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private void submitFlowRunner(final FlowRunner runner) throws ExecutorManagerException { this.runningFlows.put(runner.getExecutionId(), runner); try { // The executorService already has a queue. // The submit method below actually returns an instance of FutureTask, // which implements interfac...
return whether this execution has useExecutor defined. useExecutor is for running test executions on inactive executor.
submitFlowRunner
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private void configureFlowLevelMetrics(final FlowRunner flowRunner) { LOGGER.info("Configuring Azkaban metrics tracking for flow runner object"); if (MetricReportManager.isAvailable()) { final MetricReportManager metricManager = MetricReportManager.getInstance(); // Adding NumFailedFlow Metric list...
Configure Azkaban metrics tracking for a new flowRunner instance
configureFlowLevelMetrics
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
@Override public void cancelJobBySLA(final int execId, final String jobId) throws ExecutorManagerException { final FlowRunner flowRunner = this.runningFlows.get(execId); if (flowRunner == null) { throw new ExecutorManagerException("Execution " + execId + " is not running."); } ...
Configure Azkaban metrics tracking for a new flowRunner instance
cancelJobBySLA
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
@Override public void cancelFlow(final int execId, final String user) throws ExecutorManagerException { final FlowRunner flowRunner = this.runningFlows.get(execId); if (flowRunner == null) { throw new ExecutorManagerException("Execution " + execId + " is not running."); } // account for ...
Configure Azkaban metrics tracking for a new flowRunner instance
cancelFlow
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
@Override public void pauseFlow(final int execId, final String user) throws ExecutorManagerException { final FlowRunner runner = this.runningFlows.get(execId); if (runner == null) { throw new ExecutorManagerException("Execution " + execId + " is not running."); } try { ru...
Configure Azkaban metrics tracking for a new flowRunner instance
pauseFlow
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
@Override public void resumeFlow(final int execId, final String user) throws ExecutorManagerException { final FlowRunner runner = this.runningFlows.get(execId); if (runner == null) { throw new ExecutorManagerException("Execution " + execId + " is not running."); } runner.resume...
Configure Azkaban metrics tracking for a new flowRunner instance
resumeFlow
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
@Override public void retryFailures(final int execId, final String user) throws ExecutorManagerException { final FlowRunner flowRunner = this.runningFlows.get(execId); if (flowRunner == null) { throw new ExecutorManagerException("Execution " + execId + " is not running."); } fl...
Configure Azkaban metrics tracking for a new flowRunner instance
retryFailures
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public ExecutableFlow getExecutableFlow(final int execId) { final FlowRunner runner = this.runningFlows.get(execId); if (runner == null) { return this.recentlyFinishedFlows.get(execId); } return runner.getExecutableFlow(); }
Configure Azkaban metrics tracking for a new flowRunner instance
getExecutableFlow
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private void deleteExecutionDir(final int executionId) { LOGGER.info("Deleting execution directory for " + executionId); synchronized (this.executionDirDeletionSync) { LOGGER.info("Starting execution directory deletion for " + executionId); final Path flowExecutionDir = Paths.get(this.executionDirec...
delete execution dir pertaining to the given execution id
deleteExecutionDir
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
@Override public void handleEvent(final Event event) { if (!(event.getData().isRootFlowEvent())) { return; } if (event.getType() == EventType.FLOW_FINISHED || event.getType() == EventType.FLOW_STARTED) { final FlowRunner flowRunner = (FlowRunner) event.getRunner(); final ExecutableFlow f...
delete execution dir pertaining to the given execution id
handleEvent
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public LogData readFlowLogs(final int execId, final int startByte, final int length) throws ExecutorManagerException { final FlowRunner runner = this.runningFlows.get(execId); if (runner == null) { throw new ExecutorManagerException("Running flow " + execId + " not found."); } fin...
delete execution dir pertaining to the given execution id
readFlowLogs
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public LogData readJobLogs(final int execId, final String jobId, final int attempt, final int startByte, final int length) throws ExecutorManagerException { final FlowRunner runner = this.runningFlows.get(execId); if (runner == null) { throw new ExecutorManagerException("Running flow " + execId ...
delete execution dir pertaining to the given execution id
readJobLogs
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public List<Object> readJobAttachments(final int execId, final String jobId, final int attempt) throws ExecutorManagerException { final FlowRunner runner = this.runningFlows.get(execId); if (runner == null) { throw new ExecutorManagerException("Running flow " + execId + " not found."); ...
delete execution dir pertaining to the given execution id
readJobAttachments
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public JobMetaData readJobMetaData(final int execId, final String jobId, final int attempt, final int startByte, final int length) throws ExecutorManagerException { final FlowRunner runner = this.runningFlows.get(execId); if (runner == null) { throw new ExecutorManagerException("Running flow " + exe...
delete execution dir pertaining to the given execution id
readJobMetaData
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public long getLastCleanerThreadCheckTime() { return this.lastCleanerThreadCheckTime; }
delete execution dir pertaining to the given execution id
getLastCleanerThreadCheckTime
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public boolean isCleanerThreadActive() { return this.cleanerThread.isAlive(); }
delete execution dir pertaining to the given execution id
isCleanerThreadActive
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public State getCleanerThreadState() { return this.cleanerThread.getState(); }
delete execution dir pertaining to the given execution id
getCleanerThreadState
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public boolean isExecutorThreadPoolShutdown() { return this.executorService.isShutdown(); }
delete execution dir pertaining to the given execution id
isExecutorThreadPoolShutdown
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public int getNumQueuedFlows() { return this.executorService.getQueue().size(); }
delete execution dir pertaining to the given execution id
getNumQueuedFlows
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public int getNumRunningFlows() { return this.executorService.getActiveCount(); }
delete execution dir pertaining to the given execution id
getNumRunningFlows
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public String getRunningFlowIds() { // The in progress tasks are actually of type FutureTask final Set<Runnable> inProgressTasks = this.executorService.getInProgressTasks(); final List<Integer> runningFlowIds = new ArrayList<>(inProgressTasks.size()); for (final Runnable task : inProgressTasks...
delete execution dir pertaining to the given execution id
getRunningFlowIds
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public String getQueuedFlowIds() { final List<Integer> flowIdList = new ArrayList<>(this.executorService.getQueue().size()); for (final Runnable task : this.executorService.getQueue()) { final Integer execId = this.submittedFlows.get(task); if (execId != null) { flowIdList.add(execI...
delete execution dir pertaining to the given execution id
getQueuedFlowIds
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public int getMaxNumRunningFlows() { return this.numThreads; }
delete execution dir pertaining to the given execution id
getMaxNumRunningFlows
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public int getTheadPoolQueueSize() { return this.threadPoolQueueSize; }
delete execution dir pertaining to the given execution id
getTheadPoolQueueSize
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public int getTotalNumExecutedFlows() { return this.executorService.getTotalTasks(); }
delete execution dir pertaining to the given execution id
getTotalNumExecutedFlows
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
@Override public void beforeExecute(final Runnable r) { }
delete execution dir pertaining to the given execution id
beforeExecute
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
@Override public void afterExecute(final Runnable r) { this.submittedFlows.remove(r); }
delete execution dir pertaining to the given execution id
afterExecute
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public void shutdown() { LOGGER.warn("Shutting down FlowRunnerManager..."); if (isPollDispatchMethodEnabled()) { this.pollingService.shutdown(); } this.executorService.shutdown(); boolean result = false; while (!result) { LOGGER.info("Awaiting Shutdown. # of executing flows: " + getN...
This shuts down the flow runner. The call is blocking and awaits execution of all jobs.
shutdown
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public void shutdownNow() { LOGGER.warn("Shutting down FlowRunnerManager now..."); if (isPollDispatchMethodEnabled()) { this.pollingService.shutdown(); } this.executorService.shutdownNow(); this.triggerManager.shutdown(); }
This attempts shuts down the flow runner immediately (unsafe). This doesn't wait for jobs to finish but interrupts all threads.
shutdownNow
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private boolean isPollDispatchMethodEnabled() { return DispatchMethod.isPollMethodEnabled(this.azkabanProps .getString(ConfigurationKeys.AZKABAN_EXECUTION_DISPATCH_METHOD, DispatchMethod.PUSH.name())); }
This attempts shuts down the flow runner immediately (unsafe). This doesn't wait for jobs to finish but interrupts all threads.
isPollDispatchMethodEnabled
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public void deleteExecutionDirectory() { LOGGER.warn("Deleting execution dir: " + this.executionDirectory.getAbsolutePath()); try { FileUtils.deleteDirectory(this.executionDirectory); } catch (final IOException e) { LOGGER.error(e.getMessage()); } }
Deleting old execution directory to free disk space.
deleteExecutionDirectory
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public void shutdown() { this.shutdown = true; this.interrupt(); }
Deleting old execution directory to free disk space.
shutdown
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private boolean isFlowRunningLongerThan(final ExecutableFlow flow, final long flowMaxRunningTimeInMins) { return Status.nonFinishingStatusAfterFlowStartsSet.contains(flow.getStatus()) && flow.getStartTime() > 0 && TimeUnit.MILLISECONDS.toMinutes(System.currentTimeMillis() - flow.getSta...
Deleting old execution directory to free disk space.
isFlowRunningLongerThan
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
@Override public void run() { while (!this.shutdown) { synchronized (this) { try { FlowRunnerManager.this.lastCleanerThreadCheckTime = System.currentTimeMillis(); FlowRunnerManager.LOGGER.info("# of executing flows: " + getNumRunningFlows()); // Cleanup o...
Deleting old execution directory to free disk space.
run
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private void cleanRecentlyFinished() { final long cleanupThreshold = System.currentTimeMillis() - FlowRunnerManager.RECENTLY_FINISHED_TIME_TO_LIVE; final ArrayList<Integer> executionToKill = new ArrayList<>(); for (final ExecutableFlow flow : FlowRunnerManager.this.recentlyFinishedFlows.valu...
Deleting old execution directory to free disk space.
cleanRecentlyFinished
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public boolean restart(final long newPollingIntervalMs) { if (newPollingIntervalMs <= 0) { FlowRunnerManager.LOGGER.error(String.format("Can not set a negative polling interval: %d " + "milliseconds", newPollingIntervalMs)); return false; } if (this.futureTask != null) { ...
Cancels the existing polling schedule and starts a new one. This can be used to change the polling interval because a polling interval of an existing schedule can not be changed. @param newPollingIntervalMs The desired polling interval. @return true if a restart has happened with the new polling interval.
restart
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private void pollExecution() { if (this.executorId == -1) { if (AzkabanExecutorServer.getApp() != null) { try { final Executor executor = requireNonNull(FlowRunnerManager.this.executorLoader .fetchExecutor(AzkabanExecutorServer.getApp().getHost(), ...
Cancels the existing polling schedule and starts a new one. This can be used to change the polling interval because a polling interval of an existing schedule can not be changed. @param newPollingIntervalMs The desired polling interval. @return true if a restart has happened with the new polling interval.
pollExecution
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public void shutdown() { this.scheduler.shutdown(); this.scheduler.shutdownNow(); }
Cancels the existing polling schedule and starts a new one. This can be used to change the polling interval because a polling interval of an existing schedule can not be changed. @param newPollingIntervalMs The desired polling interval. @return true if a restart has happened with the new polling interval.
shutdown
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
public boolean shouldPoll() { if (satisfiesFlowThreadsAvailableCriteria() && satisfiesFreeMemoryCriteria() && satisfiesCpuUtilizationCriteria()) { return true; } return false; }
Cancels the existing polling schedule and starts a new one. This can be used to change the polling interval because a polling interval of an existing schedule can not be changed. @param newPollingIntervalMs The desired polling interval. @return true if a restart has happened with the new polling interval.
shouldPoll
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private boolean satisfiesFlowThreadsAvailableCriteria() { final boolean flowThreadsAvailableConfig = this.azkabanProps. getBoolean(ConfigurationKeys.AZKABAN_POLLING_CRITERIA_FLOW_THREADS_AVAILABLE, false); // allow polling if not present or configured with invalid value if (!flowThreadsAvai...
Cancels the existing polling schedule and starts a new one. This can be used to change the polling interval because a polling interval of an existing schedule can not be changed. @param newPollingIntervalMs The desired polling interval. @return true if a restart has happened with the new polling interval.
satisfiesFlowThreadsAvailableCriteria
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private boolean satisfiesFreeMemoryCriteria() { final int minFreeMemoryConfigGb = this.azkabanProps. getInt(ConfigurationKeys.AZKABAN_POLLING_CRITERIA_MIN_FREE_MEMORY_GB, 0); // allow polling if not present or configured with invalid value if (minFreeMemoryConfigGb <= 0) { return tr...
Cancels the existing polling schedule and starts a new one. This can be used to change the polling interval because a polling interval of an existing schedule can not be changed. @param newPollingIntervalMs The desired polling interval. @return true if a restart has happened with the new polling interval.
satisfiesFreeMemoryCriteria
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
private boolean satisfiesCpuUtilizationCriteria() { final double maxCpuUtilizationConfig = this.azkabanProps. getDouble(ConfigurationKeys.AZKABAN_POLLING_CRITERIA_MAX_CPU_UTILIZATION_PCT, 100); // allow polling if criteria not present or configured with invalid value if (maxCpuUtilizationCo...
Cancels the existing polling schedule and starts a new one. This can be used to change the polling interval because a polling interval of an existing schedule can not be changed. @param newPollingIntervalMs The desired polling interval. @return true if a restart has happened with the new polling interval.
satisfiesCpuUtilizationCriteria
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/FlowRunnerManager.java
Apache-2.0
@Deprecated @Override protected void doGet(final HttpServletRequest req, final HttpServletResponse resp) throws ServletException, IOException { doPost(req, resp); }
@deprecated GET available for seamless upgrade. azkaban-web now uses POST.
doGet
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JMXHttpServlet.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JMXHttpServlet.java
Apache-2.0
@Override protected void doPost(final HttpServletRequest req, final HttpServletResponse resp) throws ServletException, IOException { final Map<String, Object> ret = new HashMap<>(); if (hasParam(req, JMX_GET_MBEANS)) { ret.put("mbeans", this.server.getMBeanRegistrationManager().getMBeanNames()); ...
@deprecated GET available for seamless upgrade. azkaban-web now uses POST.
doPost
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JMXHttpServlet.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JMXHttpServlet.java
Apache-2.0
public Set<String> getPipelineWatchedJobs() { return this.pipelineJobs; }
Returns a list of jobs that this JobRunner will wait upon to finish before starting. It is only relevant if pipeline is turned on.
getPipelineWatchedJobs
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
public long getDelayStart() { return this.delayStartMs; }
Returns a list of jobs that this JobRunner will wait upon to finish before starting. It is only relevant if pipeline is turned on.
getDelayStart
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
public void setDelayStart(final long delayMS) { this.delayStartMs = delayMS; }
Returns a list of jobs that this JobRunner will wait upon to finish before starting. It is only relevant if pipeline is turned on.
setDelayStart
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
public ExecutableNode getNode() { return this.node; }
Returns a list of jobs that this JobRunner will wait upon to finish before starting. It is only relevant if pipeline is turned on.
getNode
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
public String getJobId() { return this.node.getId(); }
Returns a list of jobs that this JobRunner will wait upon to finish before starting. It is only relevant if pipeline is turned on.
getJobId
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
public String getLogFilePath() { return this.logFile == null ? null : this.logFile.getPath(); }
Returns a list of jobs that this JobRunner will wait upon to finish before starting. It is only relevant if pipeline is turned on.
getLogFilePath
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
private void createLogger() { // Create logger synchronized (logCreatorLock) { final String loggerName = System.currentTimeMillis() + "." + this.executionId + "." + this.jobId; this.logger = Logger.getLogger(loggerName); try { attachFileAppender(createFileAppen...
Returns a list of jobs that this JobRunner will wait upon to finish before starting. It is only relevant if pipeline is turned on.
createLogger
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
private void attachFileAppender(final FileAppender appender) { // If present, remove the existing file appender assert (this.jobAppender == null); this.jobAppender = appender; this.logger.addAppender(this.jobAppender); this.logger.setAdditivity(false); this.flowLogger.info("Attached file append...
Returns a list of jobs that this JobRunner will wait upon to finish before starting. It is only relevant if pipeline is turned on.
attachFileAppender
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
private FileAppender createFileAppender() throws IOException { // Set up log files final String logName = createLogFileName(this.node); this.logFile = new File(this.workingDir, logName); final String absolutePath = this.logFile.getAbsolutePath(); this.flowLogger.info("Log file path for job: " + this...
Returns a list of jobs that this JobRunner will wait upon to finish before starting. It is only relevant if pipeline is turned on.
createFileAppender
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
private void createAttachmentFile() { final String fileName = createAttachmentFileName(this.node); final File file = new File(this.workingDir, fileName); this.attachmentFileName = file.getAbsolutePath(); }
Returns a list of jobs that this JobRunner will wait upon to finish before starting. It is only relevant if pipeline is turned on.
createAttachmentFile
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
private void removeAppender(final Appender appender) { if (appender != null) { try { this.logger.removeAppender(appender); appender.close(); } catch (Exception e) { logger.error("Failed to remove appender " + appender.getName(), e); } } }
Returns a list of jobs that this JobRunner will wait upon to finish before starting. It is only relevant if pipeline is turned on.
removeAppender
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
private void closeLogger() { removeAppender(this.jobAppender); removeAppender(this.kafkaLog4jAppender); }
Returns a list of jobs that this JobRunner will wait upon to finish before starting. It is only relevant if pipeline is turned on.
closeLogger
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
private void writeStatus() { try { this.node.setUpdateTime(System.currentTimeMillis()); this.executorLoader.updateExecutableNode(this.node); } catch (final ExecutorManagerException e) { this.flowLogger.error("Could not update job properties in db for " + this.jobId, e); } }
Returns a list of jobs that this JobRunner will wait upon to finish before starting. It is only relevant if pipeline is turned on.
writeStatus
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
private boolean handleNonReadyStatus() { synchronized (this.syncObject) { Status nodeStatus = this.node.getStatus(); boolean quickFinish = false; final long time = System.currentTimeMillis(); if (Status.isStatusFinished(nodeStatus)) { quickFinish = true; } else if (nodeStatus ...
Used to handle non-ready and special status's (i.e. KILLED). Returns true if they handled anything.
handleNonReadyStatus
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
private boolean blockOnPipeLine() { if (this.isKilled()) { return true; } // For pipelining of jobs. Will watch other jobs. if (!this.pipelineJobs.isEmpty()) { String blockedList = ""; final ArrayList<BlockingStatus> blockingStatus = new ArrayList<>(); for (final Strin...
If pipelining is set, will block on another flow's jobs.
blockOnPipeLine
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
private boolean delayExecution() { synchronized (this) { if (this.isKilled()) { return true; } final long currentTime = System.currentTimeMillis(); if (this.delayStartMs > 0) { this.logger.info("Delaying start of execution for " + this.delayStartMs + " millisecon...
If pipelining is set, will block on another flow's jobs.
delayExecution
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0
private void finalizeLogFile(final int attemptNo) { closeLogger(); this.flowLogger.debug("Logger has been closed"); if (this.logFile == null) { this.flowLogger.info("Log file for job " + this.jobId + " is null"); return; } try { final File[] files = this.logFile.getParentFile().li...
If pipelining is set, will block on another flow's jobs.
finalizeLogFile
java
azkaban/azkaban
azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
https://github.com/azkaban/azkaban/blob/master/azkaban-exec-server/src/main/java/azkaban/execapp/JobRunner.java
Apache-2.0