This project has retired. For details please refer to its Attic page.
Index (Apache Twill 0.14.0 API)
Skip navigation links
A B C D E F G H I J K L M N O P R S T U V W Y Z 

A

abort() - Static method in class org.apache.twill.api.EventHandler.TimeoutAction
Creates a EventHandler.TimeoutAction to indicate aborting the application.
aborted() - Method in class org.apache.twill.api.EventHandler
Invoked by the application when the application is aborted because of timeout.
ABORTED - Static variable in class org.apache.twill.internal.ContainerExitCodes
Containers killed by the framework, either due to being released by the application or being 'lost' due to node failures etc.
AbstractExecutionServiceController - Class in org.apache.twill.internal
An abstract base class for implementing ServiceController that deal with Service state transition and listener callback.
AbstractExecutionServiceController(RunId) - Constructor for class org.apache.twill.internal.AbstractExecutionServiceController
 
AbstractTwillController - Class in org.apache.twill.internal
A abstract base class for TwillController implementation that uses Zookeeper to controller a running twill application.
AbstractTwillController(String, RunId, ZKClient, boolean, Iterable<LogHandler>) - Constructor for class org.apache.twill.internal.AbstractTwillController
 
AbstractTwillRunnable - Class in org.apache.twill.api
This abstract class provides default implementation of the TwillRunnable.
AbstractTwillRunnable() - Constructor for class org.apache.twill.api.AbstractTwillRunnable
 
AbstractTwillRunnable(Map<String, String>) - Constructor for class org.apache.twill.api.AbstractTwillRunnable
 
AbstractTwillService - Class in org.apache.twill.internal
A base implementation of Service that uses ZooKeeper to transmit states and messages.
AbstractTwillService(ZKClient, RunId) - Constructor for class org.apache.twill.internal.AbstractTwillService
 
AbstractZKClient - Class in org.apache.twill.zookeeper
An abstract base implementation of ZKClient that simplifies implementation by providing forwarding for methods that are meant to be delegated to other methods.
AbstractZKClient() - Constructor for class org.apache.twill.zookeeper.AbstractZKClient
 
AbstractZKServiceController - Class in org.apache.twill.internal
An abstract base class for implementing a ServiceController using ZooKeeper as a means for communicating with the remote service.
AbstractZKServiceController(RunId, ZKClient) - Constructor for class org.apache.twill.internal.AbstractZKServiceController
 
accept(String, URL, URL) - Method in class org.apache.twill.api.ClassAcceptor
Invoked to determine if class can be accepted.
ACLData - Interface in org.apache.twill.zookeeper
Represents result of call to ZKClient.getACL(String).
add(String, File) - Method in interface org.apache.twill.api.TwillSpecification.Builder.LocalFileAdder
 
add(String, URI) - Method in interface org.apache.twill.api.TwillSpecification.Builder.LocalFileAdder
 
add(String, File, boolean) - Method in interface org.apache.twill.api.TwillSpecification.Builder.LocalFileAdder
 
add(String, URI, boolean) - Method in interface org.apache.twill.api.TwillSpecification.Builder.LocalFileAdder
 
add(String, File, String) - Method in interface org.apache.twill.api.TwillSpecification.Builder.LocalFileAdder
 
add(String, URI, String) - Method in interface org.apache.twill.api.TwillSpecification.Builder.LocalFileAdder
 
add(String, File) - Method in class org.apache.twill.api.TwillSpecification.Builder.MoreFile
 
add(String, URI) - Method in class org.apache.twill.api.TwillSpecification.Builder.MoreFile
 
add(String, File, boolean) - Method in class org.apache.twill.api.TwillSpecification.Builder.MoreFile
 
add(String, URI, boolean) - Method in class org.apache.twill.api.TwillSpecification.Builder.MoreFile
 
add(String, File, String) - Method in class org.apache.twill.api.TwillSpecification.Builder.MoreFile
 
add(String, URI, String) - Method in class org.apache.twill.api.TwillSpecification.Builder.MoreFile
 
add(Hosts, String, String...) - Method in interface org.apache.twill.api.TwillSpecification.Builder.MorePlacementPolicies
Specify hosts for a list of runnables.
add(Racks, String, String...) - Method in interface org.apache.twill.api.TwillSpecification.Builder.MorePlacementPolicies
Specify racks for a list of runnables.
add(Hosts, Racks, String, String...) - Method in interface org.apache.twill.api.TwillSpecification.Builder.MorePlacementPolicies
Specify hosts and racks for a list of runnables.
add(TwillSpecification.PlacementPolicy.Type, String, String...) - Method in interface org.apache.twill.api.TwillSpecification.Builder.MorePlacementPolicies
Specify a placement policy for a list of runnables.
add(TwillRunnable) - Method in interface org.apache.twill.api.TwillSpecification.Builder.MoreRunnable
 
add(TwillRunnable, ResourceSpecification) - Method in interface org.apache.twill.api.TwillSpecification.Builder.MoreRunnable
 
add(String, TwillRunnable) - Method in interface org.apache.twill.api.TwillSpecification.Builder.MoreRunnable
Adds a TwillRunnable with ResourceSpecification.BASIC resource specification.
add(String, TwillRunnable, ResourceSpecification) - Method in interface org.apache.twill.api.TwillSpecification.Builder.MoreRunnable
 
add(Hosts, String, String...) - Method in class org.apache.twill.api.TwillSpecification.Builder.PlacementPolicySetter
 
add(Racks, String, String...) - Method in class org.apache.twill.api.TwillSpecification.Builder.PlacementPolicySetter
 
add(Hosts, Racks, String, String...) - Method in class org.apache.twill.api.TwillSpecification.Builder.PlacementPolicySetter
 
add(TwillSpecification.PlacementPolicy.Type, String, String...) - Method in class org.apache.twill.api.TwillSpecification.Builder.PlacementPolicySetter
 
add(TwillRunnable) - Method in class org.apache.twill.api.TwillSpecification.Builder.RunnableSetter
 
add(TwillRunnable, ResourceSpecification) - Method in class org.apache.twill.api.TwillSpecification.Builder.RunnableSetter
 
add(String, TwillRunnable) - Method in class org.apache.twill.api.TwillSpecification.Builder.RunnableSetter
 
add(String, TwillRunnable, ResourceSpecification) - Method in class org.apache.twill.api.TwillSpecification.Builder.RunnableSetter
 
add(String, int, long) - Method in interface org.apache.twill.kafka.client.KafkaConsumer.Preparer
Consumes messages from a given offset.
add(ByteBuffer, Object) - Method in interface org.apache.twill.kafka.client.KafkaPublisher.Preparer
Adds the given message to the message set, partitioned with the given partition key.
addAuthInfo(String, byte[]) - Method in class org.apache.twill.zookeeper.ZKClientService.Builder
Adds an authorization information.
addChangeListener(BrokerService.BrokerChangeListener, Executor) - Method in interface org.apache.twill.kafka.client.BrokerService
Adds a listener to changes in broker list managed by this service.
addCommand(String, String...) - Method in interface org.apache.twill.internal.ProcessLauncher.PrepareLaunchContext
Adds a command line to run in the container process.
addConnectionWatcher(Watcher) - Method in class org.apache.twill.zookeeper.ForwardingZKClient
 
addConnectionWatcher(Watcher) - Method in interface org.apache.twill.zookeeper.ZKClient
Adds a Watcher that will be called whenever connection state change.
addEnvironment(String, V) - Method in interface org.apache.twill.internal.ProcessLauncher.PrepareLaunchContext
Adds a key value pair to the container environment.
addFromBeginning(String, int) - Method in interface org.apache.twill.kafka.client.KafkaConsumer.Preparer
Consumes messages from the earliest message available.
addJVMOptions(String) - Method in interface org.apache.twill.api.TwillPreparer
This methods adds extra JVM options that will be passed to the java command line for every runnable of the application started through this TwillPreparer instance.
addLatest(String, int) - Method in interface org.apache.twill.kafka.client.KafkaConsumer.Preparer
Consumes messages from the latest message.
addListener(Service.Listener, Executor) - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
addListener(Service.Listener, Executor) - Method in class org.apache.twill.zookeeper.ForwardingZKClientService
 
addLogHandler(LogHandler) - Method in interface org.apache.twill.api.TwillController
Adds a LogHandler for receiving application log.
addLogHandler(LogHandler) - Method in interface org.apache.twill.api.TwillPreparer
Adds a LogHandler for receiving an application log.
addLogHandler(LogHandler) - Method in class org.apache.twill.internal.AbstractTwillController
 
addOption(String, String) - Method in class org.apache.twill.api.Command.Builder
 
addOptions(Map<String, String>) - Method in class org.apache.twill.api.Command.Builder
 
addResources(LocalFile...) - Method in interface org.apache.twill.internal.ProcessLauncher.PrepareLaunchContext
Adds list of files to be localized for the container.
addResources(Iterable<LocalFile>) - Method in interface org.apache.twill.internal.ProcessLauncher.PrepareLaunchContext
Adds list of files to be localized for the container.
addRunResources(String, TwillRunResources) - Method in class org.apache.twill.internal.DefaultResourceReport
Add resources used by an instance of the runnable.
addSecureStore(SecureStore) - Method in interface org.apache.twill.api.TwillPreparer
Adds security credentials for the runtime environment to gives application access to resources.
AfterConfigs() - Constructor for class org.apache.twill.api.TwillRunnableSpecification.Builder.AfterConfigs
 
AfterInstances() - Constructor for class org.apache.twill.api.ResourceSpecification.Builder.AfterInstances
 
AfterMemory() - Constructor for class org.apache.twill.api.ResourceSpecification.Builder.AfterMemory
 
AfterName() - Constructor for class org.apache.twill.api.TwillRunnableSpecification.Builder.AfterName
 
AfterName() - Constructor for class org.apache.twill.api.TwillSpecification.Builder.AfterName
 
AfterUplink() - Constructor for class org.apache.twill.api.ResourceSpecification.Builder.AfterUplink
 
announce(String, int) - Method in interface org.apache.twill.api.ServiceAnnouncer
Registers an endpoint that could be discovered by external party.
announce(String, int, byte[]) - Method in interface org.apache.twill.api.ServiceAnnouncer
Registers an endpoint that could be discovered by external party with a payload.
announce(String, int) - Method in class org.apache.twill.internal.BasicTwillContext
 
announce(String, int, byte[]) - Method in class org.apache.twill.internal.BasicTwillContext
 
anyOrder() - Method in interface org.apache.twill.api.TwillSpecification.Builder.AfterPlacementPolicy
No particular execution order is needed.
anyOrder() - Method in interface org.apache.twill.api.TwillSpecification.Builder.AfterRunnable
 
anyOrder() - Method in class org.apache.twill.api.TwillSpecification.Builder.PlacementPolicySetter
 
anyOrder() - Method in class org.apache.twill.api.TwillSpecification.Builder.RunnableSetter
 
append(String) - Method in interface org.apache.twill.filesystem.Location
Appends the child to the current Location.
APPLICATION_CLASSPATH - Static variable in class org.apache.twill.internal.Constants.Files
 
APPLICATION_JAR - Static variable in class org.apache.twill.internal.Constants.Files
 
APPLICATION_MAX_START_SECONDS - Static variable in class org.apache.twill.internal.Constants
Maximum number of seconds for AM to start.
APPLICATION_MAX_STOP_SECONDS - Static variable in class org.apache.twill.internal.Constants
Maximum number of seconds for AM to stop.
ApplicationBundler - Class in org.apache.twill.internal
This class builds jar files based on class dependencies.
ApplicationBundler(Iterable<String>) - Constructor for class org.apache.twill.internal.ApplicationBundler
Constructs an ApplicationBundler.
ApplicationBundler(Iterable<String>, Iterable<String>) - Constructor for class org.apache.twill.internal.ApplicationBundler
Constructs an ApplicationBundler.
ApplicationBundler(ClassAcceptor) - Constructor for class org.apache.twill.internal.ApplicationBundler
Constructs an ApplicationBundler.
apply() - Method in class org.apache.twill.api.TwillSpecification.Builder.MoreFile
 
Arguments(String, String, String, String[]) - Constructor for class org.apache.twill.ext.BundledJarRunner.Arguments
 
Arguments - Class in org.apache.twill.internal
Class that encapsulate application arguments and per runnable arguments.
Arguments(List<String>, Multimap<String, String>) - Constructor for class org.apache.twill.internal.Arguments
 
ARGUMENTS - Static variable in class org.apache.twill.internal.Constants.Files
 
awaitTerminated() - Method in interface org.apache.twill.api.ServiceController
Waits for termination of the remote service.
awaitTerminated(long, TimeUnit) - Method in interface org.apache.twill.api.ServiceController
Waits for termination of the remote service for no more than the given timeout limit.
awaitTerminated() - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
awaitTerminated(long, TimeUnit) - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 

B

BASIC - Static variable in interface org.apache.twill.api.ResourceSpecification
 
BasicTwillContext - Class in org.apache.twill.internal
Implementation of TwillContext that provides the basic runtime information of a TwillRunnable.
BasicTwillContext(RunId, RunId, InetAddress, String[], String[], TwillRunnableSpecification, int, DiscoveryService, DiscoveryServiceClient, ZKClient, int, int, int) - Constructor for class org.apache.twill.internal.BasicTwillContext
 
begin(String, String...) - Method in interface org.apache.twill.api.TwillSpecification.Builder.FirstOrder
 
begin(String, String...) - Method in class org.apache.twill.api.TwillSpecification.Builder.OrderSetter
 
BrokerChangeListener() - Constructor for class org.apache.twill.kafka.client.BrokerService.BrokerChangeListener
 
BrokerInfo - Class in org.apache.twill.kafka.client
Represents broker information.
BrokerInfo() - Constructor for class org.apache.twill.kafka.client.BrokerInfo
 
BrokerService - Interface in org.apache.twill.kafka.client
Service for providing information of kafka brokers.
BrokerService.BrokerChangeListener - Class in org.apache.twill.kafka.client
Listener for changes in broker list.
build() - Method in class org.apache.twill.api.Command.Builder
 
Build() - Constructor for class org.apache.twill.api.ResourceSpecification.Builder.Build
 
build() - Method in class org.apache.twill.api.ResourceSpecification.Builder.Build
 
build() - Method in class org.apache.twill.api.TwillRunnableSpecification.Builder.AfterConfigs
 
build() - Method in interface org.apache.twill.api.TwillSpecification.Builder.AfterOrder
 
build() - Method in class org.apache.twill.api.TwillSpecification.Builder.OrderSetter
 
build() - Method in class org.apache.twill.zookeeper.ZKClientService.Builder
Creates an instance of ZKClientService with the settings of this builder.
Builder() - Constructor for class org.apache.twill.ext.BundledJarRunner.Arguments.Builder
 
BundledJarRunnable - Class in org.apache.twill.ext
Uses BundledJarRunnable to run a bundled jar.
BundledJarRunnable() - Constructor for class org.apache.twill.ext.BundledJarRunnable
 
BundledJarRunner - Class in org.apache.twill.ext
Runs a bundled jar specified by jarPath.
BundledJarRunner(File, BundledJarRunner.Arguments) - Constructor for class org.apache.twill.ext.BundledJarRunner
 
