Class VirtualService
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.core.Construct
software.amazon.awscdk.core.Resource
software.amazon.awscdk.services.appmesh.VirtualService
- All Implemented Interfaces:
IConstruct
,IDependable
,IResource
,IVirtualService
,software.amazon.jsii.JsiiSerializable
,software.constructs.IConstruct
@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)",
date="2023-06-19T16:30:46.200Z")
@Stability(Stable)
public class VirtualService
extends Resource
implements IVirtualService
VirtualService represents a service inside an AppMesh.
It routes traffic either to a Virtual Node or to a Virtual Router.
Example:
Mesh mesh; VirtualNode node = VirtualNode.Builder.create(this, "node") .mesh(mesh) .serviceDiscovery(ServiceDiscovery.dns("node")) .build(); VirtualService virtualService = VirtualService.Builder.create(this, "service-1") .virtualServiceProvider(VirtualServiceProvider.virtualNode(node)) .virtualServiceName("service1.domain.local") .build(); node.addBackend(Backend.virtualService(virtualService));
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
Nested classes/interfaces inherited from interface software.amazon.awscdk.core.IConstruct
IConstruct.Jsii$Default
Nested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$Default
Nested classes/interfaces inherited from interface software.amazon.awscdk.core.IResource
IResource.Jsii$Default
Nested classes/interfaces inherited from interface software.amazon.awscdk.services.appmesh.IVirtualService
IVirtualService.Jsii$Default, IVirtualService.Jsii$Proxy
-
Constructor Summary
ModifierConstructorDescriptionprotected
VirtualService
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
VirtualService
(software.amazon.jsii.JsiiObjectRef objRef) VirtualService
(software.constructs.Construct scope, String id, VirtualServiceProps props) -
Method Summary
Modifier and TypeMethodDescriptionstatic IVirtualService
fromVirtualServiceArn
(software.constructs.Construct scope, String id, String virtualServiceArn) Import an existing VirtualService given an ARN.static IVirtualService
fromVirtualServiceAttributes
(software.constructs.Construct scope, String id, VirtualServiceAttributes attrs) Import an existing VirtualService given its attributes.getMesh()
The Mesh which the VirtualService belongs to.The Amazon Resource Name (ARN) for the virtual service.The name of the VirtualService, it is recommended this follows the fully-qualified domain name format.Methods inherited from class software.amazon.awscdk.core.Resource
applyRemovalPolicy, generatePhysicalName, getEnv, getPhysicalName, getResourceArnAttribute, getResourceNameAttribute, getStack, isResource
Methods inherited from class software.amazon.awscdk.core.Construct
getNode, isConstruct, onPrepare, onSynthesize, onValidate, prepare, synthesize, validate
Methods inherited from class software.constructs.Construct
toString
Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface software.amazon.awscdk.core.IConstruct
getNode
Methods inherited from interface software.amazon.awscdk.core.IResource
applyRemovalPolicy, getEnv, getStack
Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Constructor Details
-
VirtualService
protected VirtualService(software.amazon.jsii.JsiiObjectRef objRef) -
VirtualService
protected VirtualService(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
VirtualService
@Stability(Stable) public VirtualService(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull VirtualServiceProps props) - Parameters:
scope
- This parameter is required.id
- This parameter is required.props
- This parameter is required.
-
-
Method Details
-
fromVirtualServiceArn
@Stability(Stable) @NotNull public static IVirtualService fromVirtualServiceArn(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String virtualServiceArn) Import an existing VirtualService given an ARN.- Parameters:
scope
- This parameter is required.id
- This parameter is required.virtualServiceArn
- This parameter is required.
-
fromVirtualServiceAttributes
@Stability(Stable) @NotNull public static IVirtualService fromVirtualServiceAttributes(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull VirtualServiceAttributes attrs) Import an existing VirtualService given its attributes.- Parameters:
scope
- This parameter is required.id
- This parameter is required.attrs
- This parameter is required.
-
getMesh
The Mesh which the VirtualService belongs to.- Specified by:
getMesh
in interfaceIVirtualService
-
getVirtualServiceArn
The Amazon Resource Name (ARN) for the virtual service.- Specified by:
getVirtualServiceArn
in interfaceIVirtualService
-
getVirtualServiceName
The name of the VirtualService, it is recommended this follows the fully-qualified domain name format.- Specified by:
getVirtualServiceName
in interfaceIVirtualService
-