@Singleton public class RunningInstanceToNodeMetadata extends Object implements com.google.common.base.Function<RunningInstance,NodeMetadata>
Modifier and Type | Field and Description |
---|---|
protected Map<String,Credentials> |
credentialStore |
protected com.google.common.base.Supplier<Set<? extends Hardware>> |
hardware |
protected com.google.common.base.Supplier<com.google.common.cache.LoadingCache<RegionAndName,? extends Image>> |
imageMap |
protected Map<InstanceState,NodeMetadata.Status> |
instanceToNodeStatus |
protected com.google.common.base.Supplier<Set<? extends Location>> |
locations |
protected Logger |
logger |
protected GroupNamingConvention.Factory |
namingConvention |
Modifier | Constructor and Description |
---|---|
protected |
RunningInstanceToNodeMetadata(Map<InstanceState,NodeMetadata.Status> instanceToNodeStatus,
Map<String,Credentials> credentialStore,
com.google.common.base.Supplier<com.google.common.cache.LoadingCache<RegionAndName,? extends Image>> imageMap,
com.google.common.base.Supplier<Set<? extends Location>> locations,
com.google.common.base.Supplier<Set<? extends Hardware>> hardware,
GroupNamingConvention.Factory namingConvention) |
Modifier and Type | Method and Description |
---|---|
protected void |
addCredentialsForInstance(NodeMetadataBuilder builder,
RunningInstance instance) |
NodeMetadata |
apply(RunningInstance instance) |
protected Hardware |
parseHardware(RunningInstance instance) |
protected Logger logger
protected final com.google.common.base.Supplier<com.google.common.cache.LoadingCache<RegionAndName,? extends Image>> imageMap
protected final Map<String,Credentials> credentialStore
protected final Map<InstanceState,NodeMetadata.Status> instanceToNodeStatus
protected final GroupNamingConvention.Factory namingConvention
@Inject protected RunningInstanceToNodeMetadata(Map<InstanceState,NodeMetadata.Status> instanceToNodeStatus, Map<String,Credentials> credentialStore, com.google.common.base.Supplier<com.google.common.cache.LoadingCache<RegionAndName,? extends Image>> imageMap, com.google.common.base.Supplier<Set<? extends Location>> locations, com.google.common.base.Supplier<Set<? extends Hardware>> hardware, GroupNamingConvention.Factory namingConvention)
public NodeMetadata apply(RunningInstance instance)
apply
in interface com.google.common.base.Function<RunningInstance,NodeMetadata>
protected void addCredentialsForInstance(NodeMetadataBuilder builder, RunningInstance instance)
protected Hardware parseHardware(RunningInstance instance)
Copyright © 2009-2014 The Apache Software Foundation. All Rights Reserved.