Skip to main content

target_pools_health_check

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

Overview

Nametarget_pools_health_check
TypeResource
Idgoogle.compute.target_pools_health_check

Fields

The following fields are returned by SELECT queries:

Successful response

NameDatatypeDescription
healthStatusarray
kindstring[Output Only] Type of resource. Always compute#targetPoolInstanceHealth when checking the health of an instance. (default: compute#targetPoolInstanceHealth)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_healthselectproject, region, targetPoolGets the most recent health check results for each IP for the instance that is referenced by the given target pool.
add_health_checkinsertproject, region, targetPoolrequestIdAdds health check URLs to a target pool.
remove_health_checkdeleteproject, region, targetPoolrequestIdRemoves health check URL from a target pool.

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
projectstring
regionstring
targetPoolstring
requestIdstring

SELECT examples

Gets the most recent health check results for each IP for the instance that is referenced by the given target pool.

SELECT
healthStatus,
kind
FROM google.compute.target_pools_health_check
WHERE project = '{{ project }}' -- required
AND region = '{{ region }}' -- required
AND targetPool = '{{ targetPool }}' -- required;

INSERT examples

Adds health check URLs to a target pool.

INSERT INTO google.compute.target_pools_health_check (
data__healthChecks,
project,
region,
targetPool,
requestId
)
SELECT
'{{ healthChecks }}',
'{{ project }}',
'{{ region }}',
'{{ targetPool }}',
'{{ requestId }}'
RETURNING
id,
name,
clientOperationId,
creationTimestamp,
description,
endTime,
error,
httpErrorMessage,
httpErrorStatusCode,
insertTime,
instancesBulkInsertOperationMetadata,
kind,
operationGroupId,
operationType,
progress,
region,
selfLink,
setCommonInstanceMetadataOperationMetadata,
startTime,
status,
statusMessage,
targetId,
targetLink,
user,
warnings,
zone
;

DELETE examples

Removes health check URL from a target pool.

DELETE FROM google.compute.target_pools_health_check
WHERE project = '{{ project }}' --required
AND region = '{{ region }}' --required
AND targetPool = '{{ targetPool }}' --required
AND requestId = '{{ requestId }}';