1. Packages
  2. Google Cloud Native
  3. API Docs
  4. networkservices
  5. networkservices/v1
  6. getTcpRoute

Google Cloud Native is in preview. Google Cloud Classic is fully supported.

Google Cloud Native v0.32.0 published on Wednesday, Nov 29, 2023 by Pulumi

google-native.networkservices/v1.getTcpRoute

Explore with Pulumi AI

google-native logo

Google Cloud Native is in preview. Google Cloud Classic is fully supported.

Google Cloud Native v0.32.0 published on Wednesday, Nov 29, 2023 by Pulumi

    Gets details of a single TcpRoute.

    Using getTcpRoute

    Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

    function getTcpRoute(args: GetTcpRouteArgs, opts?: InvokeOptions): Promise<GetTcpRouteResult>
    function getTcpRouteOutput(args: GetTcpRouteOutputArgs, opts?: InvokeOptions): Output<GetTcpRouteResult>
    def get_tcp_route(location: Optional[str] = None,
                      project: Optional[str] = None,
                      tcp_route_id: Optional[str] = None,
                      opts: Optional[InvokeOptions] = None) -> GetTcpRouteResult
    def get_tcp_route_output(location: Optional[pulumi.Input[str]] = None,
                      project: Optional[pulumi.Input[str]] = None,
                      tcp_route_id: Optional[pulumi.Input[str]] = None,
                      opts: Optional[InvokeOptions] = None) -> Output[GetTcpRouteResult]
    func LookupTcpRoute(ctx *Context, args *LookupTcpRouteArgs, opts ...InvokeOption) (*LookupTcpRouteResult, error)
    func LookupTcpRouteOutput(ctx *Context, args *LookupTcpRouteOutputArgs, opts ...InvokeOption) LookupTcpRouteResultOutput

    > Note: This function is named LookupTcpRoute in the Go SDK.

    public static class GetTcpRoute 
    {
        public static Task<GetTcpRouteResult> InvokeAsync(GetTcpRouteArgs args, InvokeOptions? opts = null)
        public static Output<GetTcpRouteResult> Invoke(GetTcpRouteInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetTcpRouteResult> getTcpRoute(GetTcpRouteArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: google-native:networkservices/v1:getTcpRoute
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Location string
    TcpRouteId string
    Project string
    Location string
    TcpRouteId string
    Project string
    location String
    tcpRouteId String
    project String
    location string
    tcpRouteId string
    project string
    location String
    tcpRouteId String
    project String

    getTcpRoute Result

    The following output properties are available:

    CreateTime string
    The timestamp when the resource was created.
    Description string
    Optional. A free-text description of the resource. Max length 1024 characters.
    Gateways List<string>
    Optional. Gateways defines a list of gateways this TcpRoute is attached to, as one of the routing rules to route the requests served by the gateway. Each gateway reference should match the pattern: projects/*/locations/global/gateways/
    Labels Dictionary<string, string>
    Optional. Set of label tags associated with the TcpRoute resource.
    Meshes List<string>
    Optional. Meshes defines a list of meshes this TcpRoute is attached to, as one of the routing rules to route the requests served by the mesh. Each mesh reference should match the pattern: projects/*/locations/global/meshes/ The attached Mesh should be of a type SIDECAR
    Name string
    Name of the TcpRoute resource. It matches pattern projects/*/locations/global/tcpRoutes/tcp_route_name>.
    Rules List<Pulumi.GoogleNative.NetworkServices.V1.Outputs.TcpRouteRouteRuleResponse>
    Rules that define how traffic is routed and handled. At least one RouteRule must be supplied. If there are multiple rules then the action taken will be the first rule to match.
    SelfLink string
    Server-defined URL of this resource
    UpdateTime string
    The timestamp when the resource was updated.
    CreateTime string
    The timestamp when the resource was created.
    Description string
    Optional. A free-text description of the resource. Max length 1024 characters.
    Gateways []string
    Optional. Gateways defines a list of gateways this TcpRoute is attached to, as one of the routing rules to route the requests served by the gateway. Each gateway reference should match the pattern: projects/*/locations/global/gateways/
    Labels map[string]string
    Optional. Set of label tags associated with the TcpRoute resource.
    Meshes []string
    Optional. Meshes defines a list of meshes this TcpRoute is attached to, as one of the routing rules to route the requests served by the mesh. Each mesh reference should match the pattern: projects/*/locations/global/meshes/ The attached Mesh should be of a type SIDECAR
    Name string
    Name of the TcpRoute resource. It matches pattern projects/*/locations/global/tcpRoutes/tcp_route_name>.
    Rules []TcpRouteRouteRuleResponse
    Rules that define how traffic is routed and handled. At least one RouteRule must be supplied. If there are multiple rules then the action taken will be the first rule to match.
    SelfLink string
    Server-defined URL of this resource
    UpdateTime string
    The timestamp when the resource was updated.
    createTime String
    The timestamp when the resource was created.
    description String
    Optional. A free-text description of the resource. Max length 1024 characters.
    gateways List<String>
    Optional. Gateways defines a list of gateways this TcpRoute is attached to, as one of the routing rules to route the requests served by the gateway. Each gateway reference should match the pattern: projects/*/locations/global/gateways/
    labels Map<String,String>
    Optional. Set of label tags associated with the TcpRoute resource.
    meshes List<String>
    Optional. Meshes defines a list of meshes this TcpRoute is attached to, as one of the routing rules to route the requests served by the mesh. Each mesh reference should match the pattern: projects/*/locations/global/meshes/ The attached Mesh should be of a type SIDECAR
    name String
    Name of the TcpRoute resource. It matches pattern projects/*/locations/global/tcpRoutes/tcp_route_name>.
    rules List<TcpRouteRouteRuleResponse>
    Rules that define how traffic is routed and handled. At least one RouteRule must be supplied. If there are multiple rules then the action taken will be the first rule to match.
    selfLink String
    Server-defined URL of this resource
    updateTime String
    The timestamp when the resource was updated.
    createTime string
    The timestamp when the resource was created.
    description string
    Optional. A free-text description of the resource. Max length 1024 characters.
    gateways string[]
    Optional. Gateways defines a list of gateways this TcpRoute is attached to, as one of the routing rules to route the requests served by the gateway. Each gateway reference should match the pattern: projects/*/locations/global/gateways/
    labels {[key: string]: string}
    Optional. Set of label tags associated with the TcpRoute resource.
    meshes string[]
    Optional. Meshes defines a list of meshes this TcpRoute is attached to, as one of the routing rules to route the requests served by the mesh. Each mesh reference should match the pattern: projects/*/locations/global/meshes/ The attached Mesh should be of a type SIDECAR
    name string
    Name of the TcpRoute resource. It matches pattern projects/*/locations/global/tcpRoutes/tcp_route_name>.
    rules TcpRouteRouteRuleResponse[]
    Rules that define how traffic is routed and handled. At least one RouteRule must be supplied. If there are multiple rules then the action taken will be the first rule to match.
    selfLink string
    Server-defined URL of this resource
    updateTime string
    The timestamp when the resource was updated.
    create_time str
    The timestamp when the resource was created.
    description str
    Optional. A free-text description of the resource. Max length 1024 characters.
    gateways Sequence[str]
    Optional. Gateways defines a list of gateways this TcpRoute is attached to, as one of the routing rules to route the requests served by the gateway. Each gateway reference should match the pattern: projects/*/locations/global/gateways/
    labels Mapping[str, str]
    Optional. Set of label tags associated with the TcpRoute resource.
    meshes Sequence[str]
    Optional. Meshes defines a list of meshes this TcpRoute is attached to, as one of the routing rules to route the requests served by the mesh. Each mesh reference should match the pattern: projects/*/locations/global/meshes/ The attached Mesh should be of a type SIDECAR
    name str
    Name of the TcpRoute resource. It matches pattern projects/*/locations/global/tcpRoutes/tcp_route_name>.
    rules Sequence[TcpRouteRouteRuleResponse]
    Rules that define how traffic is routed and handled. At least one RouteRule must be supplied. If there are multiple rules then the action taken will be the first rule to match.
    self_link str
    Server-defined URL of this resource
    update_time str
    The timestamp when the resource was updated.
    createTime String
    The timestamp when the resource was created.
    description String
    Optional. A free-text description of the resource. Max length 1024 characters.
    gateways List<String>
    Optional. Gateways defines a list of gateways this TcpRoute is attached to, as one of the routing rules to route the requests served by the gateway. Each gateway reference should match the pattern: projects/*/locations/global/gateways/
    labels Map<String>
    Optional. Set of label tags associated with the TcpRoute resource.
    meshes List<String>
    Optional. Meshes defines a list of meshes this TcpRoute is attached to, as one of the routing rules to route the requests served by the mesh. Each mesh reference should match the pattern: projects/*/locations/global/meshes/ The attached Mesh should be of a type SIDECAR
    name String
    Name of the TcpRoute resource. It matches pattern projects/*/locations/global/tcpRoutes/tcp_route_name>.
    rules List<Property Map>
    Rules that define how traffic is routed and handled. At least one RouteRule must be supplied. If there are multiple rules then the action taken will be the first rule to match.
    selfLink String
    Server-defined URL of this resource
    updateTime String
    The timestamp when the resource was updated.

    Supporting Types

    TcpRouteRouteActionResponse

    Destinations List<Pulumi.GoogleNative.NetworkServices.V1.Inputs.TcpRouteRouteDestinationResponse>
    Optional. The destination services to which traffic should be forwarded. At least one destination service is required. Only one of route destination or original destination can be set.
    OriginalDestination bool
    Optional. If true, Router will use the destination IP and port of the original connection as the destination of the request. Default is false. Only one of route destinations or original destination can be set.
    Destinations []TcpRouteRouteDestinationResponse
    Optional. The destination services to which traffic should be forwarded. At least one destination service is required. Only one of route destination or original destination can be set.
    OriginalDestination bool
    Optional. If true, Router will use the destination IP and port of the original connection as the destination of the request. Default is false. Only one of route destinations or original destination can be set.
    destinations List<TcpRouteRouteDestinationResponse>
    Optional. The destination services to which traffic should be forwarded. At least one destination service is required. Only one of route destination or original destination can be set.
    originalDestination Boolean
    Optional. If true, Router will use the destination IP and port of the original connection as the destination of the request. Default is false. Only one of route destinations or original destination can be set.
    destinations TcpRouteRouteDestinationResponse[]
    Optional. The destination services to which traffic should be forwarded. At least one destination service is required. Only one of route destination or original destination can be set.
    originalDestination boolean
    Optional. If true, Router will use the destination IP and port of the original connection as the destination of the request. Default is false. Only one of route destinations or original destination can be set.
    destinations Sequence[TcpRouteRouteDestinationResponse]
    Optional. The destination services to which traffic should be forwarded. At least one destination service is required. Only one of route destination or original destination can be set.
    original_destination bool
    Optional. If true, Router will use the destination IP and port of the original connection as the destination of the request. Default is false. Only one of route destinations or original destination can be set.
    destinations List<Property Map>
    Optional. The destination services to which traffic should be forwarded. At least one destination service is required. Only one of route destination or original destination can be set.
    originalDestination Boolean
    Optional. If true, Router will use the destination IP and port of the original connection as the destination of the request. Default is false. Only one of route destinations or original destination can be set.

    TcpRouteRouteDestinationResponse

    ServiceName string
    The URL of a BackendService to route traffic to.
    Weight int
    Optional. Specifies the proportion of requests forwarded to the backend referenced by the serviceName field. This is computed as: - weight/Sum(weights in this destination list). For non-zero values, there may be some epsilon from the exact proportion defined here depending on the precision an implementation supports. If only one serviceName is specified and it has a weight greater than 0, 100% of the traffic is forwarded to that backend. If weights are specified for any one service name, they need to be specified for all of them. If weights are unspecified for all services, then, traffic is distributed in equal proportions to all of them.
    ServiceName string
    The URL of a BackendService to route traffic to.
    Weight int
    Optional. Specifies the proportion of requests forwarded to the backend referenced by the serviceName field. This is computed as: - weight/Sum(weights in this destination list). For non-zero values, there may be some epsilon from the exact proportion defined here depending on the precision an implementation supports. If only one serviceName is specified and it has a weight greater than 0, 100% of the traffic is forwarded to that backend. If weights are specified for any one service name, they need to be specified for all of them. If weights are unspecified for all services, then, traffic is distributed in equal proportions to all of them.
    serviceName String
    The URL of a BackendService to route traffic to.
    weight Integer
    Optional. Specifies the proportion of requests forwarded to the backend referenced by the serviceName field. This is computed as: - weight/Sum(weights in this destination list). For non-zero values, there may be some epsilon from the exact proportion defined here depending on the precision an implementation supports. If only one serviceName is specified and it has a weight greater than 0, 100% of the traffic is forwarded to that backend. If weights are specified for any one service name, they need to be specified for all of them. If weights are unspecified for all services, then, traffic is distributed in equal proportions to all of them.
    serviceName string
    The URL of a BackendService to route traffic to.
    weight number
    Optional. Specifies the proportion of requests forwarded to the backend referenced by the serviceName field. This is computed as: - weight/Sum(weights in this destination list). For non-zero values, there may be some epsilon from the exact proportion defined here depending on the precision an implementation supports. If only one serviceName is specified and it has a weight greater than 0, 100% of the traffic is forwarded to that backend. If weights are specified for any one service name, they need to be specified for all of them. If weights are unspecified for all services, then, traffic is distributed in equal proportions to all of them.
    service_name str
    The URL of a BackendService to route traffic to.
    weight int
    Optional. Specifies the proportion of requests forwarded to the backend referenced by the serviceName field. This is computed as: - weight/Sum(weights in this destination list). For non-zero values, there may be some epsilon from the exact proportion defined here depending on the precision an implementation supports. If only one serviceName is specified and it has a weight greater than 0, 100% of the traffic is forwarded to that backend. If weights are specified for any one service name, they need to be specified for all of them. If weights are unspecified for all services, then, traffic is distributed in equal proportions to all of them.
    serviceName String
    The URL of a BackendService to route traffic to.
    weight Number
    Optional. Specifies the proportion of requests forwarded to the backend referenced by the serviceName field. This is computed as: - weight/Sum(weights in this destination list). For non-zero values, there may be some epsilon from the exact proportion defined here depending on the precision an implementation supports. If only one serviceName is specified and it has a weight greater than 0, 100% of the traffic is forwarded to that backend. If weights are specified for any one service name, they need to be specified for all of them. If weights are unspecified for all services, then, traffic is distributed in equal proportions to all of them.

    TcpRouteRouteMatchResponse

    Address string
    Must be specified in the CIDR range format. A CIDR range consists of an IP Address and a prefix length to construct the subnet mask. By default, the prefix length is 32 (i.e. matches a single IP address). Only IPV4 addresses are supported. Examples: "10.0.0.1" - matches against this exact IP address. "10.0.0.0/8" - matches against any IP address within the 10.0.0.0 subnet and 255.255.255.0 mask. "0.0.0.0/0" - matches against any IP address'.
    Port string
    Specifies the destination port to match against.
    Address string
    Must be specified in the CIDR range format. A CIDR range consists of an IP Address and a prefix length to construct the subnet mask. By default, the prefix length is 32 (i.e. matches a single IP address). Only IPV4 addresses are supported. Examples: "10.0.0.1" - matches against this exact IP address. "10.0.0.0/8" - matches against any IP address within the 10.0.0.0 subnet and 255.255.255.0 mask. "0.0.0.0/0" - matches against any IP address'.
    Port string
    Specifies the destination port to match against.
    address String
    Must be specified in the CIDR range format. A CIDR range consists of an IP Address and a prefix length to construct the subnet mask. By default, the prefix length is 32 (i.e. matches a single IP address). Only IPV4 addresses are supported. Examples: "10.0.0.1" - matches against this exact IP address. "10.0.0.0/8" - matches against any IP address within the 10.0.0.0 subnet and 255.255.255.0 mask. "0.0.0.0/0" - matches against any IP address'.
    port String
    Specifies the destination port to match against.
    address string
    Must be specified in the CIDR range format. A CIDR range consists of an IP Address and a prefix length to construct the subnet mask. By default, the prefix length is 32 (i.e. matches a single IP address). Only IPV4 addresses are supported. Examples: "10.0.0.1" - matches against this exact IP address. "10.0.0.0/8" - matches against any IP address within the 10.0.0.0 subnet and 255.255.255.0 mask. "0.0.0.0/0" - matches against any IP address'.
    port string
    Specifies the destination port to match against.
    address str
    Must be specified in the CIDR range format. A CIDR range consists of an IP Address and a prefix length to construct the subnet mask. By default, the prefix length is 32 (i.e. matches a single IP address). Only IPV4 addresses are supported. Examples: "10.0.0.1" - matches against this exact IP address. "10.0.0.0/8" - matches against any IP address within the 10.0.0.0 subnet and 255.255.255.0 mask. "0.0.0.0/0" - matches against any IP address'.
    port str
    Specifies the destination port to match against.
    address String
    Must be specified in the CIDR range format. A CIDR range consists of an IP Address and a prefix length to construct the subnet mask. By default, the prefix length is 32 (i.e. matches a single IP address). Only IPV4 addresses are supported. Examples: "10.0.0.1" - matches against this exact IP address. "10.0.0.0/8" - matches against any IP address within the 10.0.0.0 subnet and 255.255.255.0 mask. "0.0.0.0/0" - matches against any IP address'.
    port String
    Specifies the destination port to match against.

    TcpRouteRouteRuleResponse

    Action Pulumi.GoogleNative.NetworkServices.V1.Inputs.TcpRouteRouteActionResponse
    The detailed rule defining how to route matched traffic.
    Matches List<Pulumi.GoogleNative.NetworkServices.V1.Inputs.TcpRouteRouteMatchResponse>
    Optional. RouteMatch defines the predicate used to match requests to a given action. Multiple match types are "OR"ed for evaluation. If no routeMatch field is specified, this rule will unconditionally match traffic.
    Action TcpRouteRouteActionResponse
    The detailed rule defining how to route matched traffic.
    Matches []TcpRouteRouteMatchResponse
    Optional. RouteMatch defines the predicate used to match requests to a given action. Multiple match types are "OR"ed for evaluation. If no routeMatch field is specified, this rule will unconditionally match traffic.
    action TcpRouteRouteActionResponse
    The detailed rule defining how to route matched traffic.
    matches List<TcpRouteRouteMatchResponse>
    Optional. RouteMatch defines the predicate used to match requests to a given action. Multiple match types are "OR"ed for evaluation. If no routeMatch field is specified, this rule will unconditionally match traffic.
    action TcpRouteRouteActionResponse
    The detailed rule defining how to route matched traffic.
    matches TcpRouteRouteMatchResponse[]
    Optional. RouteMatch defines the predicate used to match requests to a given action. Multiple match types are "OR"ed for evaluation. If no routeMatch field is specified, this rule will unconditionally match traffic.
    action TcpRouteRouteActionResponse
    The detailed rule defining how to route matched traffic.
    matches Sequence[TcpRouteRouteMatchResponse]
    Optional. RouteMatch defines the predicate used to match requests to a given action. Multiple match types are "OR"ed for evaluation. If no routeMatch field is specified, this rule will unconditionally match traffic.
    action Property Map
    The detailed rule defining how to route matched traffic.
    matches List<Property Map>
    Optional. RouteMatch defines the predicate used to match requests to a given action. Multiple match types are "OR"ed for evaluation. If no routeMatch field is specified, this rule will unconditionally match traffic.

    Package Details

    Repository
    Google Cloud Native pulumi/pulumi-google-native
    License
    Apache-2.0
    google-native logo

    Google Cloud Native is in preview. Google Cloud Classic is fully supported.

    Google Cloud Native v0.32.0 published on Wednesday, Nov 29, 2023 by Pulumi