Skip to main content

tls_routes

Creates, updates, deletes, gets or lists a tls_routes resource.

Overview

Nametls_routes
TypeResource
Idgoogle.networkservices.tls_routes

Fields

NameDatatypeDescription
namestringIdentifier. Name of the TlsRoute resource. It matches pattern projects/*/locations/global/tlsRoutes/tls_route_name>.
descriptionstringOptional. A free-text description of the resource. Max length 1024 characters.
createTimestringOutput only. The timestamp when the resource was created.
gatewaysarrayOptional. Gateways defines a list of gateways this TlsRoute 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/
labelsobjectOptional. Set of label tags associated with the TlsRoute resource.
meshesarrayOptional. Meshes defines a list of meshes this TlsRoute 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
rulesarrayRequired. 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.
selfLinkstringOutput only. Server-defined URL of this resource
updateTimestringOutput only. The timestamp when the resource was updated.

Methods

NameAccessible byRequired ParamsDescription
getSELECTlocationsId, projectsId, tlsRoutesIdGets details of a single TlsRoute.
listSELECTlocationsId, projectsIdLists TlsRoute in a given project and location.
createINSERTlocationsId, projectsIdCreates a new TlsRoute in a given project and location.
deleteDELETElocationsId, projectsId, tlsRoutesIdDeletes a single TlsRoute.
patchUPDATElocationsId, projectsId, tlsRoutesIdUpdates the parameters of a single TlsRoute.

SELECT examples

Lists TlsRoute in a given project and location.

SELECT
name,
description,
createTime,
gateways,
labels,
meshes,
rules,
selfLink,
updateTime
FROM google.networkservices.tls_routes
WHERE locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';

INSERT example

Use the following StackQL query and manifest file to create a new tls_routes resource.

/*+ create */
INSERT INTO google.networkservices.tls_routes (
locationsId,
projectsId,
name,
description,
rules,
meshes,
gateways,
labels
)
SELECT
'{{ locationsId }}',
'{{ projectsId }}',
'{{ name }}',
'{{ description }}',
'{{ rules }}',
'{{ meshes }}',
'{{ gateways }}',
'{{ labels }}'
;

UPDATE example

Updates a tls_routes resource.

/*+ update */
UPDATE google.networkservices.tls_routes
SET
name = '{{ name }}',
description = '{{ description }}',
rules = '{{ rules }}',
meshes = '{{ meshes }}',
gateways = '{{ gateways }}',
labels = '{{ labels }}'
WHERE
locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}'
AND tlsRoutesId = '{{ tlsRoutesId }}';

DELETE example

Deletes the specified tls_routes resource.

/*+ delete */
DELETE FROM google.networkservices.tls_routes
WHERE locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}'
AND tlsRoutesId = '{{ tlsRoutesId }}';