BundledJarRunner.Arguments - Class in org.apache.twill.ext
Contains runtime arguments for BundledJarRunner.
BundledJarRunner.Arguments.Builder - Class in org.apache.twill.ext

C

cancel() - Method in interface org.apache.twill.common.Cancellable
Attempts to cancel execution of this task.
cancel() - Method in interface org.apache.twill.internal.ProcessController
Request to stop the running process.
Cancellable - Interface in org.apache.twill.common
Something, usually a task, that can be cancelled.
chainStart(Service, Service...) - Static method in class org.apache.twill.internal.Services
Starts a list of Service one by one.
chainStop(Service, Service...) - Static method in class org.apache.twill.internal.Services
Stops a list of Service one by one.
changed(BrokerService) - Method in class org.apache.twill.kafka.client.BrokerService.BrokerChangeListener
Invoked when there is a change in the broker list.
changeInstances(String, int) - Method in interface org.apache.twill.api.TwillController
Changes the number of running instances of a given runnable.
changeInstances(String, int) - Method in class org.apache.twill.internal.AbstractTwillController
 
ClassAcceptor - Class in org.apache.twill.api
Class that can be used to determine if class can be accepted.
ClassAcceptor() - Constructor for class org.apache.twill.api.ClassAcceptor
 
CLASSPATH - Static variable in class org.apache.twill.internal.Constants.Files
 
close() - Method in class org.apache.twill.discovery.ZKDiscoveryService
 
Command - Interface in org.apache.twill.api
Represents command objects.
Command.Builder - Class in org.apache.twill.api
Builder for creating Command object.
completed() - Method in class org.apache.twill.api.EventHandler
Invoked by the application when all containers complete.
completed(int) - Method in interface org.apache.twill.internal.TwillContainerController
Calls to indicated that the container that this controller is associated with is completed.
CompositeService - Class in org.apache.twill.internal
A Service that starts/stops list of services in order.
CompositeService(Service...) - Constructor for class org.apache.twill.internal.CompositeService
 
CompositeService(Iterable<? extends Service>) - Constructor for class org.apache.twill.internal.CompositeService
 
Compression - Enum in org.apache.twill.kafka.client
An Enum representing different compression codec options for publishing messages.
Configs - Class in org.apache.twill.api
Defines keys and default values constants being used for configuration.
Configs.Defaults - Class in org.apache.twill.api
Defines default configuration values.
Configs.Keys - Class in org.apache.twill.api
Defines keys being used in configuration.
configure() - Method in class org.apache.twill.api.AbstractTwillRunnable
 
configure() - Method in class org.apache.twill.api.EventHandler
Returns an EventHandlerSpecification for configuring this handler class.
configure() - Method in interface org.apache.twill.api.TwillApplication
Invoked when launching the application on the client side.
configure() - Method in interface org.apache.twill.api.TwillRunnable
Called at submission time.
configure() - Method in class org.apache.twill.ext.BundledJarRunnable
 
configure() - Method in class org.apache.twill.internal.SingleRunnableApplication
 
Constants - Class in org.apache.twill.internal
This class contains collection of common constants used in Twill.
Constants.Files - Class in org.apache.twill.internal
Constants for names of internal files that are shared between client, AM and containers.
CONSTRAINED_PROVISION_REQUEST_TIMEOUT - Static variable in class org.apache.twill.internal.Constants
Milliseconds AM should wait for RM to allocate a constrained provision request.
consume(KafkaConsumer.MessageCallback) - Method in interface org.apache.twill.kafka.client.KafkaConsumer.Preparer
Starts the consumption as being configured by this KafkaConsumer.Preparer.
ContainerExitCodes - Class in org.apache.twill.internal
Collection of known exit code.
ContainerExitCodes() - Constructor for class org.apache.twill.internal.ContainerExitCodes
 
ContainerInfo - Interface in org.apache.twill.internal
Represents information of the container that the processing is/will be running in.
containerLaunched(String, int, String) - Method in class org.apache.twill.api.EventHandler
Invoked by the application when new container is launched for a TwillRunnable.
ContainerLiveNodeData - Class in org.apache.twill.internal
 
ContainerLiveNodeData(String, String, String, Map<String, String>) - Constructor for class org.apache.twill.internal.ContainerLiveNodeData
 
containerStopped(String, int, String, int) - Method in class org.apache.twill.api.EventHandler
Invoked by the application when the container allocated for a TwillRunnable is stopped.
contains(Discoverable) - Method in interface org.apache.twill.discovery.ServiceDiscovered
Checks if the given discoverable contains in the current discovery list.
context - Variable in class org.apache.twill.api.EventHandler
 
CoreSetter() - Constructor for class org.apache.twill.api.ResourceSpecification.Builder.CoreSetter
 
create(String) - Method in class org.apache.twill.filesystem.FileContextLocationFactory
 
create(URI) - Method in class org.apache.twill.filesystem.FileContextLocationFactory
 
create(String) - Method in class org.apache.twill.filesystem.LocalLocationFactory
 
create(URI) - Method in class org.apache.twill.filesystem.LocalLocationFactory
 
create(String) - Method in interface org.apache.twill.filesystem.LocationFactory
Creates an instance of Location of the given path.
create(URI) - Method in interface org.apache.twill.filesystem.LocationFactory
Creates an instance of Location based on URI uri.
create(Credentials) - Static method in class org.apache.twill.yarn.YarnSecureStore
 
create(String, byte[], CreateMode) - Method in class org.apache.twill.zookeeper.AbstractZKClient
 
create(String, byte[], CreateMode, boolean) - Method in class org.apache.twill.zookeeper.AbstractZKClient
 
create(String, byte[], CreateMode, Iterable<ACL>) - Method in class org.apache.twill.zookeeper.AbstractZKClient
 
create(String, byte[], CreateMode, boolean, Iterable<ACL>) - Method in class org.apache.twill.zookeeper.ForwardingZKClient
 
create(String, byte[], CreateMode) - Method in interface org.apache.twill.zookeeper.ZKClient
Creates a path in zookeeper.
create(String, byte[], CreateMode, boolean) - Method in interface org.apache.twill.zookeeper.ZKClient
Creates a path in zookeeper.
create(String, byte[], CreateMode, Iterable<ACL>) - Method in interface org.apache.twill.zookeeper.ZKClient
Creates a path in zookeeper.
create(String, byte[], CreateMode, boolean, Iterable<ACL>) - Method in interface org.apache.twill.zookeeper.ZKClient
Creates a path in zookeeper, with given data and create mode.
createAppLocation(Configuration, String, URI) - Method in class org.apache.twill.internal.ServiceMain
Returns the Location for the application based on the app directory.
createArguments() - Method in class org.apache.twill.ext.BundledJarRunner.Arguments.Builder
 
createBundle(Location, Iterable<Class<?>>) - Method in class org.apache.twill.internal.ApplicationBundler
 
createBundle(Location, Class<?>, Class<?>...) - Method in class org.apache.twill.internal.ApplicationBundler
createBundle(Location, Iterable<Class<?>>, Iterable<URI>) - Method in class org.apache.twill.internal.ApplicationBundler
Creates a jar file which includes all the given classes and all the classes that they depended on.
createDaemonThreadFactory(String) - Static method in class org.apache.twill.common.Threads
Handy method to create ThreadFactory that creates daemon threads with the given name format.
createDeleteIfExists(ZKClient, String, byte[], CreateMode, boolean, ACL...) - Static method in class org.apache.twill.zookeeper.ZKOperations
Creates a ZK node of the given path.
createLock(String) - Method in interface org.apache.twill.api.TwillContext
Creates a Lock for performing locking mechanism within the same TwillApplication.
createLock(String) - Method in class org.apache.twill.internal.BasicTwillContext
 
createNew() - Method in interface org.apache.twill.filesystem.Location
Atomically creates a new, empty file named by this abstract pathname if and only if a file with this name does not yet exist.
createNew(String) - Method in interface org.apache.twill.filesystem.Location
Atomically creates a new, empty file named by this abstract pathname if and only if a file with this name does not yet exist.
createZKClient() - Method in class org.apache.twill.internal.ServiceMain
Creates a ZKClientService.
CREDENTIALS - Static variable in class org.apache.twill.internal.Constants.Files
 

D

DebugOptions(boolean, boolean, Iterable<String>) - Constructor for class org.apache.twill.internal.JvmOptions.DebugOptions
 
DefaultEventHandlerSpecification - Class in org.apache.twill.internal
 
DefaultEventHandlerSpecification(String, Map<String, String>) - Constructor for class org.apache.twill.internal.DefaultEventHandlerSpecification
 
DefaultEventHandlerSpecification(EventHandler) - Constructor for class org.apache.twill.internal.DefaultEventHandlerSpecification
 
DefaultLocalFile - Class in org.apache.twill.internal
A straightforward implementation of LocalFile.
DefaultLocalFile(String, URI, long, long, boolean, String) - Constructor for class org.apache.twill.internal.DefaultLocalFile
 
DefaultOrder(Set<String>, TwillSpecification.Order.Type) - Constructor for class org.apache.twill.internal.DefaultTwillSpecification.DefaultOrder
 
DefaultPlacementPolicy(Set<String>, TwillSpecification.PlacementPolicy.Type, Hosts, Racks) - Constructor for class org.apache.twill.internal.DefaultTwillSpecification.DefaultPlacementPolicy
 
DefaultResourceReport - Class in org.apache.twill.internal
Implementation of ResourceReport with some additional methods for maintaining the report.
DefaultResourceReport(String, TwillRunResources) - Constructor for class org.apache.twill.internal.DefaultResourceReport
 
DefaultResourceReport(String, TwillRunResources, Map<String, Collection<TwillRunResources>>, List<String>) - Constructor for class org.apache.twill.internal.DefaultResourceReport
 
DefaultResourceSpecification - Class in org.apache.twill.internal
Straightforward implementation of ResourceSpecification.
DefaultResourceSpecification(int, int, int, int, int) - Constructor for class org.apache.twill.internal.DefaultResourceSpecification
 
DefaultRuntimeSpecification - Class in org.apache.twill.internal
Straightforward implementation of RuntimeSpecification.
DefaultRuntimeSpecification(String, TwillRunnableSpecification, ResourceSpecification, Collection<LocalFile>) - Constructor for class org.apache.twill.internal.DefaultRuntimeSpecification
 
DefaultTwillRunnableSpecification - Class in org.apache.twill.internal
Straightforward implementation of TwillRunnableSpecification.
DefaultTwillRunnableSpecification(String, String, Map<String, String>) - Constructor for class org.apache.twill.internal.DefaultTwillRunnableSpecification
 
DefaultTwillRunnableSpecification(String, TwillRunnableSpecification) - Constructor for class org.apache.twill.internal.DefaultTwillRunnableSpecification
 
DefaultTwillRunResources - Class in org.apache.twill.internal
Straightforward implementation of TwillRunResources.
DefaultTwillRunResources(int, String, int, int, int, String, Integer) - Constructor for class org.apache.twill.internal.DefaultTwillRunResources
Constructor to create an instance of DefaultTwillRunResources with empty log levels.
DefaultTwillRunResources(int, String, int, int, int, String, Integer, Map<String, LogEntry.Level>) - Constructor for class org.apache.twill.internal.DefaultTwillRunResources
 
DefaultTwillSpecification - Class in org.apache.twill.internal
Straightforward implementation of TwillSpecification.
DefaultTwillSpecification(String, Map<String, RuntimeSpecification>, List<TwillSpecification.Order>, List<TwillSpecification.PlacementPolicy>, EventHandlerSpecification) - Constructor for class org.apache.twill.internal.DefaultTwillSpecification
 
DefaultTwillSpecification.DefaultOrder - Class in org.apache.twill.internal
Straightforward implementation of Order.
DefaultTwillSpecification.DefaultPlacementPolicy - Class in org.apache.twill.internal
Straightforward implementation of TwillSpecification.PlacementPolicy.
delegate(ZKClient) - Static method in class org.apache.twill.zookeeper.ZKClientServices
Creates a ZKClientService from the given ZKClient if the given ZKClient is an instance of ZKClientService or is a ForwardingZKClient that eventually trace back to a delegate of type ZKClientService.
delegate(ZKClient, ZKClientService) - Static method in class org.apache.twill.zookeeper.ZKClientServices
Creates a ZKClientService that for all ZKClient methods would be delegated to another ZKClient, while methods for ZKClientService would be delegated to another ZKClientService, which the given ZKClient and ZKClientService could be different instances.
delete() - Method in interface org.apache.twill.filesystem.Location
Deletes the file or directory denoted by this abstract pathname.
delete(boolean) - Method in interface org.apache.twill.filesystem.Location
Deletes the file or directory denoted by this abstract pathname.
delete(String) - Method in class org.apache.twill.zookeeper.AbstractZKClient
 
delete(String, int) - Method in class org.apache.twill.zookeeper.ForwardingZKClient
 
delete(String) - Method in interface org.apache.twill.zookeeper.ZKClient
Deletes the node of the given path without matching version.
delete(String, int) - Method in interface org.apache.twill.zookeeper.ZKClient
Deletes the node of the given path that match the given version.
destroy() - Method in class org.apache.twill.api.AbstractTwillRunnable
 
destroy() - Method in class org.apache.twill.api.EventHandler
Invoked by the application when shutting down.
destroy() - Method in interface org.apache.twill.api.TwillRunnable
Called when the Runnable.run() completed.
destroy() - Method in class org.apache.twill.ext.BundledJarRunnable
 
discover(String) - Method in interface org.apache.twill.api.TwillContext
Discover service with the given name that is announced within the same TwillApplication.
discover(String) - Method in interface org.apache.twill.discovery.DiscoveryServiceClient
Discover service with the given name.
discover(String) - Method in class org.apache.twill.discovery.InMemoryDiscoveryService
 
discover(String) - Method in class org.apache.twill.discovery.ZKDiscoveryService
 
discover(String) - Method in class org.apache.twill.internal.BasicTwillContext
 
Discoverable - Class in org.apache.twill.discovery
Discoverable defines the attributes of service to be discovered.
Discoverable(String, InetSocketAddress, byte[]) - Constructor for class org.apache.twill.discovery.Discoverable
 
Discoverable(String, InetSocketAddress) - Constructor for class org.apache.twill.discovery.Discoverable
 
discoverService(String) - Method in interface org.apache.twill.api.TwillController
Discovers the set of Discoverable endpoints that provides service for the given service name.
discoverService(String) - Method in class org.apache.twill.internal.AbstractTwillController
 
DISCOVERY_PATH_PREFIX - Static variable in class org.apache.twill.internal.Constants
Common ZK paths constants.
DiscoveryService - Interface in org.apache.twill.discovery
DiscoveryService defines interface for registering Discoverable.
DiscoveryServiceClient - Interface in org.apache.twill.discovery
Interface for DiscoveryServiceClient to discover services registered with DiscoveryService.
DISKS_FAILED - Static variable in class org.apache.twill.internal.ContainerExitCodes
When threshold number of the nodemanager-local-directories or threshold number of the nodemanager-log-directories become bad.
doDebug() - Method in class org.apache.twill.internal.JvmOptions.DebugOptions
 
doDebug(String) - Method in class org.apache.twill.internal.JvmOptions.DebugOptions
 
