Skip to main content

private_connections

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

Overview

Nameprivate_connections
TypeResource
Idgoogle.datamigration.private_connections

Fields

The following fields are returned by SELECT queries:

Successful response

NameDatatypeDescription
namestringThe name of the resource.
createTimestring (google-datetime)Output only. The create time of the resource.
displayNamestringThe private connection display name.
errorobjectOutput only. The error details in case of state FAILED. (id: Status)
labelsobjectThe resource labels for private connections to use to annotate any related underlying resources such as Compute Engine VMs. An object containing a list of "key": "value" pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
pscInterfaceConfigobjectPSC Interface configuration. (id: PscInterfaceConfig)
satisfiesPzibooleanOutput only. Reserved for future use.
satisfiesPzsbooleanOutput only. Reserved for future use.
statestringOutput only. The state of the private connection.
updateTimestring (google-datetime)Output only. The last update time of the resource.
vpcPeeringConfigobjectVPC peering configuration. (id: VpcPeeringConfig)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectprojectsId, locationsId, privateConnectionsIdGets details of a single private connection.
listselectprojectsId, locationsIdpageSize, pageToken, filter, orderByRetrieves a list of private connections in a given project and location.
createinsertprojectsId, locationsIdprivateConnectionId, requestId, skipValidation, validateOnlyCreates a new private connection in a given project and location.
deletedeleteprojectsId, locationsId, privateConnectionsIdrequestIdDeletes a single Database Migration Service private connection.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
locationsIdstring
privateConnectionsIdstring
projectsIdstring
filterstring
orderBystring
pageSizeinteger (int32)
pageTokenstring
privateConnectionIdstring
requestIdstring
skipValidationboolean
validateOnlyboolean

SELECT examples

Gets details of a single private connection.

SELECT
name,
createTime,
displayName,
error,
labels,
pscInterfaceConfig,
satisfiesPzi,
satisfiesPzs,
state,
updateTime,
vpcPeeringConfig
FROM google.datamigration.private_connections
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND privateConnectionsId = '{{ privateConnectionsId }}' -- required;

INSERT examples

Creates a new private connection in a given project and location.

INSERT INTO google.datamigration.private_connections (
data__name,
data__labels,
data__displayName,
data__vpcPeeringConfig,
data__pscInterfaceConfig,
projectsId,
locationsId,
privateConnectionId,
requestId,
skipValidation,
validateOnly
)
SELECT
'{{ name }}',
'{{ labels }}',
'{{ displayName }}',
'{{ vpcPeeringConfig }}',
'{{ pscInterfaceConfig }}',
'{{ projectsId }}',
'{{ locationsId }}',
'{{ privateConnectionId }}',
'{{ requestId }}',
'{{ skipValidation }}',
'{{ validateOnly }}'
RETURNING
name,
done,
error,
metadata,
response
;

DELETE examples

Deletes a single Database Migration Service private connection.

DELETE FROM google.datamigration.private_connections
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND privateConnectionsId = '{{ privateConnectionsId }}' --required
AND requestId = '{{ requestId }}';