diff --git a/.build-tools/pkg/metadataschema/validators.go b/.build-tools/pkg/metadataschema/validators.go index 77fd894875..685e2134f7 100644 --- a/.build-tools/pkg/metadataschema/validators.go +++ b/.build-tools/pkg/metadataschema/validators.go @@ -111,6 +111,32 @@ func (c *ComponentMetadata) AppendBuiltin() error { }, ) } + if slices.Contains(c.Capabilities, "transactional") { + c.Metadata = append(c.Metadata, + Metadata{ + Name: "outboxPublishPubsub", + Type: "string", + Description: "For outbox. Sets the name of the pub/sub component to deliver the notifications when publishing state changes", + }, + Metadata{ + Name: "outboxPublishTopic", + Type: "string", + Description: `For outbox. Sets the topic that receives the state changes on the pub/sub configured with "outboxPublishPubsub". The message body will be a state transaction item for an insert or update operation`, + }, + Metadata{ + Name: "outboxPubsub", + Type: "string", + Description: `For outbox. Sets the pub/sub component used by Dapr to coordinate the state and pub/sub transactions. If not set, the pub/sub component configured with "outboxPublishPubsub" is used. This is useful if you want to separate the pub/sub component used to send the notification state changes from the one used to coordinate the transaction`, + Default: "outboxPublishPubsub", + }, + Metadata{ + Name: "outboxDiscardWhenMissingState", + Description: "By setting outboxDiscardWhenMissingState to true, Dapr discards the transaction if it cannot find the state in the database and does not retry. This setting can be useful if the state store data has been deleted for any reason before Dapr was able to deliver the message and you would like Dapr to drop the items from the pub/sub and stop retrying to fetch the state", + Type: "bool", + Default: "false", + }, + ) + } c.Metadata = append(c.Metadata, Metadata{ diff --git a/state/mysql/metadata.yaml b/state/mysql/metadata.yaml index 904e5f0c74..564430a5b5 100644 --- a/state/mysql/metadata.yaml +++ b/state/mysql/metadata.yaml @@ -18,7 +18,7 @@ capabilities: authenticationProfiles: - title: "Connection string" description: | - Authenticate using a connetion string. + Authenticate using a connection string. metadata: - name: connectionString required: true