Create component metadata for state.postgresql (#2695)

Signed-off-by: MregXN <46479059+MregXN@users.noreply.github.com>
This commit is contained in:
MregXN 2023-03-24 00:24:16 +08:00 committed by GitHub
parent b1558f8c0d
commit def1dca6c2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 55 additions and 0 deletions

View File

@ -0,0 +1,55 @@
# yaml-language-server: $schema=../../component-metadata-schema.json
schemaVersion: v1
type: state
name: postgresql
version: v1
status: stable
title: "PostgreSQL"
urls:
- title: Reference
url: https://docs.dapr.io/reference/components-reference/supported-state-stores/setup-postgresql/
capabilities:
# If actorStateStore is present, the metadata key actorStateStore can be used
- actorStateStore
- crud
- transactional
- etag
- query
- ttl
metadata:
- name: connectionString
required: true
description: The connection string for the PostgreSQL database
example: "host=localhost user=postgres password=example port=5432 connect_timeout=10 database=dapr_test"
type: string
- name: timeoutInSeconds
required: false
description: Timeout, in seconds, for all database operations.
example: "30"
default: "20"
type: number
- name: tableName
required: false
description: Name of the table where the data is stored. Defaults to `state`. Can optionally have the schema name as prefix, such as `public.state`
example: "public.state"
type: string
- name: metadataTableName
required: false
description: Name of the table Dapr uses to store a few metadata properties. Defaults to `dapr_metadata`. Can optionally have the schema name as prefix, such as `public.dapr_metadata`
example: "public.dapr_metadata"
type: string
- name: cleanupIntervalInSeconds
required: false
description: Interval, in seconds, to clean up rows with an expired TTL. Default to 3600 (i.e. 1 hour). Setting this to values <=0 disables the periodic cleanup.
example: "1800"
type: number
- name: connectionMaxIdleTime
required: false
description: Max idle time before unused connections are automatically closed in the connection pool. By default, there's no value and this is left to the database driver to choose.
example: "5m"
type: duration
- name: actorStateStore
required: false
description: Consider this state store for actors. Defaults to `false`
example: "false"
type: bool