You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by ac...@apache.org on 2023/12/01 10:13:57 UTC

(camel) branch conformace-pack created (now 6d1d405a071)

This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a change to branch conformace-pack
in repository https://gitbox.apache.org/repos/asf/camel.git


      at 6d1d405a071 Camel-AWS-Config: Add a Delete Conformance Pack Operation to Producer

This branch includes the following new commits:

     new fe0018fc236 Camel-AWS-Config: Add a Put Conformance Pack operation to producer
     new 930a4a28bee Camel-AWS-Config: Add a Put Conformance Pack operation to producer
     new 208235bdd21 Camel-AWS-Config: Add a Delete Conformance Pack Operation to Producer
     new 6d1d405a071 Camel-AWS-Config: Add a Delete Conformance Pack Operation to Producer

The 4 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



(camel) 04/04: Camel-AWS-Config: Add a Delete Conformance Pack Operation to Producer

Posted by ac...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch conformace-pack
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 6d1d405a0718b886388f485864c55dc1589134f3
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Fri Dec 1 11:13:40 2023 +0100

    Camel-AWS-Config: Add a Delete Conformance Pack Operation to Producer
    
    Signed-off-by: Andrea Cosentino <an...@gmail.com>
---
 .../resources/org/apache/camel/catalog/components/aws-config.json     | 4 ++--
 .../resources/org/apache/camel/component/aws/config/aws-config.json   | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws-config.json b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws-config.json
