@Generated(value="jsii-pacmak/1.71.0 (build f1f58ae)", date="2022-12-07T17:24:46.742Z") @Stability(value=Stable) public class KubernetesObjectValue extends Construct
Use this to fetch any information available by the kubectl get command.
Example:
Cluster cluster;
// query the load balancer address
KubernetesObjectValue myServiceAddress = KubernetesObjectValue.Builder.create(this, "LoadBalancerAttribute")
.cluster(cluster)
.objectType("service")
.objectName("my-service")
.jsonPath(".status.loadBalancer.ingress[0].hostname")
.build();
// pass the address to a lambda function
Function proxyFunction = Function.Builder.create(this, "ProxyFunction")
.handler("index.handler")
.code(Code.fromInline("my-code"))
.runtime(Runtime.NODEJS_14_X)
.environment(Map.of(
"myServiceAddress", myServiceAddress.getValue()))
.build();
| Modifier and Type | Class and Description |
|---|---|
static class |
KubernetesObjectValue.Builder
A fluent builder for
KubernetesObjectValue. |
software.amazon.jsii.JsiiObject.InitializationModeIConstruct.Jsii$Default, IConstruct.Jsii$Proxy| Modifier and Type | Field and Description |
|---|---|
static String |
RESOURCE_TYPE
The CloudFormation reosurce type.
|
| Modifier | Constructor and Description |
|---|---|
|
KubernetesObjectValue(software.constructs.Construct scope,
String id,
KubernetesObjectValueProps props) |
protected |
KubernetesObjectValue(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
KubernetesObjectValue(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
String |
getValue()
The value as a string token.
|
getNode, isConstruct, onPrepare, onSynthesize, onValidate, prepare, synthesize, validatejsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet@Stability(value=Stable) public static final String RESOURCE_TYPE
protected KubernetesObjectValue(software.amazon.jsii.JsiiObjectRef objRef)
protected KubernetesObjectValue(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable)
public KubernetesObjectValue(@NotNull
software.constructs.Construct scope,
@NotNull
String id,
@NotNull
KubernetesObjectValueProps props)
scope - This parameter is required.id - This parameter is required.props - This parameter is required.@Stability(value=Stable) @NotNull public String getValue()
Copyright © 2022. All rights reserved.