connectivity_tests
Creates, updates, deletes, gets or lists a connectivity_tests
resource.
Overview
Name | connectivity_tests |
Type | Resource |
Id | google.networkmanagement.connectivity_tests |
Fields
The following fields are returned by SELECT
queries:
- get
- list
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Identifier. Unique name of the resource using the form: projects/{project_id}/locations/global/connectivityTests/{test_id} |
bypassFirewallChecks | boolean | Whether the analysis should skip firewall checking. Default value is false. |
createTime | string (google-datetime) | Output only. The time the test was created. |
description | string | The user-supplied description of the Connectivity Test. Maximum of 512 characters. |
destination | object | Required. Destination specification of the Connectivity Test. You can use a combination of destination IP address, URI of a supported endpoint, project ID, or VPC network to identify the destination location. Reachability analysis proceeds even if the destination location is ambiguous. However, the test result might include endpoints or use a destination that you don't intend to test. (id: Endpoint) |
displayName | string | Output only. The display name of a Connectivity Test. |
labels | object | Resource labels to represent user-provided metadata. |
probingDetails | object | Output only. The probing details of this test from the latest run, present for applicable tests only. The details are updated when creating a new test, updating an existing test, or triggering a one-time rerun of an existing test. (id: ProbingDetails) |
protocol | string | IP Protocol of the test. When not provided, "TCP" is assumed. |
reachabilityDetails | object | Output only. The reachability details of this test from the latest run. The details are updated when creating a new test, updating an existing test, or triggering a one-time rerun of an existing test. (id: ReachabilityDetails) |
relatedProjects | array | Other projects that may be relevant for reachability analysis. This is applicable to scenarios where a test can cross project boundaries. |
returnReachabilityDetails | object | Output only. The reachability details of this test from the latest run for the return path. The details are updated when creating a new test, updating an existing test, or triggering a one-time rerun of an existing test. (id: ReachabilityDetails) |
roundTrip | boolean | Whether run analysis for the return path from destination to source. Default value is false. |
source | object | Required. Source specification of the Connectivity Test. You can use a combination of source IP address, URI of a supported endpoint, project ID, or VPC network to identify the source location. Reachability analysis might proceed even if the source location is ambiguous. However, the test result might include endpoints or use a source that you don't intend to test. (id: Endpoint) |
updateTime | string (google-datetime) | Output only. The time the test's configuration was updated. |
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Identifier. Unique name of the resource using the form: projects/{project_id}/locations/global/connectivityTests/{test_id} |
bypassFirewallChecks | boolean | Whether the analysis should skip firewall checking. Default value is false. |
createTime | string (google-datetime) | Output only. The time the test was created. |
description | string | The user-supplied description of the Connectivity Test. Maximum of 512 characters. |
destination | object | Required. Destination specification of the Connectivity Test. You can use a combination of destination IP address, URI of a supported endpoint, project ID, or VPC network to identify the destination location. Reachability analysis proceeds even if the destination location is ambiguous. However, the test result might include endpoints or use a destination that you don't intend to test. (id: Endpoint) |
displayName | string | Output only. The display name of a Connectivity Test. |
labels | object | Resource labels to represent user-provided metadata. |
probingDetails | object | Output only. The probing details of this test from the latest run, present for applicable tests only. The details are updated when creating a new test, updating an existing test, or triggering a one-time rerun of an existing test. (id: ProbingDetails) |
protocol | string | IP Protocol of the test. When not provided, "TCP" is assumed. |
reachabilityDetails | object | Output only. The reachability details of this test from the latest run. The details are updated when creating a new test, updating an existing test, or triggering a one-time rerun of an existing test. (id: ReachabilityDetails) |
relatedProjects | array | Other projects that may be relevant for reachability analysis. This is applicable to scenarios where a test can cross project boundaries. |
returnReachabilityDetails | object | Output only. The reachability details of this test from the latest run for the return path. The details are updated when creating a new test, updating an existing test, or triggering a one-time rerun of an existing test. (id: ReachabilityDetails) |
roundTrip | boolean | Whether run analysis for the return path from destination to source. Default value is false. |
source | object | Required. Source specification of the Connectivity Test. You can use a combination of source IP address, URI of a supported endpoint, project ID, or VPC network to identify the source location. Reachability analysis might proceed even if the source location is ambiguous. However, the test result might include endpoints or use a source that you don't intend to test. (id: Endpoint) |
updateTime | string (google-datetime) | Output only. The time the test's configuration was updated. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | projectsId , connectivityTestsId | Gets the details of a specific Connectivity Test. | |
list | select | projectsId | pageSize , pageToken , filter , orderBy | Lists all Connectivity Tests owned by a project. |
create | insert | projectsId | testId | Creates a new Connectivity Test. After you create a test, the reachability analysis is performed as part of the long running operation, which completes when the analysis completes. If the endpoint specifications in ConnectivityTest are invalid (for example, containing non-existent resources in the network, or you don't have read permissions to the network configurations of listed projects), then the reachability result returns a value of UNKNOWN . If the endpoint specifications in ConnectivityTest are incomplete, the reachability result returns a value of AMBIGUOUS. For more information, see the Connectivity Test documentation. |
patch | update | projectsId , connectivityTestsId | updateMask | Updates the configuration of an existing ConnectivityTest . After you update a test, the reachability analysis is performed as part of the long running operation, which completes when the analysis completes. The Reachability state in the test resource is updated with the new result. If the endpoint specifications in ConnectivityTest are invalid (for example, they contain non-existent resources in the network, or the user does not have read permissions to the network configurations of listed projects), then the reachability result returns a value of UNKNOWN. If the endpoint specifications in ConnectivityTest are incomplete, the reachability result returns a value of AMBIGUOUS . See the documentation in ConnectivityTest for more details. |
delete | delete | projectsId , connectivityTestsId | Deletes a specific ConnectivityTest . | |
rerun | exec | projectsId , connectivityTestsId | Rerun an existing ConnectivityTest . After the user triggers the rerun, the reachability analysis is performed as part of the long running operation, which completes when the analysis completes. Even though the test configuration remains the same, the reachability result may change due to underlying network configuration changes. If the endpoint specifications in ConnectivityTest become invalid (for example, specified resources are deleted in the network, or you lost read permissions to the network configurations of listed projects), then the reachability result returns a value of UNKNOWN . |
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.
Name | Datatype | Description |
---|---|---|
connectivityTestsId | string | |
projectsId | string | |
filter | string | |
orderBy | string | |
pageSize | integer (int32) | |
pageToken | string | |
testId | string | |
updateMask | string (google-fieldmask) |
SELECT
examples
- get
- list
Gets the details of a specific Connectivity Test.
SELECT
name,
bypassFirewallChecks,
createTime,
description,
destination,
displayName,
labels,
probingDetails,
protocol,
reachabilityDetails,
relatedProjects,
returnReachabilityDetails,
roundTrip,
source,
updateTime
FROM google.networkmanagement.connectivity_tests
WHERE projectsId = '{{ projectsId }}' -- required
AND connectivityTestsId = '{{ connectivityTestsId }}' -- required;
Lists all Connectivity Tests owned by a project.
SELECT
name,
bypassFirewallChecks,
createTime,
description,
destination,
displayName,
labels,
probingDetails,
protocol,
reachabilityDetails,
relatedProjects,
returnReachabilityDetails,
roundTrip,
source,
updateTime
FROM google.networkmanagement.connectivity_tests
WHERE projectsId = '{{ projectsId }}' -- required
AND pageSize = '{{ pageSize }}'
AND pageToken = '{{ pageToken }}'
AND filter = '{{ filter }}'
AND orderBy = '{{ orderBy }}';
INSERT
examples
- create
- Manifest
Creates a new Connectivity Test. After you create a test, the reachability analysis is performed as part of the long running operation, which completes when the analysis completes. If the endpoint specifications in ConnectivityTest
are invalid (for example, containing non-existent resources in the network, or you don't have read permissions to the network configurations of listed projects), then the reachability result returns a value of UNKNOWN
. If the endpoint specifications in ConnectivityTest
are incomplete, the reachability result returns a value of AMBIGUOUS. For more information, see the Connectivity Test documentation.
INSERT INTO google.networkmanagement.connectivity_tests (
data__name,
data__description,
data__source,
data__destination,
data__protocol,
data__relatedProjects,
data__labels,
data__roundTrip,
data__bypassFirewallChecks,
projectsId,
testId
)
SELECT
'{{ name }}',
'{{ description }}',
'{{ source }}',
'{{ destination }}',
'{{ protocol }}',
'{{ relatedProjects }}',
'{{ labels }}',
{{ roundTrip }},
{{ bypassFirewallChecks }},
'{{ projectsId }}',
'{{ testId }}'
RETURNING
name,
done,
error,
metadata,
response
;
# Description fields are for documentation purposes
- name: connectivity_tests
props:
- name: projectsId
value: string
description: Required parameter for the connectivity_tests resource.
- name: name
value: string
description: >
Identifier. Unique name of the resource using the form: `projects/{project_id}/locations/global/connectivityTests/{test_id}`
- name: description
value: string
description: >
The user-supplied description of the Connectivity Test. Maximum of 512 characters.
- name: source
value: object
description: >
Required. Source specification of the Connectivity Test. You can use a combination of source IP address, URI of a supported endpoint, project ID, or VPC network to identify the source location. Reachability analysis might proceed even if the source location is ambiguous. However, the test result might include endpoints or use a source that you don't intend to test.
- name: destination
value: object
description: >
Required. Destination specification of the Connectivity Test. You can use a combination of destination IP address, URI of a supported endpoint, project ID, or VPC network to identify the destination location. Reachability analysis proceeds even if the destination location is ambiguous. However, the test result might include endpoints or use a destination that you don't intend to test.
- name: protocol
value: string
description: >
IP Protocol of the test. When not provided, "TCP" is assumed.
- name: relatedProjects
value: array
description: >
Other projects that may be relevant for reachability analysis. This is applicable to scenarios where a test can cross project boundaries.
- name: labels
value: object
description: >
Resource labels to represent user-provided metadata.
- name: roundTrip
value: boolean
description: >
Whether run analysis for the return path from destination to source. Default value is false.
- name: bypassFirewallChecks
value: boolean
description: >
Whether the analysis should skip firewall checking. Default value is false.
- name: testId
value: string
UPDATE
examples
- patch
Updates the configuration of an existing ConnectivityTest
. After you update a test, the reachability analysis is performed as part of the long running operation, which completes when the analysis completes. The Reachability state in the test resource is updated with the new result. If the endpoint specifications in ConnectivityTest
are invalid (for example, they contain non-existent resources in the network, or the user does not have read permissions to the network configurations of listed projects), then the reachability result returns a value of UNKNOWN. If the endpoint specifications in ConnectivityTest
are incomplete, the reachability result returns a value of AMBIGUOUS
. See the documentation in ConnectivityTest
for more details.
UPDATE google.networkmanagement.connectivity_tests
SET
data__name = '{{ name }}',
data__description = '{{ description }}',
data__source = '{{ source }}',
data__destination = '{{ destination }}',
data__protocol = '{{ protocol }}',
data__relatedProjects = '{{ relatedProjects }}',
data__labels = '{{ labels }}',
data__roundTrip = {{ roundTrip }},
data__bypassFirewallChecks = {{ bypassFirewallChecks }}
WHERE
projectsId = '{{ projectsId }}' --required
AND connectivityTestsId = '{{ connectivityTestsId }}' --required
AND updateMask = '{{ updateMask}}'
RETURNING
name,
done,
error,
metadata,
response;
DELETE
examples
- delete
Deletes a specific ConnectivityTest
.
DELETE FROM google.networkmanagement.connectivity_tests
WHERE projectsId = '{{ projectsId }}' --required
AND connectivityTestsId = '{{ connectivityTestsId }}' --required;
Lifecycle Methods
- rerun
Rerun an existing ConnectivityTest
. After the user triggers the rerun, the reachability analysis is performed as part of the long running operation, which completes when the analysis completes. Even though the test configuration remains the same, the reachability result may change due to underlying network configuration changes. If the endpoint specifications in ConnectivityTest
become invalid (for example, specified resources are deleted in the network, or you lost read permissions to the network configurations of listed projects), then the reachability result returns a value of UNKNOWN
.
EXEC google.networkmanagement.connectivity_tests.rerun
@projectsId='{{ projectsId }}' --required,
@connectivityTestsId='{{ connectivityTestsId }}' --required;