doInitialize(TwillContext) - Method in class org.apache.twill.ext.BundledJarRunnable
 
doMain(Service, Service...) - Method in class org.apache.twill.internal.ServiceMain
 
Done() - Constructor for class org.apache.twill.api.ResourceSpecification.Builder.Done
 
doRun() - Method in class org.apache.twill.internal.AbstractTwillService
Override to execution service work.
doShutDown() - Method in class org.apache.twill.internal.AbstractTwillController
 
doShutDown() - Method in class org.apache.twill.internal.AbstractZKServiceController
Called during shutdown.
doStart() - Method in class org.apache.twill.internal.AbstractTwillService
Override to perform any work during service start.
doStartUp() - Method in class org.apache.twill.internal.AbstractTwillController
 
doStartUp() - Method in class org.apache.twill.internal.AbstractZKServiceController
Called during startup.
doStop() - Method in class org.apache.twill.internal.AbstractTwillService
Overrides to perform any work during service shutdown.
doSuspend() - Method in class org.apache.twill.internal.JvmOptions.DebugOptions
 

E

ElectionHandler - Interface in org.apache.twill.api
Handles events of election/un-election of leader.
ElectionRegistry - Class in org.apache.twill.internal
Tracks currently active leader elections within the Twill container.
ElectionRegistry(ZKClient) - Constructor for class org.apache.twill.internal.ElectionRegistry
 
electLeader(String, ElectionHandler) - Method in interface org.apache.twill.api.TwillContext
Register to participate in a leader election by instances within the same TwillApplication.
electLeader(String, ElectionHandler) - Method in class org.apache.twill.internal.BasicTwillContext
 
enableDebugging(String...) - Method in interface org.apache.twill.api.TwillPreparer
Enable debugging for runnables, without suspending the virtual machine to wait for the debugger.
enableDebugging(boolean, String...) - Method in interface org.apache.twill.api.TwillPreparer
Enable debugging for runnables.
EnvContainerInfo - Class in org.apache.twill.internal
A ContainerInfo based on information on the environment.
EnvContainerInfo() - Constructor for class org.apache.twill.internal.EnvContainerInfo
 
ENVIRONMENTS - Static variable in class org.apache.twill.internal.Constants.Files
 
EnvKeys - Class in org.apache.twill.internal
Places for define common environment keys.
equals(Object) - Method in class org.apache.twill.discovery.Discoverable
 
equals(Object) - Method in class org.apache.twill.ext.BundledJarRunner.Arguments
 
equals(Object) - Method in class org.apache.twill.internal.DefaultTwillRunResources
 
equals(Object) - Method in class org.apache.twill.internal.JvmOptions.DebugOptions
 
equals(Object) - Method in class org.apache.twill.kafka.client.BrokerInfo
 
equals(Object) - Method in class org.apache.twill.kafka.client.TopicPartition
 
EventHandler - Class in org.apache.twill.api
A callback handler for acting on application events related to TwillRunnable lifecycle events.
EventHandler() - Constructor for class org.apache.twill.api.EventHandler
 
EventHandler.TimeoutAction - Class in org.apache.twill.api
Represents action to act upon runnable launch timeout.
EventHandler.TimeoutEvent - Class in org.apache.twill.api
This class holds information about a launch timeout event.
EventHandlerContext - Interface in org.apache.twill.api
Represents runtime context for EventHandler.
EventHandlerSpecification - Interface in org.apache.twill.api
Specification for EventHandler.
executor(Service.State) - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
exists() - Method in interface org.apache.twill.filesystem.Location
Checks if the this location exists.
exists(String) - Method in class org.apache.twill.zookeeper.AbstractZKClient
 
exists(String, Watcher) - Method in class org.apache.twill.zookeeper.ForwardingZKClient
 
exists(String) - Method in interface org.apache.twill.zookeeper.ZKClient
Checks if the path exists.
exists(String, Watcher) - Method in interface org.apache.twill.zookeeper.ZKClient
Checks if the given path exists and leave a watcher on the node for watching creation/deletion/data changes on the node.
exponentialDelay(long, long, TimeUnit) - Static method in class org.apache.twill.zookeeper.RetryStrategies
Creates a RetryStrategy that will increase delay exponentially between each retries.

F

failed(Service.State, Throwable) - Method in class org.apache.twill.internal.ServiceListenerAdapter
 
FetchedMessage - Interface in org.apache.twill.kafka.client
 
FILE_CONTEXT_CACHE_MAX_SIZE - Static variable in class org.apache.twill.api.Configs.Defaults
Default size of the file context cache.
FILE_CONTEXT_CACHE_MAX_SIZE - Static variable in class org.apache.twill.api.Configs.Keys
The maximum number of FileContext object cached by the FileContextLocationFactory.
FileContextLocationFactory - Class in org.apache.twill.filesystem
A LocationFactory implementation that uses FileContext to create Location.
FileContextLocationFactory(Configuration) - Constructor for class org.apache.twill.filesystem.FileContextLocationFactory
FileContextLocationFactory(Configuration, String) - Constructor for class org.apache.twill.filesystem.FileContextLocationFactory
Creates a new instance.
FileContextLocationFactory(Configuration, FileContext, String) - Constructor for class org.apache.twill.filesystem.FileContextLocationFactory
Deprecated.
Use FileContextLocationFactory.FileContextLocationFactory(Configuration) or FileContextLocationFactory.FileContextLocationFactory(Configuration, String) instead. The FileContext provided to this method will only be used if the current user calling any methods of this class matches with the UserGroupInformation of the FileContext instance.
FindFreePort - Class in org.apache.twill.launcher
Utility main class to find a free port on a machine.
FindFreePort() - Constructor for class org.apache.twill.launcher.FindFreePort
 
finished() - Method in interface org.apache.twill.kafka.client.KafkaConsumer.MessageCallback
Invoked when message consumption is stopped.
fixDelay(long, TimeUnit) - Static method in class org.apache.twill.zookeeper.RetryStrategies
Creates a RetryStrategy that imposes a fix delay between each retries.
follower() - Method in interface org.apache.twill.api.ElectionHandler
This method will get invoked when a participant is a follower in a leader election process.
forceShutDown() - Method in class org.apache.twill.internal.AbstractZKServiceController
 
ForwardingLocationFactory - Class in org.apache.twill.filesystem
 
ForwardingLocationFactory(LocationFactory) - Constructor for class org.apache.twill.filesystem.ForwardingLocationFactory
 
ForwardingZKClient - Class in org.apache.twill.zookeeper
 
ForwardingZKClient(ZKClient) - Constructor for class org.apache.twill.zookeeper.ForwardingZKClient
 
ForwardingZKClientService - Class in org.apache.twill.zookeeper
 
ForwardingZKClientService(ZKClientService) - Constructor for class org.apache.twill.zookeeper.ForwardingZKClientService
 
from(BundledJarRunner.Arguments) - Method in class org.apache.twill.ext.BundledJarRunner.Arguments.Builder
 
fromArray(String[]) - Static method in class org.apache.twill.ext.BundledJarRunner.Arguments
 
fromString(String) - Static method in class org.apache.twill.internal.RunIds
 

G

generate() - Static method in class org.apache.twill.internal.RunIds
 
get() - Method in class org.apache.twill.api.Hosts
Get the list of hosts.
get() - Method in class org.apache.twill.api.Racks
Get the list of racks.
getAck() - Method in enum org.apache.twill.kafka.client.KafkaPublisher.Ack
Returns the numerical ack number as understand by Kafka server.
getACL() - Method in interface org.apache.twill.zookeeper.ACLData
 
getACL(String) - Method in class org.apache.twill.zookeeper.ForwardingZKClient
 
getACL(String) - Method in interface org.apache.twill.zookeeper.ZKClient
Retrieves the Stat and ACL being set at the given path.
getActualInstances() - Method in class org.apache.twill.api.EventHandler.TimeoutEvent
 
getAMExtraOptions() - Method in class org.apache.twill.internal.JvmOptions
Returns the extra options for the application master.
getAMMinHeapRatio() - Method in class org.apache.twill.internal.TwillRuntimeSpecification
Returns the minimum heap ratio for the application master.
getAMReservedMemory() - Method in class org.apache.twill.internal.TwillRuntimeSpecification
Returns the reserved non-heap memory size in MB for the application master.
getApplicationArguments() - Method in interface org.apache.twill.api.TwillContext
Returns the runtime arguments that are passed to the TwillApplication.
getApplicationArguments() - Method in class org.apache.twill.internal.BasicTwillContext
 
getApplicationId() - Method in interface org.apache.twill.api.ResourceReport
Get the id of the application master.
getApplicationId() - Method in class org.apache.twill.internal.DefaultResourceReport
Get the id of the application master.
getApplicationName() - Method in interface org.apache.twill.api.EventHandlerContext
 
getApplicationName() - Method in interface org.apache.twill.api.TwillRunner.LiveInfo
Returns name of the application.
getApplicationRunId() - Method in interface org.apache.twill.api.TwillContext
Returns the RunId of this running application.
getApplicationRunId() - Method in class org.apache.twill.internal.BasicTwillContext
 
getAppMasterResources() - Method in interface org.apache.twill.api.ResourceReport
Get the resources application master is using.
getAppMasterResources() - Method in class org.apache.twill.internal.DefaultResourceReport
Get the resources application master is using.
getArgument(String) - Method in class org.apache.twill.api.AbstractTwillRunnable
 
getArguments() - Method in class org.apache.twill.api.AbstractTwillRunnable
 
getArguments() - Method in interface org.apache.twill.api.TwillContext
Returns the runtime arguments that are passed to the TwillRunnable.
getArguments() - Method in class org.apache.twill.ext.BundledJarRunnable
 
getArguments() - Method in class org.apache.twill.internal.Arguments
 
getArguments() - Method in class org.apache.twill.internal.BasicTwillContext
 
getBrokerList() - Method in interface org.apache.twill.kafka.client.BrokerService
Returns a comma separate string of all current brokers.
getBrokers() - Method in interface org.apache.twill.kafka.client.BrokerService
Returns a live iterable that gives information for all the known brokers.
getCause() - Method in interface org.apache.twill.api.logging.LogThrowable
Returns the cause of this LogThrowable.
getChildren(String) - Method in class org.apache.twill.zookeeper.AbstractZKClient
 
getChildren(String, Watcher) - Method in class org.apache.twill.zookeeper.ForwardingZKClient
 
getChildren() - Method in interface org.apache.twill.zookeeper.NodeChildren
 
getChildren(String) - Method in interface org.apache.twill.zookeeper.ZKClient
Gets the list of children nodes under the given path.
getChildren(String, Watcher) - Method in interface org.apache.twill.zookeeper.ZKClient
Gets the list of children nodes under the given path and leave a watcher on the node for watching node deletion and children nodes creation/deletion.
getClassName() - Method in interface org.apache.twill.api.EventHandlerSpecification
 
getClassName() - Method in interface org.apache.twill.api.logging.LogThrowable
Returns the name of the Throwable class.
getClassName() - Method in interface org.apache.twill.api.TwillRunnableSpecification
 
getClassName() - Method in class org.apache.twill.internal.DefaultEventHandlerSpecification
 
getClassName() - Method in class org.apache.twill.internal.DefaultTwillRunnableSpecification
 
getCodec() - Method in enum org.apache.twill.kafka.client.Compression
 
getCommand() - Method in interface org.apache.twill.api.Command
 
getCompletionFuture(Service) - Static method in class org.apache.twill.internal.Services
Returns a ListenableFuture that will be completed when the given service is stopped.
getConfig() - Method in class org.apache.twill.internal.TwillRuntimeSpecification
Returns the configuration for the application.
getConfigs() - Method in class org.apache.twill.api.EventHandler
Returns set of configurations available at runtime for access.
getConfigs() - Method in interface org.apache.twill.api.EventHandlerSpecification
 
getConfigs() - Method in interface org.apache.twill.api.TwillRunnableSpecification
 
getConfigs() - Method in class org.apache.twill.internal.DefaultEventHandlerSpecification
 
getConfigs() - Method in class org.apache.twill.internal.DefaultTwillRunnableSpecification
 
getConfiguration() - Method in class org.apache.twill.filesystem.FileContextLocationFactory
Returns the Configuration used by this LocationFactory.
getConnectString() - Method in class org.apache.twill.zookeeper.ForwardingZKClient
 
getConnectString() - Method in interface org.apache.twill.zookeeper.ZKClient
Returns the connection string used for connecting to Zookeeper.
getConsumer() - Method in interface org.apache.twill.kafka.client.KafkaClient
Creates a KafkaConsumer for consuming messages.
getContainerId() - Method in interface org.apache.twill.api.TwillRunResources
 
getContainerId() - Method in class org.apache.twill.internal.ContainerLiveNodeData
 
getContainerId() - Method in class org.apache.twill.internal.DefaultTwillRunResources
 
getContainerInfo() - Method in interface org.apache.twill.internal.ProcessLauncher
Returns information about the container that this launch would launch process in.
getContext() - Method in class org.apache.twill.api.AbstractTwillRunnable
 
getControllers() - Method in interface org.apache.twill.api.TwillRunner.LiveInfo
Returns TwillControllers for all live instances of the application.
getCores() - Method in interface org.apache.twill.api.ResourceSpecification
Deprecated.
getCores() - Method in class org.apache.twill.internal.DefaultResourceSpecification
Deprecated.
getData(String) - Method in class org.apache.twill.zookeeper.AbstractZKClient
 
getData(String, Watcher) - Method in class org.apache.twill.zookeeper.ForwardingZKClient
 
getData() - Method in interface org.apache.twill.zookeeper.NodeData
 
getData(String) - Method in interface org.apache.twill.zookeeper.ZKClient
Gets the data stored in the given path.
getData(String, Watcher) - Method in interface org.apache.twill.zookeeper.ZKClient
Gets the data stored in the given path and leave a watcher on the node for watching deletion/data changes on the node.
getDebugOptions() - Method in class org.apache.twill.internal.JvmOptions
 
getDebugPort() - Method in interface org.apache.twill.api.TwillRunResources
 
getDebugPort() - Method in class org.apache.twill.internal.ContainerLiveNodeData
 
getDebugPort() - Method in class org.apache.twill.internal.DefaultTwillRunResources
 
getDelegate() - Method in class org.apache.twill.filesystem.ForwardingLocationFactory
 
getDelegate() - Method in class org.apache.twill.zookeeper.ForwardingZKClient
 
getDownlink() - Method in interface org.apache.twill.api.ResourceSpecification
Returns the downlink bandwidth in Mbps.
getDownlink() - Method in class org.apache.twill.internal.DefaultResourceSpecification
 
getEventHandler() - Method in interface org.apache.twill.api.TwillSpecification
 
getEventHandler() - Method in class org.apache.twill.internal.DefaultTwillSpecification
 
getExpectedInstances() - Method in class org.apache.twill.api.EventHandler.TimeoutEvent
 
getFileContext() - Method in class org.apache.twill.filesystem.FileContextLocationFactory
Returns the FileContext for the current user based on UserGroupInformation.getCurrentUser().
getFileName() - Method in interface org.apache.twill.api.logging.LogEntry
Returns the source file name where the log emitted.
getFsUser() - Method in class org.apache.twill.internal.TwillRuntimeSpecification
 
