public abstract class ServiceMain extends Object
Modifier and Type | Class and Description |
---|---|
protected static class |
ServiceMain.TwillZKPathService
A simple service for creating/remove ZK paths needed for
AbstractTwillService . |
Constructor and Description |
---|
ServiceMain() |
Modifier and Type | Method and Description |
---|---|
protected Location |
createAppLocation(org.apache.hadoop.conf.Configuration conf,
String fsUser,
URI appDir)
Returns the
Location for the application based on the app directory. |
protected ZKClientService |
createZKClient()
Creates a
ZKClientService . |
protected void |
doMain(com.google.common.util.concurrent.Service mainService,
com.google.common.util.concurrent.Service... prerequisites) |
protected abstract String |
getHostname() |
protected abstract String |
getRunnableName()
Returns the name of the runnable that this running inside this process.
|
protected abstract TwillRuntimeSpecification |
getTwillRuntimeSpecification()
Returns the
TwillRuntimeSpecification for this application. |
protected final void doMain(com.google.common.util.concurrent.Service mainService, com.google.common.util.concurrent.Service... prerequisites) throws Exception
Exception
protected abstract String getHostname()
protected abstract TwillRuntimeSpecification getTwillRuntimeSpecification()
TwillRuntimeSpecification
for this application.@Nullable protected abstract String getRunnableName()
protected final Location createAppLocation(org.apache.hadoop.conf.Configuration conf, String fsUser, URI appDir)
Location
for the application based on the app directory.protected final ZKClientService createZKClient()
ZKClientService
.Copyright © 2013-2020 The Apache Software Foundation. All rights reserved.