public interface TwillRunner
TwillRunnable and TwillApplication.| Modifier and Type | Interface and Description |
|---|---|
static interface |
TwillRunner.LiveInfo
Interface to represents information of a live application.
|
| Modifier and Type | Method and Description |
|---|---|
Iterable<TwillController> |
lookup(String applicationName)
Gets an
Iterable of TwillController for all running instances of the given application. |
TwillController |
lookup(String applicationName,
RunId runId)
Gets a
TwillController for the given application and runId. |
Iterable<TwillRunner.LiveInfo> |
lookupLive()
Gets an
Iterable of TwillRunner.LiveInfo. |
TwillPreparer |
prepare(TwillApplication application)
Prepares to run the given
TwillApplication as specified by the application. |
TwillPreparer |
prepare(TwillRunnable runnable)
Prepares to run the given
TwillRunnable with ResourceSpecification.BASIC resource specification. |
TwillPreparer |
prepare(TwillRunnable runnable,
ResourceSpecification resourceSpecification)
Prepares to run the given
TwillRunnable with the given resource specification. |
Cancellable |
scheduleSecureStoreUpdate(SecureStoreUpdater updater,
long initialDelay,
long delay,
TimeUnit unit)
Schedules a periodic update of SecureStore.
|
TwillPreparer prepare(TwillRunnable runnable)
TwillRunnable with ResourceSpecification.BASIC resource specification.runnable - The runnable to run through Twill when TwillPreparer.start() is called.TwillPreparer for setting up runtime options.TwillPreparer prepare(TwillRunnable runnable, ResourceSpecification resourceSpecification)
TwillRunnable with the given resource specification.runnable - The runnable to run through Twill when TwillPreparer.start() is called.resourceSpecification - The resource specification for running the runnable.TwillPreparer for setting up runtime options.TwillPreparer prepare(TwillApplication application)
TwillApplication as specified by the application.application - The application to run through Twill when TwillPreparer.start() is called.TwillPreparer for setting up runtime options.TwillController lookup(String applicationName, RunId runId)
TwillController for the given application and runId.applicationName - Name of the application.runId - The runId of the running application.TwillController to interact with the application or null if no such runId is found.Iterable<TwillController> lookup(String applicationName)
Iterable of TwillController for all running instances of the given application.applicationName - Name of the application.Iterable that gives the latest TwillController set for all running
instances of the application when Iterable.iterator() is invoked.Iterable<TwillRunner.LiveInfo> lookupLive()
Iterable of TwillRunner.LiveInfo.Iterable that gives the latest information on the set of applications that
have running instances when Iterable.iterator()} is invoked.Cancellable scheduleSecureStoreUpdate(SecureStoreUpdater updater, long initialDelay, long delay, TimeUnit unit)
SecureStoreUpdater will be made
after initialDelay, and subsequently with the given delay between completion of one update
and starting of the next. If exception is thrown on call
SecureStoreUpdater.update(String, RunId), the exception will only get logged
and won't suppress the next update call.updater - A SecureStoreUpdater for creating new SecureStore.initialDelay - Delay before the first call to update method.delay - Delay between completion of one update call to the next one.unit - time unit for the initialDelay and delay.Cancellable for cancelling the scheduled update.Copyright © 2013-2015 The Apache Software Foundation. All rights reserved.