getGroup() - Method in interface org.apache.twill.filesystem.Location
Returns the group of the location.
getHomeLocation() - Method in class org.apache.twill.filesystem.FileContextLocationFactory
 
getHomeLocation() - Method in class org.apache.twill.filesystem.LocalLocationFactory
 
getHomeLocation() - Method in interface org.apache.twill.filesystem.LocationFactory
Returns the home location.
getHost() - Method in interface org.apache.twill.api.logging.LogEntry
Returns hostname of where the log emitted.
getHost() - Method in interface org.apache.twill.api.TwillContext
Returns the hostname that the runnable is running on.
getHost() - Method in interface org.apache.twill.api.TwillRunResources
 
getHost() - Method in class org.apache.twill.internal.BasicTwillContext
 
getHost() - Method in interface org.apache.twill.internal.ContainerInfo
Returns the host information of the container.
getHost() - Method in class org.apache.twill.internal.ContainerLiveNodeData
 
getHost() - Method in class org.apache.twill.internal.DefaultTwillRunResources
 
getHost() - Method in class org.apache.twill.internal.EnvContainerInfo
 
getHost() - Method in class org.apache.twill.kafka.client.BrokerInfo
 
getHostname() - Method in class org.apache.twill.internal.ServiceMain
 
getHosts() - Method in interface org.apache.twill.api.TwillSpecification.PlacementPolicy
 
getHosts() - Method in class org.apache.twill.internal.DefaultTwillSpecification.DefaultPlacementPolicy
 
getId() - Method in interface org.apache.twill.api.RunId
 
getId() - Method in interface org.apache.twill.internal.ContainerInfo
Returns the ID of the container.
getId() - Method in class org.apache.twill.internal.EnvContainerInfo
 
getInputStream() - Method in interface org.apache.twill.filesystem.Location
 
getInstanceCount() - Method in interface org.apache.twill.api.TwillContext
Returns the number of running instances assigned for this TwillRunnable.
getInstanceCount() - Method in class org.apache.twill.internal.BasicTwillContext
 
getInstanceId() - Method in interface org.apache.twill.api.TwillContext
Returns an integer id from 0 to (instanceCount - 1).
getInstanceId() - Method in interface org.apache.twill.api.TwillRunResources
 
getInstanceId() - Method in class org.apache.twill.internal.BasicTwillContext
 
getInstanceId() - Method in class org.apache.twill.internal.DefaultTwillRunResources
 
getInstanceId() - Method in interface org.apache.twill.internal.TwillContainerController
 
getInstancePath() - Method in class org.apache.twill.internal.AbstractZKServiceController
Returns the zookeeper node path for the ephemeral instance node for this runId.
getInstances() - Method in interface org.apache.twill.api.ResourceSpecification
Returns number of execution instances.
getInstances() - Method in class org.apache.twill.internal.DefaultResourceSpecification
 
getJarFileName() - Method in class org.apache.twill.ext.BundledJarRunner.Arguments
 
getJVMOptions() - Method in class org.apache.twill.yarn.YarnTwillRunnerService
Returns any extra JVM options that have been set.
getKafkaZKConnect() - Method in class org.apache.twill.internal.TwillRuntimeSpecification
Returns the ZK connection string for the Kafka used for log collections, or null if log collection is disabled.
getLastModified() - Method in interface org.apache.twill.api.LocalFile
Returns the the last modified time of the file or -1 if unknown.
getLastModified() - Method in class org.apache.twill.internal.DefaultLocalFile
 
getLeader(String, int) - Method in interface org.apache.twill.kafka.client.BrokerService
Returns the broker information of the current leader of the given topic and partition.
getLibFolder() - Method in class org.apache.twill.ext.BundledJarRunner.Arguments
 
getLineNumber() - Method in interface org.apache.twill.api.logging.LogEntry
Returns the line number in the source file where the log emitted.
getLiveNodeData() - Method in class org.apache.twill.internal.AbstractTwillService
Returns an Object to be stored in the live node.
getLiveNodeData() - Method in interface org.apache.twill.internal.TwillContainerController
 
getLiveNodeGson() - Method in class org.apache.twill.internal.AbstractTwillService
Returns a Gson instance for serializing object returned by the AbstractTwillService.getLiveNodeData() method.
getLocalFiles() - Method in interface org.apache.twill.api.RuntimeSpecification
 
getLocalFiles() - Method in class org.apache.twill.internal.DefaultRuntimeSpecification
 
getLocationFactory() - Method in interface org.apache.twill.filesystem.Location
Returns the location factory used to create this instance.
getLoggerName() - Method in interface org.apache.twill.api.logging.LogEntry
Returns name of the logger.
getLogLevel() - Method in interface org.apache.twill.api.logging.LogEntry
Returns the log LogEntry.Level of the log.
getLogLevel() - Method in interface org.apache.twill.api.TwillRunResources
Deprecated.
Use TwillRunResources.getLogLevels() to get the log levels map and get root level from the map instead.
getLogLevel() - Method in class org.apache.twill.internal.DefaultTwillRunResources
Deprecated.
getLogLevels() - Method in interface org.apache.twill.api.TwillRunResources
 
getLogLevels() - Method in class org.apache.twill.internal.ContainerLiveNodeData
 
getLogLevels() - Method in class org.apache.twill.internal.DefaultTwillRunResources
 
getLogLevels() - Method in class org.apache.twill.internal.TwillRuntimeSpecification
 
getMainArgs() - Method in class org.apache.twill.ext.BundledJarRunner.Arguments
 
getMainClassName() - Method in class org.apache.twill.ext.BundledJarRunner.Arguments
 
getMaxHeapMemoryMB() - Method in interface org.apache.twill.api.TwillRunResources
 
getMaxHeapMemoryMB() - Method in class org.apache.twill.internal.DefaultTwillRunResources
 
getMaxHeapMemoryMB() - Method in class org.apache.twill.internal.TwillContainerLauncher
Returns the maximum heap memory size in MB of the Java process launched in the container.
getMaxMemoryMB() - Method in interface org.apache.twill.api.TwillContext
Returns the amount of memory in MB the runnable is allowed to use.
getMaxMemoryMB() - Method in class org.apache.twill.internal.BasicTwillContext
 
getMaxRetries() - Method in class org.apache.twill.internal.TwillRuntimeSpecification
 
getMemoryMB() - Method in interface org.apache.twill.api.TwillRunResources
 
getMemoryMB() - Method in class org.apache.twill.internal.DefaultTwillRunResources
 
getMemoryMB() - Method in class org.apache.twill.internal.EnvContainerInfo
 
getMemoryMB() - Method in interface org.apache.twill.internal.ResourceCapability
Returns memory size in MB.
getMemorySize() - Method in interface org.apache.twill.api.ResourceSpecification
Returns the memory size in MB.
getMemorySize() - Method in class org.apache.twill.internal.DefaultResourceSpecification
 
getMessage() - Method in interface org.apache.twill.api.logging.LogEntry
Returns the log message.
getMessage() - Method in interface org.apache.twill.api.logging.LogThrowable
Returns the message contained inside the Throwable.
getMinHeapRatio(String) - Method in class org.apache.twill.internal.TwillRuntimeSpecification
Returns the minimum heap ratio for the given runnable.
getName() - Method in interface org.apache.twill.api.LocalFile
 
getName() - Method in interface org.apache.twill.api.RuntimeSpecification
 
getName() - Method in interface org.apache.twill.api.TwillRunnableSpecification
 
getName() - Method in interface org.apache.twill.api.TwillSpecification
 
getName() - Method in class org.apache.twill.discovery.Discoverable
 
getName() - Method in interface org.apache.twill.discovery.ServiceDiscovered
Returns the name of the service being discovered.
getName() - Method in interface org.apache.twill.filesystem.Location
 
getName() - Method in class org.apache.twill.internal.DefaultLocalFile
 
getName() - Method in class org.apache.twill.internal.DefaultRuntimeSpecification
 
getName() - Method in class org.apache.twill.internal.DefaultTwillRunnableSpecification
 
getName() - Method in class org.apache.twill.internal.DefaultTwillSpecification
 
getNames() - Method in interface org.apache.twill.api.TwillSpecification.Order
 
getNames() - Method in interface org.apache.twill.api.TwillSpecification.PlacementPolicy
 
getNames() - Method in class org.apache.twill.internal.DefaultTwillSpecification.DefaultOrder
 
getNames() - Method in class org.apache.twill.internal.DefaultTwillSpecification.DefaultPlacementPolicy
 
getNextOffset() - Method in interface org.apache.twill.kafka.client.FetchedMessage
Returns the offset for the next message to be read.
getOffset() - Method in interface org.apache.twill.kafka.client.FetchedMessage
Returns the offset for the current message.
getOptions() - Method in interface org.apache.twill.api.Command
 
getOrders() - Method in interface org.apache.twill.api.TwillSpecification
 
getOrders() - Method in class org.apache.twill.internal.DefaultTwillSpecification
 
getOutputStream() - Method in interface org.apache.twill.filesystem.Location
 
getOutputStream(String) - Method in interface org.apache.twill.filesystem.Location
Creates an OutputStream for this location with the given permission.
getOwner() - Method in interface org.apache.twill.filesystem.Location
Returns the owner of the location.
getPartition() - Method in class org.apache.twill.kafka.client.TopicPartition
 
getPattern() - Method in interface org.apache.twill.api.LocalFile
 
getPattern() - Method in class org.apache.twill.internal.DefaultLocalFile
 
getPayload() - Method in class org.apache.twill.discovery.Discoverable
 
getPayload() - Method in interface org.apache.twill.kafka.client.FetchedMessage
 
getPermissions() - Method in interface org.apache.twill.filesystem.Location
Returns the permissions of this Location.
getPlacementPolicies() - Method in interface org.apache.twill.api.TwillSpecification
 
getPlacementPolicies() - Method in class org.apache.twill.internal.DefaultTwillSpecification
 
getPort() - Method in interface org.apache.twill.internal.ContainerInfo
Returns the port for communicating to the container host.
getPort() - Method in class org.apache.twill.internal.EnvContainerInfo
 
getPort() - Method in class org.apache.twill.kafka.client.BrokerInfo
 
getPublisher(KafkaPublisher.Ack, Compression) - Method in interface org.apache.twill.kafka.client.KafkaClient
Creates a KafkaPublisher that is ready for publish.
getRacks() - Method in interface org.apache.twill.api.TwillSpecification.PlacementPolicy
 
getRacks() - Method in class org.apache.twill.internal.DefaultTwillSpecification.DefaultPlacementPolicy
 
getReport() - Method in interface org.apache.twill.internal.ProcessController
 
getRequestPath() - Method in interface org.apache.twill.zookeeper.OperationFuture
 
getRequestTime() - Method in class org.apache.twill.api.EventHandler.TimeoutEvent
 
getReservedMemory(String) - Method in class org.apache.twill.internal.TwillRuntimeSpecification
Returns the reserved non-heap memory size in MB for the given runnable.
getResourceReport() - Method in interface org.apache.twill.api.TwillController
Get a snapshot of the resources used by the application, broken down by each runnable.
getResources() - Method in interface org.apache.twill.api.ResourceReport
Get all the run resources being used across all runnables.
getResources() - Method in class org.apache.twill.internal.DefaultResourceReport
Get all the run resources being used across all runnables.
getResourceSpecification() - Method in interface org.apache.twill.api.RuntimeSpecification
 
getResourceSpecification() - Method in class org.apache.twill.internal.DefaultRuntimeSpecification
 
getRmSchedulerAddr() - Method in class org.apache.twill.internal.TwillRuntimeSpecification
 
getRunId() - Method in interface org.apache.twill.api.EventHandlerContext
 
getRunId() - Method in interface org.apache.twill.api.ServiceController
Returns the RunId of the running application.
getRunId() - Method in interface org.apache.twill.api.TwillContext
Returns the RunId of this running instance of TwillRunnable.
getRunId() - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
getRunId() - Method in class org.apache.twill.internal.BasicTwillContext
 
getRunnableArguments() - Method in class org.apache.twill.internal.Arguments
 
getRunnableConfigs() - Method in class org.apache.twill.internal.TwillRuntimeSpecification
Returns the configurations for each runnable.
getRunnableExtraOptions(String) - Method in class org.apache.twill.internal.JvmOptions
Returns the extra options for the given runnable.
getRunnableName() - Method in class org.apache.twill.api.EventHandler.TimeoutEvent
 
getRunnableName() - Method in interface org.apache.twill.api.logging.LogEntry
Returns the runnable name.
getRunnableName() - Method in class org.apache.twill.internal.ServiceMain
Returns the name of the runnable that this running inside this process.
getRunnableResources(String) - Method in interface org.apache.twill.api.ResourceReport
Get all the run resources being used by all instances of the specified runnable.
getRunnableResources(String) - Method in class org.apache.twill.internal.DefaultResourceReport
Get all the run resources being used by all instances of the specified runnable.
getRunnables() - Method in interface org.apache.twill.api.TwillSpecification
 
getRunnables() - Method in class org.apache.twill.internal.DefaultTwillSpecification
 
getRunnables() - Method in class org.apache.twill.internal.JvmOptions.DebugOptions
 
getRunnableSpecification() - Method in interface org.apache.twill.api.RuntimeSpecification
 
getRunnableSpecification() - Method in class org.apache.twill.internal.DefaultRuntimeSpecification
 
getServices() - Method in interface org.apache.twill.api.ResourceReport
Get the list of services of the application master.
getServices() - Method in class org.apache.twill.internal.DefaultResourceReport
Get the list of services of the application master.
getSessionId() - Method in class org.apache.twill.zookeeper.ForwardingZKClient
 
getSessionId() - Method in interface org.apache.twill.zookeeper.ZKClient
Returns the current Zookeeper session ID of this client.
getSize() - Method in interface org.apache.twill.api.LocalFile
Returns the size of the file or -1 if unknown.
getSize() - Method in class org.apache.twill.internal.DefaultLocalFile
 
getSocketAddress() - Method in class org.apache.twill.discovery.Discoverable
 
getSourceClassName() - Method in interface org.apache.twill.api.logging.LogEntry
Returns the class name where the log emitted.
getSourceMethodName() - Method in interface org.apache.twill.api.logging.LogEntry
Returns the method name where the log emitted.
getSpecification() - Method in interface org.apache.twill.api.EventHandlerContext
 
getSpecification() - Method in interface org.apache.twill.api.TwillContext
Returns the TwillRunnableSpecification that was created by TwillRunnable.configure().
getSpecification() - Method in class org.apache.twill.internal.BasicTwillContext
 
getStackTraces() - Method in interface org.apache.twill.api.logging.LogEntry
Deprecated.
getStackTraces() - Method in interface org.apache.twill.api.logging.LogThrowable
Returns the stack trace of the Throwable.
getStat() - Method in interface org.apache.twill.zookeeper.ACLData
 
getStat() - Method in interface org.apache.twill.zookeeper.NodeChildren
 
getStat() - Method in interface org.apache.twill.zookeeper.NodeData
 
getStopMessageFuture() - Method in class org.apache.twill.internal.AbstractZKServiceController
 
