postgresql_integrations
Creates, updates, deletes, gets or lists a postgresql_integrations resource.
Overview​
| Name | postgresql_integrations |
| Type | Resource |
| Id | ovh.cloud_database.postgresql_integrations |
Fields​
The following fields are returned by SELECT queries:
- get
- list
successful operation
| Name | Datatype | Description |
|---|---|---|
id | string (uuid) | Service ID |
destination_service_id | string (uuid) | ID of the destination service (wire: destinationServiceId) |
source_service_id | string (uuid) | ID of the source service (wire: sourceServiceId) |
parameters | object | Parameters for the integration |
status | string | Current status of the integration (READY) |
type | string | Type of the integration (grafanaDashboard, grafanaDatasource, kafkaConnect, kafkaLogs, kafkaMirrorMaker, opensearchLogs, postgresqlMetrics) |
Cloud database service integration definition
| Name | Datatype | Description |
|---|---|---|
id | string (uuid) | Service ID |
destination_service_id | string (uuid) | ID of the destination service (wire: destinationServiceId) |
source_service_id | string (uuid) | ID of the source service (wire: sourceServiceId) |
parameters | object | Parameters for the integration |
status | string | Current status of the integration (READY) |
type | string | Type of the integration (grafanaDashboard, grafanaDatasource, kafkaConnect, kafkaLogs, kafkaMirrorMaker, opensearchLogs, postgresqlMetrics) |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | cluster_id, integration_id, service_name | Get an integration | |
list | select | cluster_id, service_name | x_pagination_mode | List integrations |
create | insert | cluster_id, service_name, destination_service_id, source_service_id | Create a new integration | |
delete | delete | cluster_id, integration_id, service_name | Delete an integration |
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 |
|---|---|---|
api_host | string | The OVHcloud API host. Selected by OVH_ENDPOINT (ovh-eu, ovh-ca or ovh-us; default ovh-eu). (default: api.eu.ovhcloud.com, x-stackQL-envVarSelector: {"envVar":"OVH_ENDPOINT","default":"ovh-eu","values":{"ovh-eu":"api.eu.ovhcloud.com","ovh-ca":"api.ca.ovhcloud.com","ovh-us":"api.us.ovhcloud.com"}}) |
cluster_id | string (uuid) | Cluster ID (wire: clusterId) |
integration_id | string (uuid) | Integration ID (wire: integrationId) |
service_name | string | The Public Cloud project ID. Resolved from OVH_CLOUD_PROJECT_SERVICE when set. |
x_pagination_mode | string | Sent as CachedObjectList-Pages by default so the list returns the full objects rather than their identifiers. (wire: X-Pagination-Mode) |
SELECT examples​
- get
- list
Get an integration
SELECT
id,
destination_service_id,
source_service_id,
parameters,
status,
type
FROM ovh.cloud_database.postgresql_integrations
WHERE cluster_id = '{{ cluster_id }}' -- required
AND integration_id = '{{ integration_id }}' -- required
AND service_name = '{{ service_name }}' -- required unless OVH_CLOUD_PROJECT_SERVICE is set
;
List integrations
SELECT
id,
destination_service_id,
source_service_id,
parameters,
status,
type
FROM ovh.cloud_database.postgresql_integrations
WHERE cluster_id = '{{ cluster_id }}' -- required
AND service_name = '{{ service_name }}' -- required unless OVH_CLOUD_PROJECT_SERVICE is set
AND x_pagination_mode = '{{ x_pagination_mode }}'
;
INSERT examples​
- create
- Manifest
Create a new integration
INSERT INTO ovh.cloud_database.postgresql_integrations (
destination_service_id,
parameters,
source_service_id,
type,
cluster_id,
service_name
)
SELECT
'{{ destination_service_id }}' /* required */,
'{{ parameters }}',
'{{ source_service_id }}' /* required */,
'{{ type }}',
'{{ cluster_id }}',
'{{ service_name }}'
RETURNING
id,
destination_service_id,
source_service_id,
parameters,
status,
type
;
# Description fields are for documentation purposes
- name: postgresql_integrations
props:
- name: cluster_id
value: "{{ cluster_id }}"
description: Required parameter for the postgresql_integrations resource.
- name: service_name
value: "{{ service_name }}"
description: Required parameter for the postgresql_integrations resource.
- name: destination_service_id
value: "{{ destination_service_id }}"
description: |
ID of the destination service
- name: parameters
value: "{{ parameters }}"
description: |
Parameters for the integration
- name: source_service_id
value: "{{ source_service_id }}"
description: |
ID of the source service
- name: type
value: "{{ type }}"
description: |
Type of the integration
valid_values: ['grafanaDashboard', 'grafanaDatasource', 'kafkaConnect', 'kafkaLogs', 'kafkaMirrorMaker', 'opensearchLogs', 'postgresqlMetrics']
DELETE examples​
- delete
Delete an integration
DELETE FROM ovh.cloud_database.postgresql_integrations
WHERE cluster_id = '{{ cluster_id }}' --required
AND integration_id = '{{ integration_id }}' --required
AND service_name = '{{ service_name }}' --required unless OVH_CLOUD_PROJECT_SERVICE is set
;