public interface SparkSubmitter
Modifier and Type | Method and Description |
---|---|
<V> com.google.common.util.concurrent.ListenableFuture<V> |
submit(SparkRuntimeContext runtimeContext,
Map<String,String> configs,
List<LocalizeResource> resources,
URI jobFile,
V result)
Submits a Spark job to the Spark framework.
|
<V> com.google.common.util.concurrent.ListenableFuture<V> submit(SparkRuntimeContext runtimeContext, Map<String,String> configs, List<LocalizeResource> resources, URI jobFile, V result)
V
- Type of the result objectruntimeContext
- the SparkRuntimeContext
representing the Spark programconfigs
- configurations for the Spark frameworkresources
- list of resources to be localized to Spark containersjobFile
- location of the job file required by the frameworkresult
- object instance to be available through the returned ListenableFuture
when it completesListenableFuture
that will be completed when the job finished. If the job execution failed,
the future will also be failed with the cause wrapped inside an ExecutionException
when Future.get()
is called. If Future.cancel(boolean)
is called,
the running job will be terminated immediately.Copyright © 2018 Cask Data, Inc. Licensed under the Apache License, Version 2.0.