getStore() - Method in interface org.apache.twill.api.SecureStore
 
getStore() - Method in class org.apache.twill.yarn.YarnSecureStore
 
getTempFile(String) - Method in interface org.apache.twill.filesystem.Location
Returns unique location for temporary file to be placed near this location.
getTerminationStatus() - Method in interface org.apache.twill.api.ServiceController
Gets the termination status of the application represented by this controller.
getTerminationStatus() - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
getThreadName() - Method in interface org.apache.twill.api.logging.LogEntry
Returns the name of the thread where the log emitted.
getThrowable() - Method in interface org.apache.twill.api.logging.LogEntry
Returns the Throwable information emitted with the log.
getTimeout() - Method in class org.apache.twill.api.EventHandler.TimeoutAction
Returns timeout in milliseconds or -1 if to abort the application.
getTimestamp() - Method in interface org.apache.twill.api.logging.LogEntry
Returns timestamp of the log.
getTopic() - Method in class org.apache.twill.kafka.client.TopicPartition
 
getTopicPartition() - Method in interface org.apache.twill.kafka.client.FetchedMessage
 
getTwillAppDir() - Method in class org.apache.twill.internal.TwillRuntimeSpecification
 
getTwillAppName() - Method in class org.apache.twill.internal.TwillRuntimeSpecification
 
getTwillAppRunId() - Method in class org.apache.twill.internal.TwillRuntimeSpecification
 
getTwillRuntimeSpecification() - Method in class org.apache.twill.internal.ServiceMain
Returns the TwillRuntimeSpecification for this application.
getTwillSpecification() - Method in class org.apache.twill.internal.TwillRuntimeSpecification
 
getType() - Method in interface org.apache.twill.api.TwillSpecification.Order
 
getType() - Method in interface org.apache.twill.api.TwillSpecification.PlacementPolicy
 
getType() - Method in class org.apache.twill.internal.DefaultTwillSpecification.DefaultOrder
 
getType() - Method in class org.apache.twill.internal.DefaultTwillSpecification.DefaultPlacementPolicy
 
getUplink() - Method in interface org.apache.twill.api.ResourceSpecification
Returns the uplink bandwidth in Mbps.
getUplink() - Method in class org.apache.twill.internal.DefaultResourceSpecification
 
getURI() - Method in interface org.apache.twill.api.LocalFile
 
getURI() - Method in class org.apache.twill.internal.DefaultLocalFile
 
getVirtualCores() - Method in interface org.apache.twill.api.ResourceSpecification
Returns the number of virtual CPU cores.
getVirtualCores() - Method in interface org.apache.twill.api.TwillContext
Returns the number of virtual cores the runnable is allowed to use.
getVirtualCores() - Method in interface org.apache.twill.api.TwillRunResources
 
getVirtualCores() - Method in class org.apache.twill.internal.BasicTwillContext
 
getVirtualCores() - Method in class org.apache.twill.internal.DefaultResourceSpecification
 
getVirtualCores() - Method in class org.apache.twill.internal.DefaultTwillRunResources
 
getVirtualCores() - Method in class org.apache.twill.internal.EnvContainerInfo
 
getVirtualCores() - Method in interface org.apache.twill.internal.ResourceCapability
Returns the number of virtual cpu cores.
getZkConnectStr() - Method in class org.apache.twill.internal.TwillRuntimeSpecification
 
getZooKeeperSupplier() - Method in class org.apache.twill.zookeeper.ForwardingZKClientService
 
getZooKeeperSupplier() - Method in interface org.apache.twill.zookeeper.ZKClientService
Returns a Supplier of ZooKeeper that gives the current ZooKeeper in use at the moment when Supplier.get() get called.

H

handleCommand(Command) - Method in class org.apache.twill.api.AbstractTwillRunnable
 
handleCommand(Command) - Method in interface org.apache.twill.api.TwillRunnable
Called when a command is received.
handleCommand(Command) - Method in class org.apache.twill.ext.BundledJarRunnable
 
hashCode() - Method in class org.apache.twill.discovery.Discoverable
 
hashCode() - Method in class org.apache.twill.ext.BundledJarRunner.Arguments
 
hashCode() - Method in class org.apache.twill.internal.DefaultTwillRunResources
 
hashCode() - Method in class org.apache.twill.internal.JvmOptions.DebugOptions
 
hashCode() - Method in class org.apache.twill.kafka.client.BrokerInfo
 
hashCode() - Method in class org.apache.twill.kafka.client.TopicPartition
 
HEAP_RESERVED_MIN_RATIO - Static variable in class org.apache.twill.api.Configs.Defaults
 
HEAP_RESERVED_MIN_RATIO - Static variable in class org.apache.twill.api.Configs.Keys
Configurable ratio between Heap and Reserved Memory.
Hosts - Class in org.apache.twill.api
Represents a list of hosts.
Hosts(Set<String>) - Constructor for class org.apache.twill.api.Hosts
 
Hosts(String, String...) - Constructor for class org.apache.twill.api.Hosts
 

I

ignoreError(OperationFuture<V>, Class<? extends KeeperException>, V) - Static method in class org.apache.twill.zookeeper.ZKOperations
Returns a new OperationFuture that the result will be the same as the given future, except that when the source future is having an exception matching the giving exception type, the errorResult will be set in to the returned OperationFuture.
INIT_FAILED - Static variable in class org.apache.twill.internal.ContainerExitCodes
When the container exit when it fails to initialize.
initialize(TwillContext) - Method in class org.apache.twill.api.AbstractTwillRunnable
 
initialize(EventHandlerContext) - Method in class org.apache.twill.api.EventHandler
Invoked by the application to initialize this EventHandler instance.
initialize(TwillContext) - Method in interface org.apache.twill.api.TwillRunnable
Called when the container process starts.
initialize(TwillContext) - Method in class org.apache.twill.ext.BundledJarRunnable
 
InMemoryDiscoveryService - Class in org.apache.twill.discovery
A simple in memory implementation of DiscoveryService and DiscoveryServiceClient.
InMemoryDiscoveryService() - Constructor for class org.apache.twill.discovery.InMemoryDiscoveryService
 
instanceNodeFailed(Throwable) - Method in class org.apache.twill.internal.AbstractZKServiceController
Called when failed to fetch from live instance node.
instanceNodeUpdated(NodeData) - Method in class org.apache.twill.internal.AbstractZKServiceController
Called when an update on the live instance node is detected.
INSTANCES_PATH_PREFIX - Static variable in class org.apache.twill.internal.Constants
 
INVALID - Static variable in class org.apache.twill.internal.ContainerExitCodes
 
isArchive() - Method in interface org.apache.twill.api.LocalFile
Indicates whether this file is an archive.
isArchive() - Method in class org.apache.twill.internal.DefaultLocalFile
 
isDirectory() - Method in interface org.apache.twill.filesystem.Location
Checks if this location represents a directory.
isLogCollectionEnabled() - Method in class org.apache.twill.internal.TwillRuntimeSpecification
Returns whether log collection is enabled.
isRunning() - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
isRunning() - Method in class org.apache.twill.zookeeper.ForwardingZKClientService
 

J

JAVA_RESERVED_MEMORY_MB - Static variable in class org.apache.twill.api.Configs.Defaults
Default have 200MB reserved for Java process.
JAVA_RESERVED_MEMORY_MB - Static variable in class org.apache.twill.api.Configs.Keys
Size in MB of reserved memory for Java process (non-heap memory).
JVM_OPTIONS - Static variable in class org.apache.twill.internal.Constants.Files
 
JvmOptions - Class in org.apache.twill.internal
A class that encapsulates the different options for starting Java in containers.
JvmOptions(String, Map<String, String>, JvmOptions.DebugOptions) - Constructor for class org.apache.twill.internal.JvmOptions
 
JvmOptions.DebugOptions - Class in org.apache.twill.internal
Represents the debugging options of the JVM.

K

KafkaClient - Interface in org.apache.twill.kafka.client
Represents a kafka client that can publish/subscribe to a Kafka server cluster.
KafkaClientService - Interface in org.apache.twill.kafka.client
A KafkaClient that extends Service to provide lifecycle management.
KafkaConsumer - Interface in org.apache.twill.kafka.client
A consumer for consuming (reading) messages published to a Kafka server cluster.
KafkaConsumer.MessageCallback - Interface in org.apache.twill.kafka.client
Callback for receiving new messages.
KafkaConsumer.Preparer - Interface in org.apache.twill.kafka.client
A builder for preparing message consumption.
KafkaPublisher - Interface in org.apache.twill.kafka.client
This interface is for publishing data to Kafka.
KafkaPublisher.Ack - Enum in org.apache.twill.kafka.client
Represents the desired level of publish acknowledgment.
KafkaPublisher.Preparer - Interface in org.apache.twill.kafka.client
A Preparer for preparing to publish messages to a given topic.
kill() - Method in interface org.apache.twill.api.ServiceController
Requests to forcefully kill a running service.
killed() - Method in class org.apache.twill.api.EventHandler
Invoked by the application when stop command is received to kill the current application.

L

lastModified() - Method in interface org.apache.twill.filesystem.Location
 
launch() - Method in interface org.apache.twill.internal.ProcessLauncher.PrepareLaunchContext
Launches the container process.
LAUNCHER_JAR - Static variable in class org.apache.twill.internal.Constants.Files
 
launchTimeout(Iterable<EventHandler.TimeoutEvent>) - Method in class org.apache.twill.api.EventHandler
Invoked when the number of expected instances doesn't match with number of actual instances.
launchTimeout(Iterable<EventHandler.TimeoutEvent>) - Method in class org.apache.twill.internal.LogOnlyEventHandler
 
leader() - Method in interface org.apache.twill.api.ElectionHandler
This method will get invoked when a participant becomes a leader in a leader election process.
length() - Method in interface org.apache.twill.filesystem.Location
 
limit(int, RetryStrategy) - Static method in class org.apache.twill.zookeeper.RetryStrategies
Creates a RetryStrategy that retries maximum given number of times, with the actual delay behavior delegated to another RetryStrategy.
list() - Method in interface org.apache.twill.filesystem.Location
List the locations under this location.
load() - Method in class org.apache.twill.ext.BundledJarRunner
 
load(ClassLoader) - Method in class org.apache.twill.ext.BundledJarRunner
 
LOCAL_STAGING_DIRECTORY - Static variable in class org.apache.twill.api.Configs.Defaults
Default use the system temp directory for local staging files.
LOCAL_STAGING_DIRECTORY - Static variable in class org.apache.twill.api.Configs.Keys
Specifies the local directory for twill to store files generated at runtime.
LocalFile - Interface in org.apache.twill.api
This interface represents a local file that will be available for the container running a TwillRunnable.
LOCALIZE_FILES - Static variable in class org.apache.twill.internal.Constants.Files
 
LocalLocationFactory - Class in org.apache.twill.filesystem
A LocationFactory for creating local file Location.
LocalLocationFactory() - Constructor for class org.apache.twill.filesystem.LocalLocationFactory
Constructs a LocalLocationFactory that Location created will be relative to system root.
LocalLocationFactory(File) - Constructor for class org.apache.twill.filesystem.LocalLocationFactory
 
Location - Interface in org.apache.twill.filesystem
This interface defines the location and operations of a resource on the filesystem.
LOCATION_CACHE_ANTIQUE_EXPIRY_MS - Static variable in class org.apache.twill.api.Configs.Defaults
Default expiration is five minutes for location cache created by different twill runner.
LOCATION_CACHE_ANTIQUE_EXPIRY_MS - Static variable in class org.apache.twill.api.Configs.Keys
Setting the expiration time in milliseconds of unused files created by older runs in the location cache.
LOCATION_CACHE_DIR - Static variable in class org.apache.twill.api.Configs.Keys
Setting caching directory name for location cache.
LOCATION_CACHE_EXPIRY_MS - Static variable in class org.apache.twill.api.Configs.Defaults
Default expiration is one day for location cache.
LOCATION_CACHE_EXPIRY_MS - Static variable in class org.apache.twill.api.Configs.Keys
Setting the expiration time in milliseconds of unused files in the location cache.
LocationFactories - Class in org.apache.twill.filesystem
Provides helper methods for creating different LocationFactory.
LocationFactory - Interface in org.apache.twill.filesystem
Factory for creating instance of Location.
LOG_COLLECTION_ENABLED - Static variable in class org.apache.twill.api.Configs.Defaults
Default to enable log collection.
LOG_COLLECTION_ENABLED - Static variable in class org.apache.twill.api.Configs.Keys
Setting for enabling log collection.
LOG_LEVELS - Static variable in class org.apache.twill.internal.Constants.Files
 
LOG_TOPIC - Static variable in class org.apache.twill.internal.Constants
 
LOGBACK_TEMPLATE - Static variable in class org.apache.twill.internal.Constants.Files
 
LogEntry - Interface in org.apache.twill.api.logging
Represents a log entry emitted by application.
LogEntry.Level - Enum in org.apache.twill.api.logging
Log level.
LogHandler - Interface in org.apache.twill.api.logging
Represents class that can receive logs from the application.
LogOnlyEventHandler - Class in org.apache.twill.internal
 
LogOnlyEventHandler() - Constructor for class org.apache.twill.internal.LogOnlyEventHandler
 
LogThrowable - Interface in org.apache.twill.api.logging
Carries Throwable information in a LogEntry.
lookup(String, RunId) - Method in interface org.apache.twill.api.TwillRunner
Gets a TwillController for the given application and runId.
lookup(String) - Method in interface org.apache.twill.api.TwillRunner
Gets an Iterable of TwillController for all running instances of the given application.
lookup(String, RunId) - Method in class org.apache.twill.yarn.YarnTwillRunnerService
 
lookup(String) - Method in class org.apache.twill.yarn.YarnTwillRunnerService
 
lookupLive() - Method in interface org.apache.twill.api.TwillRunner
lookupLive() - Method in class org.apache.twill.yarn.YarnTwillRunnerService
 

M

main(String[]) - Static method in class org.apache.twill.launcher.FindFreePort
 
main(String[]) - Static method in class org.apache.twill.launcher.TwillLauncher
Main method to unpackage a jar and run the mainClass.main() method.
MemorySetter() - Constructor for class org.apache.twill.api.ResourceSpecification.Builder.MemorySetter
 
mkdirs() - Method in interface org.apache.twill.filesystem.Location
Creates the directory named by this abstract pathname, including any necessary but nonexistent parent directories.
mkdirs(String) - Method in interface org.apache.twill.filesystem.Location
Creates the directory named by this abstract pathname, including any necessary but nonexistent parent directories.
MoreFile(TwillSpecification.Builder.LocalFileCompleter) - Constructor for class org.apache.twill.api.TwillSpecification.Builder.MoreFile
 

N

NameSetter() - Constructor for class org.apache.twill.api.TwillRunnableSpecification.Builder.NameSetter
 
NameSetter() - Constructor for class org.apache.twill.api.TwillSpecification.Builder.NameSetter
 