index 6f425a2a828..3282515261a 100644
--- a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws-config.json
+++ b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws-config.json
@@ -24,7 +24,7 @@
   "componentProperties": {
     "configuration": { "index": 0, "kind": "property", "displayName": "Configuration", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "deprecated": false, "autowired": false, "secret": false, "description": "Component configuration" },
     "lazyStartProducer": { "index": 1, "kind": "property", "displayName": "Lazy Start Producer", "group": "producer", "label": "producer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "description": "Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail [...]
-    "operation": { "index": 2, "kind": "property", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance", "putConformancePack" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "confi [...]
+    "operation": { "index": 2, "kind": "property", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance", "putConformancePack", "removeConformancePack" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSCon [...]
     "overrideEndpoint": { "index": 3, "kind": "property", "displayName": "Override Endpoint", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "Set the need for overidding the endpoint. This option needs to be used in combina [...]
     "pojoRequest": { "index": 4, "kind": "property", "displayName": "Pojo Request", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "If we want to use a POJO request as body or not" },
     "region": { "index": 5, "kind": "property", "displayName": "Region", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "enum": [ "ap-south-2", "ap-south-1", "eu-south-1", "eu-south-2", "us-gov-east-1", "me-central-1", "il-central-1", "ca-central-1", "eu-central-1", "us-iso-west-1", "eu-central-2", "us-west-1", "us-west-2", "af-south-1", "eu-north-1", "eu-west-3", "eu-west-2", "eu-west-1", "ap-northeast-3", "ap-northeast-2", "ap-nor [...]
@@ -54,7 +54,7 @@
   },
   "properties": {
     "label": { "index": 0, "kind": "path", "displayName": "Label", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "Logical name" },
-    "operation": { "index": 1, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance", "putConformancePack" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "conf [...]
+    "operation": { "index": 1, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance", "putConformancePack", "removeConformancePack" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSCo [...]
     "overrideEndpoint": { "index": 2, "kind": "parameter", "displayName": "Override Endpoint", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "Set the need for overidding the endpoint. This option needs to be used in combin [...]
     "pojoRequest": { "index": 3, "kind": "parameter", "displayName": "Pojo Request", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "If we want to use a POJO request as body or not" },
     "region": { "index": 4, "kind": "parameter", "displayName": "Region", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "enum": [ "ap-south-2", "ap-south-1", "eu-south-1", "eu-south-2", "us-gov-east-1", "me-central-1", "il-central-1", "ca-central-1", "eu-central-1", "us-iso-west-1", "eu-central-2", "us-west-1", "us-west-2", "af-south-1", "eu-north-1", "eu-west-3", "eu-west-2", "eu-west-1", "ap-northeast-3", "ap-northeast-2", "ap-no [...]
diff --git a/components/camel-aws/camel-aws-config/src/generated/resources/org/apache/camel/component/aws/config/aws-config.json b/components/camel-aws/camel-aws-config/src/generated/resources/org/apache/camel/component/aws/config/aws-config.json
index 6f425a2a828..3282515261a 100644
--- a/components/camel-aws/camel-aws-config/src/generated/resources/org/apache/camel/component/aws/config/aws-config.json
+++ b/components/camel-aws/camel-aws-config/src/generated/resources/org/apache/camel/component/aws/config/aws-config.json
@@ -24,7 +24,7 @@
   "componentProperties": {
     "configuration": { "index": 0, "kind": "property", "displayName": "Configuration", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "deprecated": false, "autowired": false, "secret": false, "description": "Component configuration" },
     "lazyStartProducer": { "index": 1, "kind": "property", "displayName": "Lazy Start Producer", "group": "producer", "label": "producer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "description": "Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail [...]
-    "operation": { "index": 2, "kind": "property", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance", "putConformancePack" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "confi [...]
+    "operation": { "index": 2, "kind": "property", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance", "putConformancePack", "removeConformancePack" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSCon [...]
     "overrideEndpoint": { "index": 3, "kind": "property", "displayName": "Override Endpoint", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "Set the need for overidding the endpoint. This option needs to be used in combina [...]
     "pojoRequest": { "index": 4, "kind": "property", "displayName": "Pojo Request", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "If we want to use a POJO request as body or not" },
     "region": { "index": 5, "kind": "property", "displayName": "Region", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "enum": [ "ap-south-2", "ap-south-1", "eu-south-1", "eu-south-2", "us-gov-east-1", "me-central-1", "il-central-1", "ca-central-1", "eu-central-1", "us-iso-west-1", "eu-central-2", "us-west-1", "us-west-2", "af-south-1", "eu-north-1", "eu-west-3", "eu-west-2", "eu-west-1", "ap-northeast-3", "ap-northeast-2", "ap-nor [...]
@@ -54,7 +54,7 @@
   },
   "properties": {
     "label": { "index": 0, "kind": "path", "displayName": "Label", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "Logical name" },
-    "operation": { "index": 1, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance", "putConformancePack" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "conf [...]
+    "operation": { "index": 1, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance", "putConformancePack", "removeConformancePack" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSCo [...]
     "overrideEndpoint": { "index": 2, "kind": "parameter", "displayName": "Override Endpoint", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "Set the need for overidding the endpoint. This option needs to be used in combin [...]
     "pojoRequest": { "index": 3, "kind": "parameter", "displayName": "Pojo Request", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "If we want to use a POJO request as body or not" },
     "region": { "index": 4, "kind": "parameter", "displayName": "Region", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "enum": [ "ap-south-2", "ap-south-1", "eu-south-1", "eu-south-2", "us-gov-east-1", "me-central-1", "il-central-1", "ca-central-1", "eu-central-1", "us-iso-west-1", "eu-central-2", "us-west-1", "us-west-2", "af-south-1", "eu-north-1", "eu-west-3", "eu-west-2", "eu-west-1", "ap-northeast-3", "ap-northeast-2", "ap-no [...]


(camel) 02/04: Camel-AWS-Config: Add a Put Conformance Pack operation to producer

Posted by ac...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch conformace-pack
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 930a4a28bee060da23750f2a13433861c681f932
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Fri Dec 1 11:03:57 2023 +0100

    Camel-AWS-Config: Add a Put Conformance Pack operation to producer
    
    Signed-off-by: Andrea Cosentino <an...@gmail.com>
---
 .../org/apache/camel/catalog/components/aws-config.json          | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws-config.json b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws-config.json
index f71b893bb71..6f425a2a828 100644
--- a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws-config.json
+++ b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/aws-config.json
@@ -24,7 +24,7 @@
   "componentProperties": {
     "configuration": { "index": 0, "kind": "property", "displayName": "Configuration", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "deprecated": false, "autowired": false, "secret": false, "description": "Component configuration" },
     "lazyStartProducer": { "index": 1, "kind": "property", "displayName": "Lazy Start Producer", "group": "producer", "label": "producer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "description": "Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail [...]
-    "operation": { "index": 2, "kind": "property", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "confi [...]
+    "operation": { "index": 2, "kind": "property", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance", "putConformancePack" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "confi [...]
     "overrideEndpoint": { "index": 3, "kind": "property", "displayName": "Override Endpoint", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "Set the need for overidding the endpoint. This option needs to be used in combina [...]
     "pojoRequest": { "index": 4, "kind": "property", "displayName": "Pojo Request", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "If we want to use a POJO request as body or not" },
     "region": { "index": 5, "kind": "property", "displayName": "Region", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "enum": [ "ap-south-2", "ap-south-1", "eu-south-1", "eu-south-2", "us-gov-east-1", "me-central-1", "il-central-1", "ca-central-1", "eu-central-1", "us-iso-west-1", "eu-central-2", "us-west-1", "us-west-2", "af-south-1", "eu-north-1", "eu-west-3", "eu-west-2", "eu-west-1", "ap-northeast-3", "ap-northeast-2", "ap-nor [...]
@@ -47,11 +47,14 @@
     "CamelAwsConfigOperation": { "index": 0, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "The operation we want to perform", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#OPERATION" },
     "CamelAwsConfigRuleSourceIdentifier": { "index": 1, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "The Managed rule source identifier", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#RULE_SOURCE_IDENTIFIER" },
     "CamelAwsConfigRuleSource": { "index": 2, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "The source object for the rule. The owner of the rule could be AWS, CUSTOM_LAMBDA or CUSTOM_POLICY", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#SOURCE" },
-    "CamelAwsConfigRuleName": { "index": 3, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "The Managed rule name", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#RULE_NAME" }
+    "CamelAwsConfigRuleName": { "index": 3, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "The Managed rule name", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#RULE_NAME" },
+    "CamelAwsConformancePackName": { "index": 4, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "The Conformance pack name", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#CONFORMACE_PACK_NAME" },
+    "CamelAwsConfigConformacePackS3TemplateURI": { "index": 5, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "The location of the file containing the template body in S3", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#CONFORMACE_PACK_S3_TEMPLATE_URI" },
+    "CamelAwsConfigConformacePackTemplateBody": { "index": 6, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "A string containing the full conformance pack template body", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#CONFORMACE_PACK_TEMPLATE_BODY" }
   },
   "properties": {
     "label": { "index": 0, "kind": "path", "displayName": "Label", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "Logical name" },
-    "operation": { "index": 1, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "conf [...]
+    "operation": { "index": 1, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance", "putConformancePack" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "conf [...]
     "overrideEndpoint": { "index": 2, "kind": "parameter", "displayName": "Override Endpoint", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "Set the need for overidding the endpoint. This option needs to be used in combin [...]
     "pojoRequest": { "index": 3, "kind": "parameter", "displayName": "Pojo Request", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "If we want to use a POJO request as body or not" },
     "region": { "index": 4, "kind": "parameter", "displayName": "Region", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "enum": [ "ap-south-2", "ap-south-1", "eu-south-1", "eu-south-2", "us-gov-east-1", "me-central-1", "il-central-1", "ca-central-1", "eu-central-1", "us-iso-west-1", "eu-central-2", "us-west-1", "us-west-2", "af-south-1", "eu-north-1", "eu-west-3", "eu-west-2", "eu-west-1", "ap-northeast-3", "ap-northeast-2", "ap-no [...]


(camel) 01/04: Camel-AWS-Config: Add a Put Conformance Pack operation to producer

Posted by ac...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch conformace-pack
in repository https://gitbox.apache.org/repos/asf/camel.git

commit fe0018fc2365e93ac7180b5201d767e02559ca8a
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Fri Dec 1 10:58:38 2023 +0100

    Camel-AWS-Config: Add a Put Conformance Pack operation to producer
    
    Signed-off-by: Andrea Cosentino <an...@gmail.com>
---
 .../camel/component/aws/config/aws-config.json     |  9 ++--
 .../component/aws/config/AWSConfigConstants.java   |  9 ++++
 .../component/aws/config/AWSConfigOperations.java  |  3 +-
 .../component/aws/config/AWSConfigProducer.java    | 54 ++++++++++++++++++++++
 4 files changed, 71 insertions(+), 4 deletions(-)

diff --git a/components/camel-aws/camel-aws-config/src/generated/resources/org/apache/camel/component/aws/config/aws-config.json b/components/camel-aws/camel-aws-config/src/generated/resources/org/apache/camel/component/aws/config/aws-config.json
index f71b893bb71..6f425a2a828 100644
--- a/components/camel-aws/camel-aws-config/src/generated/resources/org/apache/camel/component/aws/config/aws-config.json
+++ b/components/camel-aws/camel-aws-config/src/generated/resources/org/apache/camel/component/aws/config/aws-config.json
@@ -24,7 +24,7 @@
   "componentProperties": {
     "configuration": { "index": 0, "kind": "property", "displayName": "Configuration", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "deprecated": false, "autowired": false, "secret": false, "description": "Component configuration" },
     "lazyStartProducer": { "index": 1, "kind": "property", "displayName": "Lazy Start Producer", "group": "producer", "label": "producer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "description": "Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail [...]
-    "operation": { "index": 2, "kind": "property", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "confi [...]
+    "operation": { "index": 2, "kind": "property", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance", "putConformancePack" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "confi [...]
     "overrideEndpoint": { "index": 3, "kind": "property", "displayName": "Override Endpoint", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "Set the need for overidding the endpoint. This option needs to be used in combina [...]
     "pojoRequest": { "index": 4, "kind": "property", "displayName": "Pojo Request", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "If we want to use a POJO request as body or not" },
     "region": { "index": 5, "kind": "property", "displayName": "Region", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "enum": [ "ap-south-2", "ap-south-1", "eu-south-1", "eu-south-2", "us-gov-east-1", "me-central-1", "il-central-1", "ca-central-1", "eu-central-1", "us-iso-west-1", "eu-central-2", "us-west-1", "us-west-2", "af-south-1", "eu-north-1", "eu-west-3", "eu-west-2", "eu-west-1", "ap-northeast-3", "ap-northeast-2", "ap-nor [...]
@@ -47,11 +47,14 @@
     "CamelAwsConfigOperation": { "index": 0, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "The operation we want to perform", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#OPERATION" },
     "CamelAwsConfigRuleSourceIdentifier": { "index": 1, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "The Managed rule source identifier", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#RULE_SOURCE_IDENTIFIER" },
     "CamelAwsConfigRuleSource": { "index": 2, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "The source object for the rule. The owner of the rule could be AWS, CUSTOM_LAMBDA or CUSTOM_POLICY", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#SOURCE" },
-    "CamelAwsConfigRuleName": { "index": 3, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "The Managed rule name", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#RULE_NAME" }
+    "CamelAwsConfigRuleName": { "index": 3, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "The Managed rule name", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#RULE_NAME" },
+    "CamelAwsConformancePackName": { "index": 4, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "The Conformance pack name", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#CONFORMACE_PACK_NAME" },
+    "CamelAwsConfigConformacePackS3TemplateURI": { "index": 5, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "The location of the file containing the template body in S3", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#CONFORMACE_PACK_S3_TEMPLATE_URI" },
+    "CamelAwsConfigConformacePackTemplateBody": { "index": 6, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "A string containing the full conformance pack template body", "constantName": "org.apache.camel.component.aws.config.AWSConfigConstants#CONFORMACE_PACK_TEMPLATE_BODY" }
   },
   "properties": {
     "label": { "index": 0, "kind": "path", "displayName": "Label", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "Logical name" },
-    "operation": { "index": 1, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "conf [...]
+    "operation": { "index": 1, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": true, "type": "object", "javaType": "org.apache.camel.component.aws.config.AWSConfigOperations", "enum": [ "putConfigRule", "removeConfigRule", "describeRuleCompliance", "putConformancePack" ], "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "conf [...]
     "overrideEndpoint": { "index": 2, "kind": "parameter", "displayName": "Override Endpoint", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "Set the need for overidding the endpoint. This option needs to be used in combin [...]
     "pojoRequest": { "index": 3, "kind": "parameter", "displayName": "Pojo Request", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.aws.config.AWSConfigConfiguration", "configurationField": "configuration", "description": "If we want to use a POJO request as body or not" },
     "region": { "index": 4, "kind": "parameter", "displayName": "Region", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "enum": [ "ap-south-2", "ap-south-1", "eu-south-1", "eu-south-2", "us-gov-east-1", "me-central-1", "il-central-1", "ca-central-1", "eu-central-1", "us-iso-west-1", "eu-central-2", "us-west-1", "us-west-2", "af-south-1", "eu-north-1", "eu-west-3", "eu-west-2", "eu-west-1", "ap-northeast-3", "ap-northeast-2", "ap-no [...]
diff --git a/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigConstants.java b/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigConstants.java
index 0a5a902dfb2..f9973b0d5fa 100644
--- a/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigConstants.java
+++ b/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigConstants.java
@@ -31,4 +31,13 @@ public interface AWSConfigConstants {
     String SOURCE = "CamelAwsConfigRuleSource";
     @Metadata(description = "The Managed rule name", javaType = "String")
     String RULE_NAME = "CamelAwsConfigRuleName";
+
+    @Metadata(description = "The Conformance pack name", javaType = "String")
+    String CONFORMACE_PACK_NAME = "CamelAwsConformancePackName";
+
+    @Metadata(description = "The location of the file containing the template body in S3", javaType = "String")
+    String CONFORMACE_PACK_S3_TEMPLATE_URI = "CamelAwsConfigConformacePackS3TemplateURI";
+
+    @Metadata(description = "A string containing the full conformance pack template body", javaType = "String")
+    String CONFORMACE_PACK_TEMPLATE_BODY = "CamelAwsConfigConformacePackTemplateBody";
 }
diff --git a/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigOperations.java b/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigOperations.java
index 6c002bc7e71..7c215d10b4e 100644
--- a/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigOperations.java
+++ b/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigOperations.java
@@ -20,6 +20,7 @@ public enum AWSConfigOperations {
 
     putConfigRule,
     removeConfigRule,
+    describeRuleCompliance,
+    putConformancePack
 
-    describeRuleCompliance
 }
diff --git a/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigProducer.java b/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigProducer.java
index cc63c42e314..f59031c940f 100644
--- a/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigProducer.java
+++ b/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigProducer.java
@@ -60,6 +60,9 @@ public class AWSConfigProducer extends DefaultProducer {
             case describeRuleCompliance:
                 describeRuleCompliance(getEndpoint().getConfigClient(), exchange);
                 break;
+            case putConformancePack:
+                putConformancePack(getEndpoint().getConfigClient(), exchange);
+                break;
             default:
                 throw new IllegalArgumentException("Unsupported operation");
         }
@@ -209,6 +212,57 @@ public class AWSConfigProducer extends DefaultProducer {
         }
     }
 
+    private void putConformancePack(ConfigClient configClient, Exchange exchange) throws InvalidPayloadException {
+        if (getConfiguration().isPojoRequest()) {
+            Object payload = exchange.getIn().getMandatoryBody();
+            if (payload instanceof PutConformancePackRequest) {
+                PutConformancePackResponse result;
+                try {
+                    PutConformancePackRequest request = (PutConformancePackRequest) payload;
+                    result = configClient.putConformancePack(request);
+                } catch (AwsServiceException ase) {
+                    LOG.trace("Put Conformance Pack command returned the error code {}", ase.awsErrorDetails().errorCode());
+                    throw ase;
+                }
+                Message message = getMessageForResponse(exchange);
+                message.setBody(result);
+            }
+        } else {
+            PutConformancePackRequest.Builder builder = PutConformancePackRequest.builder();
+            if (ObjectHelper.isNotEmpty(exchange.getIn().getHeader(AWSConfigConstants.CONFORMACE_PACK_NAME))) {
+                String conformancePackName = exchange.getIn().getHeader(AWSConfigConstants.CONFORMACE_PACK_NAME, String.class);
+                builder.conformancePackName(conformancePackName);
+            } else {
+                throw new IllegalArgumentException("Rule Name must be specified");
+            }
+            String conformancePackS3TemplateUri = null;
+            String conformancePackTemplateBody = null;
+            if (ObjectHelper.isNotEmpty(exchange.getIn().getHeader(AWSConfigConstants.CONFORMACE_PACK_S3_TEMPLATE_URI))) {
+                conformancePackS3TemplateUri
+                        = exchange.getIn().getHeader(AWSConfigConstants.CONFORMACE_PACK_S3_TEMPLATE_URI, String.class);
+                builder.templateS3Uri(conformancePackS3TemplateUri);
+            }
+            if (ObjectHelper.isNotEmpty(exchange.getIn().getHeader(AWSConfigConstants.CONFORMACE_PACK_TEMPLATE_BODY))) {
+                conformancePackTemplateBody
+                        = exchange.getIn().getHeader(AWSConfigConstants.CONFORMACE_PACK_TEMPLATE_BODY, String.class);
+                builder.templateBody(conformancePackTemplateBody);
+            }
+            if (ObjectHelper.isEmpty(conformancePackS3TemplateUri) && ObjectHelper.isEmpty(conformancePackTemplateBody)) {
+                throw new IllegalArgumentException("One of Conformace Pack S3 Template URI or Template Body must be specified");
+            }
+            PutConformancePackResponse result;
+            try {
+                PutConformancePackRequest request = builder.build();
+                result = configClient.putConformancePack(request);
+            } catch (AwsServiceException ase) {
+                LOG.trace("Put Conformance Pack command returned the error code {}", ase.awsErrorDetails().errorCode());
+                throw ase;
+            }
+            Message message = getMessageForResponse(exchange);
+            message.setBody(result);
+        }
+    }
+
     public static Message getMessageForResponse(final Exchange exchange) {
         return exchange.getMessage();
     }


(camel) 03/04: Camel-AWS-Config: Add a Delete Conformance Pack Operation to Producer

Posted by ac...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

acosentino pushed a commit to branch conformace-pack
in repository https://gitbox.apache.org/repos/asf/camel.git

commit 208235bdd21d72e263628e934172c87aef72fb65
Author: Andrea Cosentino <an...@gmail.com>
AuthorDate: Fri Dec 1 11:08:01 2023 +0100

    Camel-AWS-Config: Add a Delete Conformance Pack Operation to Producer
    
    Signed-off-by: Andrea Cosentino <an...@gmail.com>
---
 .../component/aws/config/AWSConfigOperations.java  |  3 +-
 .../component/aws/config/AWSConfigProducer.java    | 39 ++++++++++++++++++++++
 2 files changed, 41 insertions(+), 1 deletion(-)

diff --git a/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigOperations.java b/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigOperations.java
index 7c215d10b4e..3abe50adffe 100644
--- a/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigOperations.java
+++ b/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigOperations.java
@@ -21,6 +21,7 @@ public enum AWSConfigOperations {
     putConfigRule,
     removeConfigRule,
     describeRuleCompliance,
-    putConformancePack
+    putConformancePack,
+    removeConformancePack
 
 }
diff --git a/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigProducer.java b/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigProducer.java
index f59031c940f..317be5b3bf6 100644
--- a/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigProducer.java
+++ b/components/camel-aws/camel-aws-config/src/main/java/org/apache/camel/component/aws/config/AWSConfigProducer.java
@@ -63,6 +63,9 @@ public class AWSConfigProducer extends DefaultProducer {
             case putConformancePack:
                 putConformancePack(getEndpoint().getConfigClient(), exchange);
                 break;
+            case removeConformancePack:
+                removeConformancePack(getEndpoint().getConfigClient(), exchange);
+                break;
             default:
                 throw new IllegalArgumentException("Unsupported operation");
         }
@@ -263,6 +266,42 @@ public class AWSConfigProducer extends DefaultProducer {
         }
     }
 
+    private void removeConformancePack(ConfigClient configClient, Exchange exchange) throws InvalidPayloadException {
+        if (getConfiguration().isPojoRequest()) {
+            Object payload = exchange.getIn().getMandatoryBody();
+            if (payload instanceof DeleteConformancePackRequest) {
+                DeleteConformancePackResponse result;
+                try {
+                    DeleteConformancePackRequest request = (DeleteConformancePackRequest) payload;
+                    result = configClient.deleteConformancePack(request);
+                } catch (AwsServiceException ase) {
+                    LOG.trace("Remove Conformance Pack rule command returned the error code {}", ase.awsErrorDetails().errorCode());
+                    throw ase;
+                }
+                Message message = getMessageForResponse(exchange);
+                message.setBody(result);
+            }
+        } else {
+            DeleteConformancePackRequest.Builder builder = DeleteConformancePackRequest.builder();
+            if (ObjectHelper.isNotEmpty(exchange.getIn().getHeader(AWSConfigConstants.CONFORMACE_PACK_NAME))) {
+                String conformancePackName = exchange.getIn().getHeader(AWSConfigConstants.RULE_NAME, String.class);
+                builder.conformancePackName(conformancePackName);
+            } else {
+                throw new IllegalArgumentException("Conformance Pack Name must be specified");
+            }
+            DeleteConformancePackResponse result;
+            try {
+                DeleteConformancePackRequest request = builder.build();
+                result = configClient.deleteConformancePack(request);
+            } catch (AwsServiceException ase) {
+                LOG.trace("Remove Conformance Pack command returned the error code {}", ase.awsErrorDetails().errorCode());
+                throw ase;
+            }
+            Message message = getMessageForResponse(exchange);
+            message.setBody(result);
+        }
+    }
+
     public static Message getMessageForResponse(final Exchange exchange) {
         return exchange.getMessage();
     }