You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2020/08/12 12:06:16 UTC
[camel] branch master updated (9a7af71 -> ae3698b)
This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git.
from 9a7af71 CAMEL-15390: CollectionStringBuilder - Use JDK util methods instead (#4085)
new 370b020 CAMEL-15400: rest endpoint query parameters should not be marked as multivalued.
new 9aec62f CAMEL-15400: fixed camel-jpa parameters should have prefix for multivalued endpoint-dsl
new ae3698b CAMEL-15400: crypto-cms endpoint recipient should not be marked as multivalued.
The 3 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.
Summary of changes:
.../camel/component/crypto/cms/crypto-cms.json | 2 +-
.../crypt/EnvelopedDataEncryptorConfiguration.java | 2 +-
.../org/apache/camel/component/jpa/jpa.json | 2 +-
.../apache/camel/component/jpa/JpaComponent.java | 6 +++++
.../apache/camel/component/jpa/JpaEndpoint.java | 2 +-
...ithNamedQueryAndParametersMultivaluedTest.java} | 9 ++++----
.../org/apache/camel/component/rest/rest.json | 2 +-
.../camel-rest/src/main/docs/rest-component.adoc | 2 +-
.../apache/camel/component/rest/RestEndpoint.java | 6 +++--
.../dsl/CryptoCmsEndpointBuilderFactory.java | 17 ++++----------
.../endpoint/dsl/JpaEndpointBuilderFactory.java | 4 ++--
.../endpoint/dsl/RestEndpointBuilderFactory.java | 27 ++++------------------
12 files changed, 33 insertions(+), 48 deletions(-)
copy components/camel-jpa/src/test/java/org/apache/camel/component/jpa/{JpaUsingCustomPersistenceUnitTest.java => JpaWithNamedQueryAndParametersMultivaluedTest.java} (76%)
[camel] 01/03: CAMEL-15400: rest endpoint query parameters should
not be marked as multivalued.
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git
commit 370b020c1d55a238edf4d704e59f00b5c901697f
Author: Claus Ibsen <cl...@gmail.com>
AuthorDate: Wed Aug 12 13:43:08 2020 +0200
CAMEL-15400: rest endpoint query parameters should not be marked as multivalued.
---
.../org/apache/camel/component/rest/rest.json | 2 +-
.../camel-rest/src/main/docs/rest-component.adoc | 2 +-
.../apache/camel/component/rest/RestEndpoint.java | 6 +++--
.../endpoint/dsl/RestEndpointBuilderFactory.java | 27 ++++------------------
4 files changed, 11 insertions(+), 26 deletions(-)
diff --git a/components/camel-rest/src/generated/resources/org/apache/camel/component/rest/rest.json b/components/camel-rest/src/generated/resources/org/apache/camel/component/rest/rest.json
index e8e9e21..19b498d 100644
--- a/components/camel-rest/src/generated/resources/org/apache/camel/component/rest/rest.json
+++ b/components/camel-rest/src/generated/resources/org/apache/camel/component/rest/rest.json
@@ -50,7 +50,7 @@
"host": { "kind": "parameter", "displayName": "Host", "group": "producer", "label": "producer", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "Host and port of HTTP service to use (override host in openapi schema)" },
"lazyStartProducer": { "kind": "parameter", "displayName": "Lazy Start Producer", "group": "producer", "label": "producer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": 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 during starting and cause the [...]
"producerComponentName": { "kind": "parameter", "displayName": "Producer Component Name", "group": "producer", "label": "producer", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "The Camel Rest component to use for (producer) the REST transport, such as http, undertow. If no component has been explicit configured, then Camel will lookup if there is a Camel component that integrates with the Rest DSL, or if a [...]
- "queryParameters": { "kind": "parameter", "displayName": "Query Parameters", "group": "producer", "label": "producer", "required": false, "type": "string", "javaType": "java.lang.String", "multiValue": true, "deprecated": false, "secret": false, "description": "Query parameters for the HTTP service to call" },
+ "queryParameters": { "kind": "parameter", "displayName": "Query Parameters", "group": "producer", "label": "producer", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "secret": false, "description": "Query parameters for the HTTP service to call. The query parameters can contain multiple parameters separated by ampersand such such as foo=123&bar=456." },
"basicPropertyBinding": { "kind": "parameter", "displayName": "Basic Property Binding", "group": "advanced", "label": "advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "Whether the endpoint should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities" },
"synchronous": { "kind": "parameter", "displayName": "Synchronous", "group": "advanced", "label": "advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": "false", "description": "Sets whether synchronous processing should be strictly used, or Camel is allowed to use asynchronous processing (if supported)." }
}
diff --git a/components/camel-rest/src/main/docs/rest-component.adoc b/components/camel-rest/src/main/docs/rest-component.adoc
index e864303..04c06d7 100644
--- a/components/camel-rest/src/main/docs/rest-component.adoc
+++ b/components/camel-rest/src/main/docs/rest-component.adoc
@@ -88,7 +88,7 @@ with the following path and query parameters:
| *host* (producer) | Host and port of HTTP service to use (override host in openapi schema) | | String
| *lazyStartProducer* (producer) | 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 during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel's routing error handlers. Beware that when the first message is processed then creating and [...]
| *producerComponentName* (producer) | The Camel Rest component to use for (producer) the REST transport, such as http, undertow. If no component has been explicit configured, then Camel will lookup if there is a Camel component that integrates with the Rest DSL, or if a org.apache.camel.spi.RestProducerFactory is registered in the registry. If either one is found, then that is being used. | | String
-| *queryParameters* (producer) | Query parameters for the HTTP service to call | | String
+| *queryParameters* (producer) | Query parameters for the HTTP service to call. The query parameters can contain multiple parameters separated by ampersand such such as foo=123&bar=456. | | String
| *basicPropertyBinding* (advanced) | Whether the endpoint should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities | false | boolean
| *synchronous* (advanced) | Sets whether synchronous processing should be strictly used, or Camel is allowed to use asynchronous processing (if supported). | false | boolean
|===
diff --git a/components/camel-rest/src/main/java/org/apache/camel/component/rest/RestEndpoint.java b/components/camel-rest/src/main/java/org/apache/camel/component/rest/RestEndpoint.java
index daba5ec..8357274 100644
--- a/components/camel-rest/src/main/java/org/apache/camel/component/rest/RestEndpoint.java
+++ b/components/camel-rest/src/main/java/org/apache/camel/component/rest/RestEndpoint.java
@@ -81,7 +81,7 @@ public class RestEndpoint extends DefaultEndpoint {
private String apiDoc;
@UriParam(label = "producer")
private String host;
- @UriParam(label = "producer", multiValue = true)
+ @UriParam(label = "producer")
private String queryParameters;
@UriParam(label = "producer", enums = "auto,off,json,xml,json_xml")
private RestConfiguration.RestBindingMode bindingMode;
@@ -278,7 +278,9 @@ public class RestEndpoint extends DefaultEndpoint {
}
/**
- * Query parameters for the HTTP service to call
+ * Query parameters for the HTTP service to call.
+ *
+ * The query parameters can contain multiple parameters separated by ampersand such such as foo=123&bar=456.
*/
public void setQueryParameters(String queryParameters) {
this.queryParameters = queryParameters;
diff --git a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/RestEndpointBuilderFactory.java b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/RestEndpointBuilderFactory.java
index 870ae41..a4a426e 100644
--- a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/RestEndpointBuilderFactory.java
+++ b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/RestEndpointBuilderFactory.java
@@ -16,7 +16,6 @@
*/
package org.apache.camel.builder.endpoint.dsl;
-import java.util.Map;
import javax.annotation.Generated;
import org.apache.camel.ExchangePattern;
import org.apache.camel.builder.EndpointConsumerBuilder;
@@ -474,33 +473,17 @@ public interface RestEndpointBuilderFactory {
return this;
}
/**
- * Query parameters for the HTTP service to call.
+ * Query parameters for the HTTP service to call. The query parameters
+ * can contain multiple parameters separated by ampersand such such as
+ * foo=123&bar=456.
*
* The option is a: <code>java.lang.String</code> type.
- * The option is multivalued, and you can use the
- * queryParameters(String, Object) method to add a value (call the
- * method multiple times to set more values).
*
* Group: producer
*/
default RestEndpointProducerBuilder queryParameters(
- String key,
- Object value) {
- doSetMultiValueProperty("queryParameters", "null" + key, value);
- return this;
- }
- /**
- * Query parameters for the HTTP service to call.
- *
- * The option is a: <code>java.lang.String</code> type.
- * The option is multivalued, and you can use the
- * queryParameters(String, Object) method to add a value (call the
- * method multiple times to set more values).
- *
- * Group: producer
- */
- default RestEndpointProducerBuilder queryParameters(Map values) {
- doSetMultiValueProperties("queryParameters", "null", values);
+ String queryParameters) {
+ doSetProperty("queryParameters", queryParameters);
return this;
}
}
[camel] 02/03: CAMEL-15400: fixed camel-jpa parameters should have
prefix for multivalued endpoint-dsl
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git
commit 9aec62f55b2c2e62016aed40f40f13564e68b456
Author: Claus Ibsen <cl...@gmail.com>
AuthorDate: Wed Aug 12 13:57:11 2020 +0200
CAMEL-15400: fixed camel-jpa parameters should have prefix for multivalued endpoint-dsl
---
.../org/apache/camel/component/jpa/jpa.json | 2 +-
.../apache/camel/component/jpa/JpaComponent.java | 6 +++++
.../apache/camel/component/jpa/JpaEndpoint.java | 2 +-
...WithNamedQueryAndParametersMultivaluedTest.java | 27 ++++++++++++++++++++++
.../endpoint/dsl/JpaEndpointBuilderFactory.java | 4 ++--
5 files changed, 37 insertions(+), 4 deletions(-)
diff --git a/components/camel-jpa/src/generated/resources/org/apache/camel/component/jpa/jpa.json b/components/camel-jpa/src/generated/resources/org/apache/camel/component/jpa/jpa.json
index fd532ca..2a4994a 100644
--- a/components/camel-jpa/src/generated/resources/org/apache/camel/component/jpa/jpa.json
+++ b/components/camel-jpa/src/generated/resources/org/apache/camel/component/jpa/jpa.json
@@ -50,7 +50,7 @@
"transacted": { "kind": "parameter", "displayName": "Transacted", "group": "consumer", "label": "consumer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "Whether to run the consumer in transacted mode, by which all messages will either commit or rollback, when the entire batch has been processed. The default behavior (false) is to commit all the previously successfully processed messages, and [...]
"exceptionHandler": { "kind": "parameter", "displayName": "Exception Handler", "group": "consumer (advanced)", "label": "consumer,advanced", "required": false, "type": "object", "javaType": "org.apache.camel.spi.ExceptionHandler", "optionalPrefix": "consumer.", "deprecated": false, "secret": false, "description": "To let the consumer use a custom ExceptionHandler. Notice if the option bridgeErrorHandler is enabled then this option is not in use. By default the consumer will deal with [...]
"exchangePattern": { "kind": "parameter", "displayName": "Exchange Pattern", "group": "consumer (advanced)", "label": "consumer,advanced", "required": false, "type": "object", "javaType": "org.apache.camel.ExchangePattern", "enum": [ "InOnly", "InOut", "InOptionalOut" ], "deprecated": false, "secret": false, "description": "Sets the exchange pattern when the consumer creates an exchange." },
- "parameters": { "kind": "parameter", "displayName": "Parameters", "group": "consumer (advanced)", "label": "consumer,advanced", "required": false, "type": "object", "javaType": "java.util.Map<java.lang.String, java.lang.Object>", "multiValue": true, "deprecated": false, "secret": false, "description": "This key\/value mapping is used for building the query parameters. It is expected to be of the generic type java.util.Map where the keys are the named parameters of a given JPA query a [...]
+ "parameters": { "kind": "parameter", "displayName": "Parameters", "group": "consumer (advanced)", "label": "consumer,advanced", "required": false, "type": "object", "javaType": "java.util.Map<java.lang.String, java.lang.Object>", "prefix": "parameters.", "multiValue": true, "deprecated": false, "secret": false, "description": "This key\/value mapping is used for building the query parameters. It is expected to be of the generic type java.util.Map where the keys are the named paramete [...]
"pollStrategy": { "kind": "parameter", "displayName": "Poll Strategy", "group": "consumer (advanced)", "label": "consumer,advanced", "required": false, "type": "object", "javaType": "org.apache.camel.spi.PollingConsumerPollStrategy", "deprecated": false, "secret": false, "description": "A pluggable org.apache.camel.PollingConsumerPollingStrategy allowing you to provide your custom implementation to control error handling usually occurred during the poll operation before an Exchange h [...]
"findEntity": { "kind": "parameter", "displayName": "Find Entity", "group": "producer", "label": "producer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "description": "If enabled then the producer will find a single entity by using the message body as key and entityType as the class type. This can be used instead of a query to find a single entity." },
"flushOnSend": { "kind": "parameter", "displayName": "Flush On Send", "group": "producer", "label": "producer", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": "true", "description": "Flushes the EntityManager after the entity bean has been persisted." },
diff --git a/components/camel-jpa/src/main/java/org/apache/camel/component/jpa/JpaComponent.java b/components/camel-jpa/src/main/java/org/apache/camel/component/jpa/JpaComponent.java
index 9bec929..7883c72 100644
--- a/components/camel-jpa/src/main/java/org/apache/camel/component/jpa/JpaComponent.java
+++ b/components/camel-jpa/src/main/java/org/apache/camel/component/jpa/JpaComponent.java
@@ -26,6 +26,7 @@ import org.apache.camel.spi.Metadata;
import org.apache.camel.spi.annotations.Component;
import org.apache.camel.support.DefaultComponent;
import org.apache.camel.util.ObjectHelper;
+import org.apache.camel.util.PropertiesHelper;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.transaction.PlatformTransactionManager;
@@ -120,6 +121,11 @@ public class JpaComponent extends DefaultComponent {
endpoint.setJoinTransaction(isJoinTransaction());
endpoint.setSharedEntityManager(isSharedEntityManager());
+ Map<String, Object> params = PropertiesHelper.extractProperties(options, "parameters.", true);
+ if (!params.isEmpty()) {
+ endpoint.setParameters(params);
+ }
+
// lets interpret the next string as a class
if (ObjectHelper.isNotEmpty(path)) {
// provide the class loader of this component to work in OSGi environments as camel-jpa must be able
diff --git a/components/camel-jpa/src/main/java/org/apache/camel/component/jpa/JpaEndpoint.java b/components/camel-jpa/src/main/java/org/apache/camel/component/jpa/JpaEndpoint.java
index 3854411..37af064 100644
--- a/components/camel-jpa/src/main/java/org/apache/camel/component/jpa/JpaEndpoint.java
+++ b/components/camel-jpa/src/main/java/org/apache/camel/component/jpa/JpaEndpoint.java
@@ -82,7 +82,7 @@ public class JpaEndpoint extends ScheduledPollEndpoint {
private String nativeQuery;
@UriParam(label = "consumer", defaultValue = "PESSIMISTIC_WRITE")
private LockModeType lockModeType = LockModeType.PESSIMISTIC_WRITE;
- @UriParam(label = "consumer,advanced", multiValue = true)
+ @UriParam(label = "consumer,advanced", multiValue = true, prefix = "parameters.")
private Map<String, Object> parameters;
@UriParam
private Class<?> resultClass;
diff --git a/components/camel-jpa/src/test/java/org/apache/camel/component/jpa/JpaWithNamedQueryAndParametersMultivaluedTest.java b/components/camel-jpa/src/test/java/org/apache/camel/component/jpa/JpaWithNamedQueryAndParametersMultivaluedTest.java
new file mode 100644
index 0000000..c5b91be
--- /dev/null
+++ b/components/camel-jpa/src/test/java/org/apache/camel/component/jpa/JpaWithNamedQueryAndParametersMultivaluedTest.java
@@ -0,0 +1,27 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.component.jpa;
+
+import org.apache.camel.examples.Customer;
+
+public class JpaWithNamedQueryAndParametersMultivaluedTest extends JpaWithNamedQueryAndParametersTest {
+
+ protected String getEndpointUri() {
+ return "jpa://" + Customer.class.getName() + "?namedQuery=findAllCustomersWithName¶meters.custName=Willem";
+ }
+
+}
diff --git a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/JpaEndpointBuilderFactory.java b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/JpaEndpointBuilderFactory.java
index 330f45e..247e9fe 100644
--- a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/JpaEndpointBuilderFactory.java
+++ b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/JpaEndpointBuilderFactory.java
@@ -932,7 +932,7 @@ public interface JpaEndpointBuilderFactory {
default AdvancedJpaEndpointConsumerBuilder parameters(
String key,
Object value) {
- doSetMultiValueProperty("parameters", "null" + key, value);
+ doSetMultiValueProperty("parameters", "parameters." + key, value);
return this;
}
/**
@@ -953,7 +953,7 @@ public interface JpaEndpointBuilderFactory {
* Group: consumer (advanced)
*/
default AdvancedJpaEndpointConsumerBuilder parameters(Map values) {
- doSetMultiValueProperties("parameters", "null", values);
+ doSetMultiValueProperties("parameters", "parameters.", values);
return this;
}
/**
[camel] 03/03: CAMEL-15400: crypto-cms endpoint recipient should
not be marked as multivalued.
Posted by da...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git
commit ae3698bdb583669199298d689d4d05397c1c1ee1
Author: Claus Ibsen <cl...@gmail.com>
AuthorDate: Wed Aug 12 14:00:45 2020 +0200
CAMEL-15400: crypto-cms endpoint recipient should not be marked as multivalued.
---
.../apache/camel/component/crypto/cms/crypto-cms.json | 2 +-
.../cms/crypt/EnvelopedDataEncryptorConfiguration.java | 2 +-
.../endpoint/dsl/CryptoCmsEndpointBuilderFactory.java | 17 +++++------------
3 files changed, 7 insertions(+), 14 deletions(-)
diff --git a/components/camel-crypto-cms/src/generated/resources/org/apache/camel/component/crypto/cms/crypto-cms.json b/components/camel-crypto-cms/src/generated/resources/org/apache/camel/component/crypto/cms/crypto-cms.json
index f556cd8..dafcf02 100644
--- a/components/camel-crypto-cms/src/generated/resources/org/apache/camel/component/crypto/cms/crypto-cms.json
+++ b/components/camel-crypto-cms/src/generated/resources/org/apache/camel/component/crypto/cms/crypto-cms.json
@@ -39,7 +39,7 @@
"fromBase64": { "kind": "parameter", "displayName": "From Base64", "group": "decrypt_verify", "label": "decrypt_verify", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "secret": false, "defaultValue": false, "configurationClass": "org.apache.camel.component.crypto.cms.sig.DefaultSignedDataVerifierConfiguration", "configurationField": "verifyConfig", "description": "If true then the CMS message is base 64 encoded and must be decoded during the proces [...]
"contentEncryptionAlgorithm": { "kind": "parameter", "displayName": "Content Encryption Algorithm", "group": "encrypt", "label": "encrypt", "required": false, "type": "string", "javaType": "java.lang.String", "enum": [ "AES\/CBC\/PKCS5Padding", "DESede\/CBC\/PKCS5Padding", "Camellia\/CBC\/PKCS5Padding", "CAST5\/CBC\/PKCS5Padding" ], "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.crypto.cms.crypt.EnvelopedDataEncryptorConfiguration", "configura [...]
"originatorInformationProvider": { "kind": "parameter", "displayName": "Originator Information Provider", "group": "encrypt", "label": "encrypt", "required": false, "type": "object", "javaType": "org.apache.camel.component.crypto.cms.common.OriginatorInformationProvider", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.crypto.cms.crypt.EnvelopedDataEncryptorConfiguration", "configurationField": "encryptConfig", "description": "Provider for the [...]
- "recipient": { "kind": "parameter", "displayName": "Recipient", "group": "encrypt", "label": "encrypt", "required": false, "type": "array", "javaType": "java.util.List<org.apache.camel.component.crypto.cms.crypt.RecipientInfo>", "multiValue": true, "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.crypto.cms.crypt.EnvelopedDataEncryptorConfiguration", "configurationField": "encryptConfig", "description": "Recipient Info: reference to a bean which [...]
+ "recipient": { "kind": "parameter", "displayName": "Recipient", "group": "encrypt", "label": "encrypt", "required": false, "type": "array", "javaType": "java.util.List<org.apache.camel.component.crypto.cms.crypt.RecipientInfo>", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.crypto.cms.crypt.EnvelopedDataEncryptorConfiguration", "configurationField": "encryptConfig", "description": "Recipient Info: reference to a bean which implements the inte [...]
"secretKeyLength": { "kind": "parameter", "displayName": "Secret Key Length", "group": "encrypt", "label": "encrypt", "required": false, "type": "integer", "javaType": "int", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.crypto.cms.crypt.EnvelopedDataEncryptorConfiguration", "configurationField": "encryptConfig", "description": "Key length for the secret symmetric key used for the content encryption. Only used if the specified content-encrypt [...]
"unprotectedAttributesGeneratorProvider": { "kind": "parameter", "displayName": "Unprotected Attributes Generator Provider", "group": "encrypt", "label": "encrypt", "required": false, "type": "object", "javaType": "org.apache.camel.component.crypto.cms.common.AttributesGeneratorProvider", "deprecated": false, "secret": false, "configurationClass": "org.apache.camel.component.crypto.cms.crypt.EnvelopedDataEncryptorConfiguration", "configurationField": "encryptConfig", "description": " [...]
"toBase64": { "kind": "parameter", "displayName": "To Base64", "group": "encrypt_sign", "label": "encrypt_sign", "required": false, "type": "boolean", "javaType": "java.lang.Boolean", "deprecated": false, "secret": false, "defaultValue": "false", "configurationClass": "org.apache.camel.component.crypto.cms.sig.SignedDataCreatorConfiguration", "configurationField": "signConfig", "description": "Indicates whether the Signed Data or Enveloped Data instance shall be base 64 encoded. Defa [...]
diff --git a/components/camel-crypto-cms/src/main/java/org/apache/camel/component/crypto/cms/crypt/EnvelopedDataEncryptorConfiguration.java b/components/camel-crypto-cms/src/main/java/org/apache/camel/component/crypto/cms/crypt/EnvelopedDataEncryptorConfiguration.java
index d891450..e0cad4e 100644
--- a/components/camel-crypto-cms/src/main/java/org/apache/camel/component/crypto/cms/crypt/EnvelopedDataEncryptorConfiguration.java
+++ b/components/camel-crypto-cms/src/main/java/org/apache/camel/component/crypto/cms/crypt/EnvelopedDataEncryptorConfiguration.java
@@ -73,7 +73,7 @@ public class EnvelopedDataEncryptorConfiguration extends CryptoCmsMarshallerConf
SUPPORTED_ENCRYPTION_ALGORITHMS.put(CAST5_CBC_PKCS5_PADDING, Arrays.asList(new Integer[] {128, 120, 112, 104, 96, 88, 80, 72, 64, 56, 48, 40}));
}
- @UriParam(label = "encrypt", multiValue = true, description = "Recipient Info: reference to a bean which implements the interface org.apache.camel.component.crypto.cms.api.TransRecipientInfo")
+ @UriParam(label = "encrypt", description = "Recipient Info: reference to a bean which implements the interface org.apache.camel.component.crypto.cms.api.TransRecipientInfo")
private final List<RecipientInfo> recipient = new ArrayList<>(3);
@UriParam(label = "encrypt", enums = "AES/CBC/PKCS5Padding,DESede/CBC/PKCS5Padding,Camellia/CBC/PKCS5Padding,CAST5/CBC/PKCS5Padding")
diff --git a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/CryptoCmsEndpointBuilderFactory.java b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/CryptoCmsEndpointBuilderFactory.java
index e9e396b..76eb8e8 100644
--- a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/CryptoCmsEndpointBuilderFactory.java
+++ b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/CryptoCmsEndpointBuilderFactory.java
@@ -18,7 +18,6 @@ package org.apache.camel.builder.endpoint.dsl;
import java.security.KeyStore;
import java.util.List;
-import java.util.Map;
import javax.annotation.Generated;
import org.apache.camel.builder.EndpointConsumerBuilder;
import org.apache.camel.builder.EndpointProducerBuilder;
@@ -245,30 +244,24 @@ public interface CryptoCmsEndpointBuilderFactory {
*
* The option is a:
* <code>java.util.List<org.apache.camel.component.crypto.cms.crypt.RecipientInfo></code> type.
- * The option is multivalued, and you can use the recipient(String,
- * Object) method to add a value (call the method multiple times to set
- * more values).
*
* Group: encrypt
*/
- default CryptoCmsEndpointBuilder recipient(String key, Object value) {
- doSetMultiValueProperty("recipient", "null" + key, value);
+ default CryptoCmsEndpointBuilder recipient(List<Object> recipient) {
+ doSetProperty("recipient", recipient);
return this;
}
/**
* Recipient Info: reference to a bean which implements the interface
* org.apache.camel.component.crypto.cms.api.TransRecipientInfo.
*
- * The option is a:
+ * The option will be converted to a
* <code>java.util.List<org.apache.camel.component.crypto.cms.crypt.RecipientInfo></code> type.
- * The option is multivalued, and you can use the recipient(String,
- * Object) method to add a value (call the method multiple times to set
- * more values).
*
* Group: encrypt
*/
- default CryptoCmsEndpointBuilder recipient(Map values) {
- doSetMultiValueProperties("recipient", "null", values);
+ default CryptoCmsEndpointBuilder recipient(String recipient) {
+ doSetProperty("recipient", recipient);
return this;
}
/**