namespace(LocationFactory, String) - Static method in class org.apache.twill.filesystem.LocationFactories
Creates a LocationFactory that always applies the giving namespace prefix.
namespace(ZKClient, String) - Static method in class org.apache.twill.zookeeper.ZKClients
Creates a ZKClient that will add prefix namespace for every paths.
nextRetry(int, long, RetryStrategy.OperationType, String) - Method in interface org.apache.twill.zookeeper.RetryStrategy
Returns the number of milliseconds to wait before retrying the operation.
nextWhenCompleted(String, String...) - Method in interface org.apache.twill.api.TwillSpecification.Builder.NextOrder
 
nextWhenCompleted(String, String...) - Method in class org.apache.twill.api.TwillSpecification.Builder.OrderSetter
 
nextWhenStarted(String, String...) - Method in interface org.apache.twill.api.TwillSpecification.Builder.NextOrder
 
nextWhenStarted(String, String...) - Method in class org.apache.twill.api.TwillSpecification.Builder.OrderSetter
 
NO_DEBUG - Static variable in class org.apache.twill.internal.JvmOptions.DebugOptions
 
noConfigs() - Method in class org.apache.twill.api.TwillRunnableSpecification.Builder.AfterName
 
NodeChildren - Interface in org.apache.twill.zookeeper
NodeData - Interface in org.apache.twill.zookeeper
noLocalFiles() - Method in class org.apache.twill.api.TwillSpecification.Builder.RuntimeSpecificationAdder
 
noRetry() - Static method in class org.apache.twill.zookeeper.RetryStrategies
 

O

of(String) - Static method in class org.apache.twill.api.Command.Builder
 
of(String, String...) - Static method in class org.apache.twill.api.Hosts
Convenience method to create an instance of Hosts.
of(String, String...) - Static method in class org.apache.twill.api.Racks
Convenience method to create an instance of Racks.
of(String) - Static method in class org.apache.twill.zookeeper.ZKClientService.Builder
Creates a ZKClientService.Builder with the given ZooKeeper connection string.
onChange(ServiceDiscovered) - Method in interface org.apache.twill.discovery.ServiceDiscovered.ChangeListener
This method will be invoked when the discovery list changed.
onLog(LogEntry) - Method in interface org.apache.twill.api.logging.LogHandler
Invokes when there is new LogEntry received from the application.
onLog(LogEntry) - Method in class org.apache.twill.api.logging.PrinterLogHandler
 
onReceived(String, Message) - Method in class org.apache.twill.internal.AbstractTwillService
Handles message by simply logging it.
onReceived(Iterator<FetchedMessage>) - Method in interface org.apache.twill.kafka.client.KafkaConsumer.MessageCallback
Invoked when new messages is available.
onRunning(Runnable, Executor) - Method in interface org.apache.twill.api.ServiceController
Attaches a Runnable that will get executed when the service is running.
onRunning(Runnable, Executor) - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
onTerminated(Runnable, Executor) - Method in interface org.apache.twill.api.ServiceController
Attaches a Runnable that will get executed when the serivce is terminated.
onTerminated(Runnable, Executor) - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
OperationFuture<V> - Interface in org.apache.twill.zookeeper
A ListenableFuture that also provides the requested path for a operation.
OrderSetter() - Constructor for class org.apache.twill.api.TwillSpecification.Builder.OrderSetter
 
org.apache.twill.api - package org.apache.twill.api
Classes in this package provides core functionality of the Twill library.
org.apache.twill.api.logging - package org.apache.twill.api.logging
This package contains class for handling logging events.
org.apache.twill.api.security - package org.apache.twill.api.security
 
org.apache.twill.common - package org.apache.twill.common
 
org.apache.twill.discovery - package org.apache.twill.discovery
Classes in this package provides service discovery implementations.
org.apache.twill.ext - package org.apache.twill.ext
 
org.apache.twill.filesystem - package org.apache.twill.filesystem
Contains HDFS location classes.
org.apache.twill.internal - package org.apache.twill.internal
This package provides internal classes for Twill.
org.apache.twill.kafka.client - package org.apache.twill.kafka.client
This package provides Kafka client interfaces.
org.apache.twill.launcher - package org.apache.twill.launcher
 
org.apache.twill.yarn - package org.apache.twill.yarn
Classes in this package implement the Twill API for Apache Hadoop YARN.
org.apache.twill.zookeeper - package org.apache.twill.zookeeper
This package provides functionality for ZooKeeper interactions.

P

PlacementPolicySetter() - Constructor for class org.apache.twill.api.TwillSpecification.Builder.PlacementPolicySetter
 
PREEMPTED - Static variable in class org.apache.twill.internal.ContainerExitCodes
Containers preempted by the YARN framework.
prepare(TwillRunnable) - Method in interface org.apache.twill.api.TwillRunner
Prepares to run the given TwillRunnable with ResourceSpecification.BASIC resource specification.
prepare(TwillRunnable, ResourceSpecification) - Method in interface org.apache.twill.api.TwillRunner
Prepares to run the given TwillRunnable with the given resource specification.
prepare(TwillApplication) - Method in interface org.apache.twill.api.TwillRunner
Prepares to run the given TwillApplication as specified by the application.
prepare() - Method in interface org.apache.twill.kafka.client.KafkaConsumer
Prepares for message consumption.
prepare(String) - Method in interface org.apache.twill.kafka.client.KafkaPublisher
Prepares to publish to a given topic.
prepare(TwillRunnable) - Method in class org.apache.twill.yarn.YarnTwillRunnerService
 
prepare(TwillRunnable, ResourceSpecification) - Method in class org.apache.twill.yarn.YarnTwillRunnerService
 
prepare(TwillApplication) - Method in class org.apache.twill.yarn.YarnTwillRunnerService
 
prepareLaunch(Map<String, String>, Iterable<LocalFile>, C) - Method in interface org.apache.twill.internal.ProcessLauncher
Returns a preparer with the given default set of environments, resources and credentials.
PrinterLogHandler - Class in org.apache.twill.api.logging
A LogHandler that prints the LogEntry through a PrintWriter.
PrinterLogHandler(PrintWriter) - Constructor for class org.apache.twill.api.logging.PrinterLogHandler
Creates a PrinterLogHandler which has LogEntry written to the given PrintWriter.
ProcessController<R> - Interface in org.apache.twill.internal
For controlling a launch yarn process.
ProcessLauncher<T extends ResourceCapability> - Interface in org.apache.twill.internal
Class for launching container process.
ProcessLauncher.PrepareLaunchContext - Interface in org.apache.twill.internal
For setting up the launcher.
PROVISION_TIMEOUT - Static variable in class org.apache.twill.internal.Constants
 

R

Racks - Class in org.apache.twill.api
Represents a list of Racks.
Racks(Set<String>) - Constructor for class org.apache.twill.api.Racks
 
Racks(String, String...) - Constructor for class org.apache.twill.api.Racks
 
recheck(long, TimeUnit) - Static method in class org.apache.twill.api.EventHandler.TimeoutAction
Creates a EventHandler.TimeoutAction to indicate recheck again after the given time has passed.
recursiveDelete(ZKClient, String) - Static method in class org.apache.twill.zookeeper.ZKOperations
Deletes the given path recursively.
register(Discoverable) - Method in interface org.apache.twill.discovery.DiscoveryService
Registers a Discoverable service.
register(Discoverable) - Method in class org.apache.twill.discovery.InMemoryDiscoveryService
 
register(Discoverable) - Method in class org.apache.twill.discovery.ZKDiscoveryService
Registers a Discoverable in zookeeper.
register(String, ElectionHandler) - Method in class org.apache.twill.internal.ElectionRegistry
Creates a new LeaderElection for the given arguments, starts the service, and adds it to the registry.
removeLogLevel(String) - Method in class org.apache.twill.internal.ContainerLiveNodeData
 
removeRunnableResources(String, String) - Method in class org.apache.twill.internal.DefaultResourceReport
Remove the resource corresponding to the given runnable and container.
renameTo(Location) - Method in interface org.apache.twill.filesystem.Location
Moves the file or directory denoted by this abstract pathname.
renew(String, RunId, SecureStoreWriter) - Method in class org.apache.twill.api.security.SecureStoreRenewer
Renew the secure store for an application run.
resetLogHandler() - Method in class org.apache.twill.internal.AbstractTwillController
Reset the log handler to poll from the beginning of Kafka.
resetLogLevels(String...) - Method in interface org.apache.twill.api.TwillController
Reset the log levels of all runnables.
resetLogLevels(String...) - Method in class org.apache.twill.internal.AbstractTwillController
 
resetRunnableLogLevels(String, String...) - Method in interface org.apache.twill.api.TwillController
Reset the log levels of the given runnable.
resetRunnableLogLevels(String, String...) - Method in class org.apache.twill.internal.AbstractTwillController
 
ResourceCapability - Interface in org.apache.twill.internal
Represents information about compute resources capability.
ResourceReport - Interface in org.apache.twill.api
This interface provides a snapshot of the resources an application is using broken down by each runnable.
RESOURCES_JAR - Static variable in class org.apache.twill.internal.Constants.Files
 
ResourceSpecification - Interface in org.apache.twill.api
This interface provides specifications for resource requirements including set and get methods for number of cores, amount of memory, and number of instances.
ResourceSpecification.Builder - Class in org.apache.twill.api
Builder for creating ResourceSpecification.
ResourceSpecification.Builder.AfterInstances - Class in org.apache.twill.api
 
ResourceSpecification.Builder.AfterMemory - Class in org.apache.twill.api
 
ResourceSpecification.Builder.AfterUplink - Class in org.apache.twill.api
 
ResourceSpecification.Builder.Build - Class in org.apache.twill.api
 
ResourceSpecification.Builder.CoreSetter - Class in org.apache.twill.api
 
ResourceSpecification.Builder.Done - Class in org.apache.twill.api
 
ResourceSpecification.Builder.MemorySetter - Class in org.apache.twill.api
 
ResourceSpecification.SizeUnit - Enum in org.apache.twill.api
Unit for specifying memory size.
RESTART_ALL_RUNNABLE_INSTANCES - Static variable in class org.apache.twill.internal.Constants
Command names for the restart runnable instances.
RESTART_RUNNABLES_INSTANCES - Static variable in class org.apache.twill.internal.Constants
 
restartAllInstances(String) - Method in interface org.apache.twill.api.TwillController
Restart all instances of a particular TwillRunnable.
restartAllInstances(String) - Method in class org.apache.twill.internal.AbstractTwillController
 
restartInstances(Map<String, ? extends Set<Integer>>) - Method in interface org.apache.twill.api.TwillController
Restart instances of some TwillRunnable.
restartInstances(String, int, int...) - Method in interface org.apache.twill.api.TwillController
Restart instances of some TwillRunnable.
restartInstances(String, Set<Integer>) - Method in interface org.apache.twill.api.TwillController
Restart instances of some TwillRunnable.
restartInstances(Map<String, ? extends Set<Integer>>) - Method in class org.apache.twill.internal.AbstractTwillController
 
restartInstances(String, int, int...) - Method in class org.apache.twill.internal.AbstractTwillController
 
restartInstances(String, Set<Integer>) - Method in class org.apache.twill.internal.AbstractTwillController
 
