Skip to main content

routes

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

Overview

Nameroutes
TypeResource
Idgoogle.datastream.routes

Fields

NameDatatypeDescription
namestringOutput only. The resource's name.
createTimestringOutput only. The create time of the resource.
destinationAddressstringRequired. Destination address for connection
destinationPortintegerDestination port for connection
displayNamestringRequired. Display name.
labelsobjectLabels.
updateTimestringOutput only. The update time of the resource.

Methods

NameAccessible byRequired ParamsDescription
getSELECTlocationsId, privateConnectionsId, projectsId, routesIdUse this method to get details about a route.
listSELECTlocationsId, privateConnectionsId, projectsIdUse this method to list routes created for a private connectivity configuration in a project and location.
createINSERTlocationsId, privateConnectionsId, projectsIdUse this method to create a route for a private connectivity configuration in a project and location.
deleteDELETElocationsId, privateConnectionsId, projectsId, routesIdUse this method to delete a route.

SELECT examples

Use this method to list routes created for a private connectivity configuration in a project and location.

SELECT
name,
createTime,
destinationAddress,
destinationPort,
displayName,
labels,
updateTime
FROM google.datastream.routes
WHERE locationsId = '{{ locationsId }}'
AND privateConnectionsId = '{{ privateConnectionsId }}'
AND projectsId = '{{ projectsId }}';

INSERT example

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

/*+ create */
INSERT INTO google.datastream.routes (
locationsId,
privateConnectionsId,
projectsId,
labels,
displayName,
destinationAddress,
destinationPort
)
SELECT
'{{ locationsId }}',
'{{ privateConnectionsId }}',
'{{ projectsId }}',
'{{ labels }}',
'{{ displayName }}',
'{{ destinationAddress }}',
'{{ destinationPort }}'
;

DELETE example

Deletes the specified routes resource.

/*+ delete */
DELETE FROM google.datastream.routes
WHERE locationsId = '{{ locationsId }}'
AND privateConnectionsId = '{{ privateConnectionsId }}'
AND projectsId = '{{ projectsId }}'
AND routesId = '{{ routesId }}';