public class KubernetesManager extends Object implements KubernetesManagerMXBean
Modifier and Type | Field and Description |
---|---|
static ObjectName |
OBJECT_NAME |
Constructor and Description |
---|
KubernetesManager() |
Modifier and Type | Method and Description |
---|---|
protected String |
addPortToIP(String podIP,
Integer containerPort,
String portNumberOrName) |
String |
apply(String json)
Takes the blob of Kubernetes JSON (pod, replication controller, service, config, template etc)
and applies it to the runtime environment so that any changes or new items take effect
|
protected Controller |
createController() |
void |
destroy() |
String |
getDockerRegistry() |
KubernetesClient |
getKubernetes() |
String |
getPodUrl(String name,
String portNumberOrName)
Returns the pod IP of the given pod name
|
String |
getReplicationControllerIdForPod(String podId)
Returns the replication controller ID for the given pod id if one can be found or null if not
|
String |
getServiceUrl(String serviceName)
Returns the service URL of the given service name
|
void |
init() |
void |
setKubernetes(KubernetesClient kubernetes) |
public static ObjectName OBJECT_NAME
public void init()
public void destroy()
public String apply(String json) throws IOException
KubernetesManagerMXBean
apply
in interface KubernetesManagerMXBean
IOException
public String getServiceUrl(String serviceName)
getServiceUrl
in interface KubernetesManagerMXBean
public String getPodUrl(String name, String portNumberOrName)
getPodUrl
in interface KubernetesManagerMXBean
protected String addPortToIP(String podIP, Integer containerPort, String portNumberOrName)
public String getDockerRegistry()
getDockerRegistry
in interface KubernetesManagerMXBean
public String getReplicationControllerIdForPod(String podId)
KubernetesManagerMXBean
getReplicationControllerIdForPod
in interface KubernetesManagerMXBean
public KubernetesClient getKubernetes()
public void setKubernetes(KubernetesClient kubernetes)
protected Controller createController()
Copyright © 2011–2014 Red Hat. All rights reserved.