retryOnFailure(ZKClient, RetryStrategy) - Static method in class org.apache.twill.zookeeper.ZKClients
Creates a ZKClient that will retry interim failure (e.g.
RetryStrategies - Class in org.apache.twill.zookeeper
Factory for creating common RetryStrategy implementation.
RetryStrategy - Interface in org.apache.twill.zookeeper
Provides strategy to use for operation retries.
RetryStrategy.OperationType - Enum in org.apache.twill.zookeeper
Defines ZooKeeper operation type that triggers retry.
reWatchOnExpire(ZKClient) - Static method in class org.apache.twill.zookeeper.ZKClients
Creates a ZKClient that will perform auto re-watch on all existing watches when reconnection happens after session expiration.
run() - Method in class org.apache.twill.ext.BundledJarRunnable
 
run() - Method in class org.apache.twill.ext.BundledJarRunner
 
run() - Method in class org.apache.twill.internal.AbstractTwillService
 
RunId - Interface in org.apache.twill.api
Represents the unique ID of a particular execution.
runId - Variable in class org.apache.twill.internal.AbstractTwillService
 
RunIds - Class in org.apache.twill.internal
Factory class for creating instance of RunId.
RunnableSetter() - Constructor for class org.apache.twill.api.TwillSpecification.Builder.RunnableSetter
 
running() - Method in class org.apache.twill.internal.ServiceListenerAdapter
 
RUNTIME_CONFIG_JAR - Static variable in class org.apache.twill.internal.Constants.Files
 
RuntimeSpecification - Interface in org.apache.twill.api
Specifications for runtime requirements.

S

SAME_THREAD_EXECUTOR - Static variable in class org.apache.twill.common.Threads
A executor that execute task from the submitter thread.
scheduleSecureStoreUpdate(SecureStoreUpdater, long, long, TimeUnit) - Method in interface org.apache.twill.api.TwillRunner
scheduleSecureStoreUpdate(SecureStoreUpdater, long, long, TimeUnit) - Method in class org.apache.twill.yarn.YarnTwillRunnerService
 
SECURE_STORE_UPDATE_LOCATION_ENABLED - Static variable in class org.apache.twill.api.Configs.Keys
Set this to false to disable the secure store updates done by default.
SecureStore - Interface in org.apache.twill.api
Represents storage of secure tokens.
SecureStoreRenewer - Class in org.apache.twill.api.security
This class is responsible for renewing the secure store used by application.
SecureStoreRenewer() - Constructor for class org.apache.twill.api.security.SecureStoreRenewer
 
SecureStoreUpdater - Interface in org.apache.twill.api
Deprecated.
This class doesn't handle user correctly, use SecureStoreRenewer instead
SecureStoreWriter - Interface in org.apache.twill.api.security
A writer provided to SecureStoreRenewer for writing out SecureStore during renewal process.
send() - Method in interface org.apache.twill.kafka.client.KafkaPublisher.Preparer
Sends all the messages being added through the KafkaPublisher.Preparer.add(java.nio.ByteBuffer, java.lang.Object) method.
sendCommand(Command) - Method in interface org.apache.twill.api.ServiceController
Sends a user command to the running application.
sendCommand(String, Command) - Method in interface org.apache.twill.api.ServiceController
Sends a user command to the given runnable of the running application.
sendCommand(Command) - Method in class org.apache.twill.internal.AbstractZKServiceController
 
sendCommand(String, Command) - Method in class org.apache.twill.internal.AbstractZKServiceController
 
sendMessage(Message, V) - Method in class org.apache.twill.internal.AbstractZKServiceController
Sends a Message to the remote service.
sendMessage(Message) - Method in interface org.apache.twill.internal.TwillContainerController
 
sendMessage(ZKClient, String, Message, V) - Static method in class org.apache.twill.internal.ZKMessages
Creates a message node in zookeeper.
sendMessage(ZKClient, String, Message, SettableFuture<V>, V) - Static method in class org.apache.twill.internal.ZKMessages
Creates a message node in zookeeper.
ServiceAnnouncer - Interface in org.apache.twill.api
This interface provides a way to announce the availability of a service.
ServiceController - Interface in org.apache.twill.api
This interface is for controlling a remote running service.
ServiceController.TerminationStatus - Enum in org.apache.twill.api
Enum to represent termination status of the application when it completed.
ServiceDiscovered - Interface in org.apache.twill.discovery
Represents the result of service discovery.
ServiceDiscovered.ChangeListener - Interface in org.apache.twill.discovery
Represents a callback for watching changes in the discovery list.
ServiceListenerAdapter - Class in org.apache.twill.internal
An adapter for implementing Service.Listener with all method default to no-op.
ServiceListenerAdapter() - Constructor for class org.apache.twill.internal.ServiceListenerAdapter
 
ServiceMain - Class in org.apache.twill.internal
Class for main method that starts a service.
ServiceMain() - Constructor for class org.apache.twill.internal.ServiceMain
 
ServiceMain.TwillZKPathService - Class in org.apache.twill.internal
A simple service for creating/remove ZK paths needed for AbstractTwillService.
Services - Class in org.apache.twill.internal
Utility methods for help dealing with Service.
setACL(String, Iterable<ACL>) - Method in class org.apache.twill.zookeeper.AbstractZKClient
 
setACL(String, Iterable<ACL>, int) - Method in class org.apache.twill.zookeeper.ForwardingZKClient
 
setACL(String, Iterable<ACL>) - Method in interface org.apache.twill.zookeeper.ZKClient
Sets the ACL of the given path if the path exists.
setACL(String, Iterable<ACL>, int) - Method in interface org.apache.twill.zookeeper.ZKClient
Sets the ACL of the given path if the path exists and version matched.
setClassesDir(String) - Method in class org.apache.twill.internal.ApplicationBundler
Sets the name of the directory inside the bundle jar that all ".class" files stored in.
setClassLoader(String) - Method in interface org.apache.twill.api.TwillPreparer
Sets the class name of the ClassLoader to be used for loading twill and application classes for all containers.
setConnectionWatcher(Watcher) - Method in class org.apache.twill.zookeeper.ZKClientService.Builder
Sets a Watcher that will be called whenever connection state change.
setCores(int) - Method in class org.apache.twill.api.ResourceSpecification.Builder.CoreSetter
Deprecated.
setData(String, byte[]) - Method in class org.apache.twill.zookeeper.AbstractZKClient
 
setData(String, byte[], int) - Method in class org.apache.twill.zookeeper.ForwardingZKClient
 
setData(String, byte[]) - Method in interface org.apache.twill.zookeeper.ZKClient
Sets the data for the given path without matching version.
setData(String, byte[], int) - Method in interface org.apache.twill.zookeeper.ZKClient
Sets the data for the given path that match the given version.
setDownlink(int, ResourceSpecification.SizeUnit) - Method in class org.apache.twill.api.ResourceSpecification.Builder.AfterUplink
 
setGroup(String) - Method in interface org.apache.twill.filesystem.Location
Sets the group of the location.
setInstanceCount(int) - Method in class org.apache.twill.internal.BasicTwillContext
 
setInstances(int) - Method in class org.apache.twill.api.ResourceSpecification.Builder.AfterMemory
 
setJarFileName(String) - Method in class org.apache.twill.ext.BundledJarRunner.Arguments.Builder
 
setJVMOptions(String) - Method in interface org.apache.twill.api.TwillPreparer
This methods sets the extra JVM options that will be passed to the java command line for every runnable of the application started through this TwillPreparer instance.
setJVMOptions(String, String) - Method in interface org.apache.twill.api.TwillPreparer
This methods sets the extra JVM options that will be passed to the java command line for the given runnable of the application started through this TwillPreparer instance.
setJVMOptions(String) - Method in class org.apache.twill.yarn.YarnTwillRunnerService
This methods sets the extra JVM options that will be passed to the java command line for every application started through this YarnTwillRunnerService instance.
setLibDir(String) - Method in class org.apache.twill.internal.ApplicationBundler
Sets the name of the directory inside the bundle jar that all ".jar" files stored in.
setLibFolder(String) - Method in class org.apache.twill.ext.BundledJarRunner.Arguments.Builder
 
setLogLevel(LogEntry.Level) - Method in interface org.apache.twill.api.TwillPreparer
Deprecated.
Use TwillPreparer.setLogLevels(Map) with key Logger.ROOT_LOGGER_NAME instead.
setLogLevel(String, String) - Method in class org.apache.twill.internal.ContainerLiveNodeData
 
setLogLevels(Map<String, LogEntry.Level>) - Method in interface org.apache.twill.api.TwillPreparer
Set the log levels for requested logger names for Twill applications running in a container.
setLogLevels(String, Map<String, LogEntry.Level>) - Method in interface org.apache.twill.api.TwillPreparer
Set the log levels for requested logger names for a TwillRunnable.
setMainArgs(String[]) - Method in class org.apache.twill.ext.BundledJarRunnable
 
setMainArgs(String) - Method in class org.apache.twill.ext.BundledJarRunnable
 
setMainArgs(String[]) - Method in class org.apache.twill.ext.BundledJarRunner.Arguments.Builder
 
setMainClassName(String) - Method in class org.apache.twill.ext.BundledJarRunner.Arguments.Builder
 
setMemory(int, ResourceSpecification.SizeUnit) - Method in class org.apache.twill.api.ResourceSpecification.Builder.MemorySetter
 
setName(String) - Method in class org.apache.twill.api.TwillRunnableSpecification.Builder.NameSetter
 
setName(String) - Method in class org.apache.twill.api.TwillSpecification.Builder.NameSetter
 
setPermissions(String) - Method in interface org.apache.twill.filesystem.Location
Sets the permissions on this location.
setResourcesDir(String) - Method in class org.apache.twill.internal.ApplicationBundler
Sets the name of the directory inside the bundle jar that all resource files stored in.
setSchedulerQueue(String) - Method in interface org.apache.twill.api.TwillPreparer
Sets the name of the scheduler queue to use.
setSecureStoreRenewer(SecureStoreRenewer, long, long, long, TimeUnit) - Method in interface org.apache.twill.api.TwillRunner
Sets and schedules a periodic renewal of SecureStore using a given SecureStoreRenewer.
setSecureStoreRenewer(SecureStoreRenewer, long, long, long, TimeUnit) - Method in class org.apache.twill.yarn.YarnTwillRunnerService
 
setServices(List<String>) - Method in class org.apache.twill.internal.DefaultResourceReport
Set the list of services of the application master.
setSessionTimeout(int) - Method in class org.apache.twill.zookeeper.ZKClientService.Builder
Sets the client timeout to the give milliseconds.
setTempDir(File) - Method in class org.apache.twill.internal.ApplicationBundler
Sets the temporary directory used by this class when generating new jars.
setTerminationStatus(ServiceController.TerminationStatus) - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
setUplink(int, ResourceSpecification.SizeUnit) - Method in class org.apache.twill.api.ResourceSpecification.Builder.AfterInstances
 
setUser(String) - Method in interface org.apache.twill.api.TwillPreparer
Deprecated.
This method will be removed in future version.
setVirtualCores(int) - Method in class org.apache.twill.api.ResourceSpecification.Builder.CoreSetter
 
shutDown() - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
shutDown() - Method in class org.apache.twill.internal.AbstractTwillService
 
shutDown() - Method in class org.apache.twill.internal.AbstractZKServiceController
 
shutDown() - Method in class org.apache.twill.internal.CompositeService
 
shutdown() - Method in class org.apache.twill.internal.ElectionRegistry
Stops all active LeaderElection processes.
shutDown() - Method in class org.apache.twill.internal.ServiceMain.TwillZKPathService
 
SingleRunnableApplication - Class in org.apache.twill.internal
A simple TwillApplication that contains only one TwillRunnable.
SingleRunnableApplication(TwillRunnable, ResourceSpecification) - Constructor for class org.apache.twill.internal.SingleRunnableApplication
 
start() - Method in interface org.apache.twill.api.TwillPreparer
Starts the application.
start(long, TimeUnit) - Method in interface org.apache.twill.api.TwillPreparer
Starts the application.
start() - Method in interface org.apache.twill.api.TwillRunnerService
Starts the service.
start() - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
start(RunId, int, Class<?>, String, Location) - Method in class org.apache.twill.internal.TwillContainerLauncher
Start execution run for a class in a container.
start() - Method in class org.apache.twill.yarn.YarnTwillRunnerService
 
start() - Method in class org.apache.twill.zookeeper.ForwardingZKClientService
 
startAndWait() - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
startAndWait() - Method in class org.apache.twill.zookeeper.ForwardingZKClientService
 
started() - Method in class org.apache.twill.api.EventHandler
Invoked by the application when it starts.
starting() - Method in class org.apache.twill.internal.ServiceListenerAdapter
 
startUp() - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
startUp() - Method in class org.apache.twill.internal.AbstractTwillService
 
startUp() - Method in class org.apache.twill.internal.AbstractZKServiceController
 
startUp() - Method in class org.apache.twill.internal.CompositeService
 
startUp() - Method in class org.apache.twill.internal.ServiceMain.TwillZKPathService
 
state() - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
state() - Method in class org.apache.twill.zookeeper.ForwardingZKClientService
 
stop() - Method in class org.apache.twill.api.AbstractTwillRunnable
 
stop() - Method in interface org.apache.twill.api.TwillRunnable
Requests to stop the running service.
stop() - Method in interface org.apache.twill.api.TwillRunnerService
Stops the service.
stop() - Method in class org.apache.twill.ext.BundledJarRunnable
 
stop() - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
stop() - Method in class org.apache.twill.internal.BasicTwillContext
Stops and frees any currently allocated resources.
stop() - Method in class org.apache.twill.yarn.YarnTwillRunnerService
 
stop() - Method in class org.apache.twill.zookeeper.ForwardingZKClientService
 
stopAndWait() - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
stopAndWait() - Method in class org.apache.twill.zookeeper.ForwardingZKClientService
 
stopping(Service.State) - Method in class org.apache.twill.internal.ServiceListenerAdapter
 
SUCCESS - Static variable in class org.apache.twill.internal.ContainerExitCodes
 

T

TEMP_FILE_SUFFIX - Static variable in interface org.apache.twill.filesystem.Location
Suffix added to every temp file name generated with Location.getTempFile(String).
terminate() - Method in interface org.apache.twill.api.ServiceController
Requests to terminate the running service.
terminate() - Method in class org.apache.twill.internal.AbstractExecutionServiceController
 
terminated(Service.State) - Method in class org.apache.twill.internal.ServiceListenerAdapter
 
Threads - Class in org.apache.twill.common
 
timeLimit(long, TimeUnit, RetryStrategy) - Static method in class org.apache.twill.zookeeper.RetryStrategies
Creates a RetryStrategy that will retry until maximum amount of time has been passed since the request, with the actual delay behavior delegated to another RetryStrategy.
TIMEOUT_SECONDS - Static variable in class org.apache.twill.internal.ServiceMain.TwillZKPathService
 
TimeoutEvent(String, int, int, long) - Constructor for class org.apache.twill.api.EventHandler.TimeoutEvent
 
toArray() - Method in class org.apache.twill.ext.BundledJarRunner.Arguments
 
TopicPartition - Class in org.apache.twill.kafka.client
Represents a combination of topic and partition.
TopicPartition(String, int) - Constructor for class org.apache.twill.kafka.client.TopicPartition
 
toString() - Method in class org.apache.twill.api.Hosts
 
toString() - Method in class org.apache.twill.api.Racks
 
toString() - Method in class org.apache.twill.discovery.Discoverable
 
toString() - Method in class org.apache.twill.internal.DefaultLocalFile
 
toString() - Method in class org.apache.twill.internal.DefaultResourceReport
 
toString() - Method in class org.apache.twill.internal.DefaultTwillRunResources
 
toString() - Method in class org.apache.twill.internal.DefaultTwillSpecification.DefaultOrder
 
toString() - Method in class org.apache.twill.internal.DefaultTwillSpecification.DefaultPlacementPolicy
 
toString() - Method in class org.apache.twill.internal.JvmOptions.DebugOptions
 
toString() - Method in class org.apache.twill.kafka.client.BrokerInfo
 
toString() - Method in class org.apache.twill.kafka.client.TopicPartition
 
toURI() - Method in interface org.apache.twill.filesystem.Location
 
TWILL_APP_NAME - Static variable in class org.apache.twill.internal.Constants
Constants for twill variable names.
TWILL_CONTAINER_CLASSLOADER - Static variable in class org.apache.twill.internal.Constants
Constant for the system property name that carries the class name for the container ClassLoader as defined by user.
TWILL_INSTANCE_COUNT - Static variable in class org.apache.twill.internal.EnvKeys
 
TWILL_INSTANCE_ID - Static variable in class org.apache.twill.internal.EnvKeys
 
TWILL_JAR - Static variable in class org.apache.twill.internal.Constants.Files
 
TWILL_RUN_ID - Static variable in class org.apache.twill.internal.EnvKeys
 
TWILL_RUNNABLE_NAME - Static variable in class org.apache.twill.internal.EnvKeys
Cluster filesystem directory for storing twill app related files.
TWILL_SPEC - Static variable in class org.apache.twill.internal.Constants.Files
 
TwillApplication - Interface in org.apache.twill.api
Represents a application that can be launched by Twill.
TwillContainerController - Interface in org.apache.twill.internal
A ServiceController that allows sending a message directly.
TwillContainerLauncher - Class in org.apache.twill.internal
This class helps launching a container.
TwillContainerLauncher(RuntimeSpecification, ContainerInfo, ProcessLauncher.PrepareLaunchContext, ZKClient, int, JvmOptions, int, double, Location) - Constructor for class org.apache.twill.internal.TwillContainerLauncher
 
TwillContext - Interface in org.apache.twill.api
Represents the runtime context of a TwillRunnable.
TwillController - Interface in org.apache.twill.api
For controlling a running application.
TwillLauncher - Class in org.apache.twill.launcher
A launcher for application from a archive jar.
TwillLauncher() - Constructor for class org.apache.twill.launcher.TwillLauncher
 
TwillPreparer - Interface in org.apache.twill.api
This interface exposes methods to set up the Twill runtime environment and start a Twill application.
TwillRunnable - Interface in org.apache.twill.api
The TwillRunnable interface should be implemented by any class whose instances are intended to be executed in a Twill cluster.
TwillRunnableSpecification - Interface in org.apache.twill.api
Represents a specification of a TwillRunnable.
TwillRunnableSpecification.Builder - Class in org.apache.twill.api
Builder for constructing TwillRunnableSpecification.
TwillRunnableSpecification.Builder.AfterConfigs - Class in org.apache.twill.api
 
TwillRunnableSpecification.Builder.AfterName - Class in org.apache.twill.api
 
TwillRunnableSpecification.Builder.NameSetter - Class in org.apache.twill.api
 
TwillRunner - Interface in org.apache.twill.api
This interface prepares execution of TwillRunnable and TwillApplication.
TwillRunner.LiveInfo - Interface in org.apache.twill.api
Interface to represents information of a live application.
TwillRunnerService - Interface in org.apache.twill.api
A TwillRunner that provides lifecycle management functions.
TwillRunResources - Interface in org.apache.twill.api
Information about the container the TwillRunnable is running in.
TwillRuntimeSpecification - Class in org.apache.twill.internal
Represents runtime specification of a TwillApplication.
TwillRuntimeSpecification(TwillSpecification, String, URI, String, RunId, String, String, Map<String, Map<String, String>>, Map<String, Integer>, Map<String, String>, Map<String, Map<String, String>>) - Constructor for class org.apache.twill.internal.TwillRuntimeSpecification
 
TwillSpecification - Interface in org.apache.twill.api
Represents specification of a TwillApplication.
TwillSpecification.Builder - Class in org.apache.twill.api
Builder for constructing instance of TwillSpecification.
TwillSpecification.Builder.AfterName - Class in org.apache.twill.api
 
TwillSpecification.Builder.AfterOrder - Interface in org.apache.twill.api
 
TwillSpecification.Builder.AfterPlacementPolicy - Interface in org.apache.twill.api
Interface to define execution order after adding placement policies.
TwillSpecification.Builder.AfterRunnable - Interface in org.apache.twill.api
 
TwillSpecification.Builder.FirstOrder - Interface in org.apache.twill.api
 
TwillSpecification.Builder.LocalFileAdder - Interface in org.apache.twill.api
 
TwillSpecification.Builder.MoreFile - Class in org.apache.twill.api
 
TwillSpecification.Builder.MorePlacementPolicies - Interface in org.apache.twill.api
Interface to add placement policies to the application.
TwillSpecification.Builder.MoreRunnable - Interface in org.apache.twill.api
 
TwillSpecification.Builder.NameSetter - Class in org.apache.twill.api
 
TwillSpecification.Builder.NextOrder - Interface in org.apache.twill.api
 
TwillSpecification.Builder.OrderSetter - Class in org.apache.twill.api
 
TwillSpecification.Builder.PlacementPolicySetter - Class in org.apache.twill.api
 
TwillSpecification.Builder.RunnableSetter - Class in org.apache.twill.api
 
TwillSpecification.Builder.RuntimeSpecificationAdder - Class in org.apache.twill.api
For setting runtime specific settings.
TwillSpecification.Order - Interface in org.apache.twill.api
Defines execution order.
TwillSpecification.Order.Type - Enum in org.apache.twill.api
 
TwillSpecification.PlacementPolicy - Interface in org.apache.twill.api
Defines a container placement policy.
TwillSpecification.PlacementPolicy.Type - Enum in org.apache.twill.api
Lists different types of Placement Policies available.
TwillZKPathService(ZKClient, RunId) - Constructor for class org.apache.twill.internal.ServiceMain.TwillZKPathService
 

U

update(String, RunId) - Method in interface org.apache.twill.api.SecureStoreUpdater
Deprecated.
Invoked when an update to SecureStore is needed.
updated(T) - Method in interface org.apache.twill.zookeeper.ZKOperations.Callback
 
updated(NodeChildren) - Method in interface org.apache.twill.zookeeper.ZKOperations.ChildrenCallback
 
updated(NodeData) - Method in interface org.apache.twill.zookeeper.ZKOperations.DataCallback
Invoked when data of the node changed.
updateLiveNode() - Method in class org.apache.twill.internal.AbstractTwillService
Update the live node for the service.
updateLogLevels(Map<String, LogEntry.Level>) - Method in interface org.apache.twill.api.TwillController
Update the log levels for requested logger names for Twill applications running in a container.
updateLogLevels(String, Map<String, LogEntry.Level>) - Method in interface org.apache.twill.api.TwillController
Update the log levels for requested logger names for a TwillRunnable.
updateLogLevels(Map<String, LogEntry.Level>) - Method in class org.apache.twill.internal.AbstractTwillController
 
updateLogLevels(String, Map<String, LogEntry.Level>) - Method in class org.apache.twill.internal.AbstractTwillController
 

V

valueOf(String) - Static method in enum org.apache.twill.api.logging.LogEntry.Level
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum org.apache.twill.api.ResourceSpecification.SizeUnit
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum org.apache.twill.api.ServiceController.TerminationStatus
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum org.apache.twill.api.TwillSpecification.Order.Type
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum org.apache.twill.api.TwillSpecification.PlacementPolicy.Type
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum org.apache.twill.kafka.client.Compression
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum org.apache.twill.kafka.client.KafkaPublisher.Ack
Returns the enum constant of this type with the specified name.
valueOf(String) - Static method in enum org.apache.twill.zookeeper.RetryStrategy.OperationType
Returns the enum constant of this type with the specified name.
values() - Static method in enum org.apache.twill.api.logging.LogEntry.Level
Returns an array containing the constants of this enum type, in the order they are declared.
values() - Static method in enum org.apache.twill.api.ResourceSpecification.SizeUnit
Returns an array containing the constants of this enum type, in the order they are declared.
values() - Static method in enum org.apache.twill.api.ServiceController.TerminationStatus
Returns an array containing the constants of this enum type, in the order they are declared.
values() - Static method in enum org.apache.twill.api.TwillSpecification.Order.Type
Returns an array containing the constants of this enum type, in the order they are declared.
values() - Static method in enum org.apache.twill.api.TwillSpecification.PlacementPolicy.Type
Returns an array containing the constants of this enum type, in the order they are declared.
values() - Static method in enum org.apache.twill.kafka.client.Compression
Returns an array containing the constants of this enum type, in the order they are declared.
values() - Static method in enum org.apache.twill.kafka.client.KafkaPublisher.Ack
Returns an array containing the constants of this enum type, in the order they are declared.
values() - Static method in enum org.apache.twill.zookeeper.RetryStrategy.OperationType
Returns an array containing the constants of this enum type, in the order they are declared.

W

watchChanges(ServiceDiscovered.ChangeListener, Executor) - Method in interface org.apache.twill.discovery.ServiceDiscovered
Registers a ServiceDiscovered.ChangeListener to watch for changes in the discovery list.
watchChildren(ZKClient, String, ZKOperations.ChildrenCallback) - Static method in class org.apache.twill.zookeeper.ZKOperations
 
watchData(ZKClient, String, ZKOperations.DataCallback) - Static method in class org.apache.twill.zookeeper.ZKOperations
Watch for data changes of the given path.
watchDeleted(ZKClient, String) - Static method in class org.apache.twill.zookeeper.ZKOperations
 
watchDeleted(ZKClient, String, SettableFuture<String>) - Static method in class org.apache.twill.zookeeper.ZKOperations
 
watchInstanceNode() - Method in class org.apache.twill.internal.AbstractZKServiceController
 
with() - Static method in class org.apache.twill.api.ResourceSpecification.Builder
 
with() - Static method in class org.apache.twill.api.TwillRunnableSpecification.Builder
 
with() - Static method in class org.apache.twill.api.TwillSpecification.Builder
 
withApplicationArguments(String...) - Method in interface org.apache.twill.api.TwillPreparer
Sets the list of arguments that will be passed to the application.
withApplicationArguments(Iterable<String>) - Method in interface org.apache.twill.api.TwillPreparer
Sets the list of arguments that will be passed to the application.
withApplicationClassPaths(String...) - Method in interface org.apache.twill.api.TwillPreparer
Adds the set of paths to the classpath on the target machine for ApplicationMaster and all runnables.
withApplicationClassPaths(Iterable<String>) - Method in interface org.apache.twill.api.TwillPreparer
Adds the set of paths to the classpath on the target machine for ApplicationMaster and all runnables.
withArguments(String, String...) - Method in interface org.apache.twill.api.TwillPreparer
Sets the list of arguments that will be passed to the TwillRunnable identified by the given name.
withArguments(String, Iterable<String>) - Method in interface org.apache.twill.api.TwillPreparer
Sets the list of arguments that will be passed to the TwillRunnable identified by the given name.
withBundlerClassAcceptor(ClassAcceptor) - Method in interface org.apache.twill.api.TwillPreparer
Uses ClassAcceptor to determine the classes to include in the bundle jar for ApplicationMaster and all runnables.
withClassPaths(String...) - Method in interface org.apache.twill.api.TwillPreparer
Adds the set of paths to the classpath on the target machine for all runnables.
withClassPaths(Iterable<String>) - Method in interface org.apache.twill.api.TwillPreparer
Adds the set of paths to the classpath on the target machine for all runnables.
withConfigs(Map<String, String>) - Method in class org.apache.twill.api.TwillRunnableSpecification.Builder.AfterName
 
withConfiguration(Map<String, String>) - Method in interface org.apache.twill.api.TwillPreparer
Overrides the default configuration with the given set of configurations.
withConfiguration(String, Map<String, String>) - Method in interface org.apache.twill.api.TwillPreparer
Overrides the default configuration with the given set of configurations for the given runnable only.
withDependencies(Class<?>...) - Method in interface org.apache.twill.api.TwillPreparer
Adds extra classes that the application is dependent on and is not traceable from the application itself.
withDependencies(Iterable<Class<?>>) - Method in interface org.apache.twill.api.TwillPreparer
Adds extra classes that the application is dependent on and is not traceable from the application itself.
withEnv(Map<String, String>) - Method in interface org.apache.twill.api.TwillPreparer
Adds the set of environment variables that will be set as container environment variables for all runnables.
withEnv(String, Map<String, String>) - Method in interface org.apache.twill.api.TwillPreparer
Adds the set of environment variables that will be set as container environment variables for the given runnable.
withEventHandler(EventHandler) - Method in interface org.apache.twill.api.TwillSpecification.Builder.AfterOrder
 
withEventHandler(EventHandler) - Method in class org.apache.twill.api.TwillSpecification.Builder.OrderSetter
 
withLocalFiles() - Method in class org.apache.twill.api.TwillSpecification.Builder.RuntimeSpecificationAdder
 
withMaxRetries(String, int) - Method in interface org.apache.twill.api.TwillPreparer
Sets the maximum number of times (per instance) a runnable will be retried if it exits without success.
withOrder() - Method in interface org.apache.twill.api.TwillSpecification.Builder.AfterPlacementPolicy
Start defining execution order.
withOrder() - Method in interface org.apache.twill.api.TwillSpecification.Builder.AfterRunnable
 
withOrder() - Method in class org.apache.twill.api.TwillSpecification.Builder.PlacementPolicySetter
 
withOrder() - Method in class org.apache.twill.api.TwillSpecification.Builder.RunnableSetter
 
withPlacementPolicy() - Method in interface org.apache.twill.api.TwillSpecification.Builder.AfterRunnable
 
withPlacementPolicy() - Method in class org.apache.twill.api.TwillSpecification.Builder.RunnableSetter
 
withResources(URI...) - Method in interface org.apache.twill.api.TwillPreparer
Adds resources that will be available through the ClassLoader of the runnables.
withResources(Iterable<URI>) - Method in interface org.apache.twill.api.TwillPreparer
Adds resources that will be available through the ClassLoader of the runnables.
withRunnable() - Method in class org.apache.twill.api.TwillSpecification.Builder.AfterName
 
write(SecureStore) - Method in interface org.apache.twill.api.security.SecureStoreWriter
Writes the given SecureStore.

Y

YARN_AM_MEMORY_MB - Static variable in class org.apache.twill.api.Configs.Defaults
Default AM container memory size.
YARN_AM_MEMORY_MB - Static variable in class org.apache.twill.api.Configs.Keys
Size in MB for the memory size of the YARN application master container.
YARN_AM_RESERVED_MEMORY_MB - Static variable in class org.apache.twill.api.Configs.Defaults
Default AM JVM reserved memory.
YARN_AM_RESERVED_MEMORY_MB - Static variable in class org.apache.twill.api.Configs.Keys
Size in MB for the reserved non-heap memory size for the YARN application Java process.
YARN_APP_ID - Static variable in class org.apache.twill.internal.EnvKeys
 
YARN_APP_ID_CLUSTER_TIME - Static variable in class org.apache.twill.internal.EnvKeys
 
YARN_APP_ID_STR - Static variable in class org.apache.twill.internal.EnvKeys
 
YARN_ATTEMPT_FAILURES_VALIDITY_INTERVAL - Static variable in class org.apache.twill.api.Configs.Keys
Interval time in milliseconds for the attempt failures validity interval in YARN.
YARN_CONTAINER_HOST - Static variable in class org.apache.twill.internal.EnvKeys
 
YARN_CONTAINER_ID - Static variable in class org.apache.twill.internal.EnvKeys
 
YARN_CONTAINER_MEMORY_MB - Static variable in class org.apache.twill.internal.EnvKeys
 
YARN_CONTAINER_PORT - Static variable in class org.apache.twill.internal.EnvKeys
 
YARN_CONTAINER_VIRTUAL_CORES - Static variable in class org.apache.twill.internal.EnvKeys
Used to inform runnables of their resource usage.
YARN_MAX_APP_ATTEMPTS - Static variable in class org.apache.twill.api.Configs.Keys
Maximum number of attempts to run the application by YARN if there is failure.
YarnSecureStore - Class in org.apache.twill.yarn
A SecureStore for hadoop credentials.
YarnTwillRunnerService - Class in org.apache.twill.yarn
An implementation of TwillRunnerService that runs application on a YARN cluster.
YarnTwillRunnerService(YarnConfiguration, String) - Constructor for class org.apache.twill.yarn.YarnTwillRunnerService
Creates an instance with a FileContextLocationFactory created base on the given configuration with the user home directory as the location factory namespace.
YarnTwillRunnerService(YarnConfiguration, String, LocationFactory) - Constructor for class org.apache.twill.yarn.YarnTwillRunnerService
Creates an instance.

Z

zkClient - Variable in class org.apache.twill.internal.AbstractTwillService
 
zkClient - Variable in class org.apache.twill.internal.AbstractZKServiceController
 
ZKClient - Interface in org.apache.twill.zookeeper
A ZooKeeper client that provides asynchronous zookeeper operations.
ZKClients - Class in org.apache.twill.zookeeper
Utility class to create ZKClient instances.
ZKClientService - Interface in org.apache.twill.zookeeper
A ZKClient that extends from Service to provide lifecycle management functions.
ZKClientService.Builder - Class in org.apache.twill.zookeeper
Builder for creating an implementation of ZKClientService.
ZKClientServices - Class in org.apache.twill.zookeeper
Provides static factory method to create ZKClientService with modified behaviors.
ZKDiscoveryService - Class in org.apache.twill.discovery
Zookeeper implementation of DiscoveryService and DiscoveryServiceClient.
ZKDiscoveryService(ZKClient) - Constructor for class org.apache.twill.discovery.ZKDiscoveryService
Constructs ZKDiscoveryService using the provided zookeeper client for storing service registry.
ZKDiscoveryService(ZKClient, String) - Constructor for class org.apache.twill.discovery.ZKDiscoveryService
Constructs ZKDiscoveryService using the provided zookeeper client for storing service registry under namespace.
ZKMessages - Class in org.apache.twill.internal
Helper class to send messages to remote instances using Apache Zookeeper watch mechanism.
ZKOperations - Class in org.apache.twill.zookeeper
Collection of helper methods for common operations that usually needed when interacting with ZooKeeper.
ZKOperations.Callback<T> - Interface in org.apache.twill.zookeeper
Represents a ZK operation updates callback.
ZKOperations.ChildrenCallback - Interface in org.apache.twill.zookeeper
Interface for defining callback method to receive children nodes updates.
ZKOperations.DataCallback - Interface in org.apache.twill.zookeeper
Interface for defining callback method to receive node data updates.
A B C D E F G H I J K L M N O P R S T U V W Y Z 
Skip navigation links

Copyright © 2013-2020 The Apache Software Foundation. All rights reserved.