runnableSpec.getResourceSpecification().getVirtualCores(),
runnableSpec.getResourceSpecification().getMemorySize(),
discoveryServiceClient, dService, instanceCount, electionRegistry);
TypeToken<? extends TwillRunnable> runnableType = TypeToken.of(runnableClass);
TwillRunnable runnable = null;
if (runnableClass.isAssignableFrom(HttpServiceTwillRunnable.class)) {
// Special case for running HTTP services
runnable = new HttpServiceTwillRunnable(program, runId, cConfiguration, runnableName, metricsCollectionService,
discoveryServiceClient, datasetFramework,