From 1c0bae3f3b4554abf5b9f9306785cd004ab98995 Mon Sep 17 00:00:00 2001 From: Mathias Vandaele Date: Fri, 27 Sep 2024 12:43:39 +0200 Subject: [PATCH] fix(sqs): remove pattern validation in runtime, add override description to template (#3366) * fix(sqs): add last minute fix (discussed with the team) * docs(readme): fix Spotless formatting issues --------- Co-authored-by: Ev Bilske (cherry picked from commit 02fe7cb2708a1c14b7cd0f65b14167dcdd68621c) --- .../aws-sqs/element-templates/aws-sqs-boundary-connector.json | 4 ++-- .../aws-sqs-inbound-intermediate-connector.json | 4 ++-- .../aws/aws-sqs/element-templates/aws-sqs-start-message.json | 4 ++-- .../connector/inbound/model/SqsInboundQueueProperties.java | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/connectors/aws/aws-sqs/element-templates/aws-sqs-boundary-connector.json b/connectors/aws/aws-sqs/element-templates/aws-sqs-boundary-connector.json index 6fc28993ae..e0d3f96fbf 100644 --- a/connectors/aws/aws-sqs/element-templates/aws-sqs-boundary-connector.json +++ b/connectors/aws/aws-sqs/element-templates/aws-sqs-boundary-connector.json @@ -149,13 +149,13 @@ }, { "id" : "queue.queue.pollingWaitTime", "label" : "Polling wait time", - "description" : "The duration (in seconds) for which the call waits for a message to arrive in the queue before returning. See documentation for details", + "description" : "The duration (in seconds) for which the call waits for a message to arrive in the queue before returning. See documentation for details. A value of 0 will automatically be overridden to 1", "optional" : false, "value" : "20", "constraints" : { "notEmpty" : true, "pattern" : { - "value" : "^([1-9]?|1[0-9]|20|secrets\\..+)$" + "value" : "^([0-9]?|1[0-9]|20|secrets\\..+)$" } }, "group" : "messagePollingProperties", diff --git a/connectors/aws/aws-sqs/element-templates/aws-sqs-inbound-intermediate-connector.json b/connectors/aws/aws-sqs/element-templates/aws-sqs-inbound-intermediate-connector.json index 8288f16c97..455817c69a 100644 --- a/connectors/aws/aws-sqs/element-templates/aws-sqs-inbound-intermediate-connector.json +++ b/connectors/aws/aws-sqs/element-templates/aws-sqs-inbound-intermediate-connector.json @@ -149,13 +149,13 @@ }, { "id" : "queue.queue.pollingWaitTime", "label" : "Polling wait time", - "description" : "The duration (in seconds) for which the call waits for a message to arrive in the queue before returning. See documentation for details", + "description" : "The duration (in seconds) for which the call waits for a message to arrive in the queue before returning. See documentation for details. A value of 0 will automatically be overridden to 1", "optional" : false, "value" : "20", "constraints" : { "notEmpty" : true, "pattern" : { - "value" : "^([1-9]?|1[0-9]|20|secrets\\..+)$" + "value" : "^([0-9]?|1[0-9]|20|secrets\\..+)$" } }, "group" : "messagePollingProperties", diff --git a/connectors/aws/aws-sqs/element-templates/aws-sqs-start-message.json b/connectors/aws/aws-sqs/element-templates/aws-sqs-start-message.json index f15ec4412a..358f0d118d 100644 --- a/connectors/aws/aws-sqs/element-templates/aws-sqs-start-message.json +++ b/connectors/aws/aws-sqs/element-templates/aws-sqs-start-message.json @@ -149,13 +149,13 @@ }, { "id" : "queue.queue.pollingWaitTime", "label" : "Polling wait time", - "description" : "The duration (in seconds) for which the call waits for a message to arrive in the queue before returning. See documentation for details", + "description" : "The duration (in seconds) for which the call waits for a message to arrive in the queue before returning. See documentation for details. A value of 0 will automatically be overridden to 1", "optional" : false, "value" : "20", "constraints" : { "notEmpty" : true, "pattern" : { - "value" : "^([1-9]?|1[0-9]|20|secrets\\..+)$" + "value" : "^([0-9]?|1[0-9]|20|secrets\\..+)$" } }, "group" : "messagePollingProperties", diff --git a/connectors/aws/aws-sqs/src/main/java/io/camunda/connector/inbound/model/SqsInboundQueueProperties.java b/connectors/aws/aws-sqs/src/main/java/io/camunda/connector/inbound/model/SqsInboundQueueProperties.java index ae9e40d4c4..ad0f7fda95 100644 --- a/connectors/aws/aws-sqs/src/main/java/io/camunda/connector/inbound/model/SqsInboundQueueProperties.java +++ b/connectors/aws/aws-sqs/src/main/java/io/camunda/connector/inbound/model/SqsInboundQueueProperties.java @@ -44,8 +44,8 @@ public record SqsInboundQueueProperties( group = "messagePollingProperties", defaultValue = "20", description = - "The duration (in seconds) for which the call waits for a message to arrive in the queue before returning. See documentation for details", + "The duration (in seconds) for which the call waits for a message to arrive in the queue before returning. See documentation for details. A value of 0 will automatically be overridden to 1", feel = FeelMode.disabled) - @Pattern(regexp = "^([1-9]?|1[0-9]|20|secrets\\..+)$") + @Pattern(regexp = "^([0-9]?|1[0-9]|20|secrets\\..+)$") @NotBlank String pollingWaitTime) {}