Show / Hide Table of Contents

Class RouteBaseProps

Base interface properties for all Routes.

Inheritance
object
RouteBaseProps
Implements
IRouteBaseProps
Inherited Members
object.GetType()
object.MemberwiseClone()
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
Namespace: Amazon.CDK.AWS.AppMesh
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class RouteBaseProps : IRouteBaseProps
Syntax (vb)
Public Class RouteBaseProps Implements IRouteBaseProps
Remarks

ExampleMetadata: infused

Examples
VirtualRouter router;
            VirtualNode node;


            router.AddRoute("route-http2-retry", new RouteBaseProps {
                RouteSpec = RouteSpec.Http2(new HttpRouteSpecOptions {
                    WeightedTargets = new [] { new WeightedTarget { VirtualNode = node } },
                    RetryPolicy = new HttpRetryPolicy {
                        // Retry if the connection failed
                        TcpRetryEvents = new [] { TcpRetryEvent.CONNECTION_ERROR },
                        // Retry if HTTP responds with a gateway error (502, 503, 504)
                        HttpRetryEvents = new [] { HttpRetryEvent.GATEWAY_ERROR },
                        // Retry five times
                        RetryAttempts = 5,
                        // Use a 1 second timeout per retry
                        RetryTimeout = Duration.Seconds(1)
                    }
                })
            });

Synopsis

Constructors

RouteBaseProps()

Base interface properties for all Routes.

Properties

RouteName

The name of the route.

RouteSpec

Protocol specific spec.

Constructors

RouteBaseProps()

Base interface properties for all Routes.

public RouteBaseProps()
Remarks

ExampleMetadata: infused

Examples
VirtualRouter router;
            VirtualNode node;


            router.AddRoute("route-http2-retry", new RouteBaseProps {
                RouteSpec = RouteSpec.Http2(new HttpRouteSpecOptions {
                    WeightedTargets = new [] { new WeightedTarget { VirtualNode = node } },
                    RetryPolicy = new HttpRetryPolicy {
                        // Retry if the connection failed
                        TcpRetryEvents = new [] { TcpRetryEvent.CONNECTION_ERROR },
                        // Retry if HTTP responds with a gateway error (502, 503, 504)
                        HttpRetryEvents = new [] { HttpRetryEvent.GATEWAY_ERROR },
                        // Retry five times
                        RetryAttempts = 5,
                        // Use a 1 second timeout per retry
                        RetryTimeout = Duration.Seconds(1)
                    }
                })
            });

Properties

RouteName

The name of the route.

public string? RouteName { get; set; }
Property Value

string

Remarks

Default: - An automatically generated name

RouteSpec

Protocol specific spec.

public RouteSpec RouteSpec { get; set; }
Property Value

RouteSpec

Remarks

ExampleMetadata: infused

Implements

IRouteBaseProps
Back to top Generated by DocFX