This is an automated email from the ASF dual-hosted git repository. acosentino pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/camel.git
commit 9a19ea4e9fb89734e00ff50304dbdead637e31c8 Author: Andrea Cosentino <anco...@gmail.com> AuthorDate: Thu Jan 28 07:19:29 2021 +0100 CAMEL-16001 - Regen --- .../smn/SimpleNotificationComponentConfigurer.java | 55 +++ .../smn/SimpleNotificationEndpointConfigurer.java | 115 +++++++ .../smn/SimpleNotificationEndpointUriFactory.java | 80 +++++ .../services/org/apache/camel/component.properties | 7 + .../org/apache/camel/component/hwcloud-smn | 2 + .../apache/camel/configurer/hwcloud-smn-component | 2 + .../apache/camel/configurer/hwcloud-smn-endpoint | 2 + .../apache/camel/urifactory/hwcloud-smn-endpoint | 2 + .../component/huaweicloud/smn/hwcloud-smn.json | 44 +++ .../dsl/HwcloudSmnComponentBuilderFactory.java | 121 +++++++ .../SimpleNotificationEndpointBuilderFactory.java | 383 +++++++++++++++++++++ 11 files changed, 813 insertions(+) diff --git a/components/camel-huaweicloud-smn/src/generated/java/org/apache/camel/component/huaweicloud/smn/SimpleNotificationComponentConfigurer.java b/components/camel-huaweicloud-smn/src/generated/java/org/apache/camel/component/huaweicloud/smn/SimpleNotificationComponentConfigurer.java new file mode 100644 index 0000000..c7a0037 --- /dev/null +++ b/components/camel-huaweicloud-smn/src/generated/java/org/apache/camel/component/huaweicloud/smn/SimpleNotificationComponentConfigurer.java @@ -0,0 +1,55 @@ +/* Generated by camel build tools - do NOT edit this file! */ +package org.apache.camel.component.huaweicloud.smn; + +import java.util.Map; + +import org.apache.camel.CamelContext; +import org.apache.camel.spi.ExtendedPropertyConfigurerGetter; +import org.apache.camel.spi.PropertyConfigurerGetter; +import org.apache.camel.spi.ConfigurerStrategy; +import org.apache.camel.spi.GeneratedPropertyConfigurer; +import org.apache.camel.util.CaseInsensitiveMap; +import org.apache.camel.support.component.PropertyConfigurerSupport; + +/** + * Generated by camel build tools - do NOT edit this file! + */ +@SuppressWarnings("unchecked") +public class SimpleNotificationComponentConfigurer extends PropertyConfigurerSupport implements GeneratedPropertyConfigurer, PropertyConfigurerGetter { + + @Override + public boolean configure(CamelContext camelContext, Object obj, String name, Object value, boolean ignoreCase) { + SimpleNotificationComponent target = (SimpleNotificationComponent) obj; + switch (ignoreCase ? name.toLowerCase() : name) { + case "autowiredenabled": + case "autowiredEnabled": target.setAutowiredEnabled(property(camelContext, boolean.class, value)); return true; + case "lazystartproducer": + case "lazyStartProducer": target.setLazyStartProducer(property(camelContext, boolean.class, value)); return true; + default: return false; + } + } + + @Override + public Class<?> getOptionType(String name, boolean ignoreCase) { + switch (ignoreCase ? name.toLowerCase() : name) { + case "autowiredenabled": + case "autowiredEnabled": return boolean.class; + case "lazystartproducer": + case "lazyStartProducer": return boolean.class; + default: return null; + } + } + + @Override + public Object getOptionValue(Object obj, String name, boolean ignoreCase) { + SimpleNotificationComponent target = (SimpleNotificationComponent) obj; + switch (ignoreCase ? name.toLowerCase() : name) { + case "autowiredenabled": + case "autowiredEnabled": return target.isAutowiredEnabled(); + case "lazystartproducer": + case "lazyStartProducer": return target.isLazyStartProducer(); + default: return null; + } + } +} + diff --git a/components/camel-huaweicloud-smn/src/generated/java/org/apache/camel/component/huaweicloud/smn/SimpleNotificationEndpointConfigurer.java b/components/camel-huaweicloud-smn/src/generated/java/org/apache/camel/component/huaweicloud/smn/SimpleNotificationEndpointConfigurer.java new file mode 100644 index 0000000..82c8a7f --- /dev/null +++ b/components/camel-huaweicloud-smn/src/generated/java/org/apache/camel/component/huaweicloud/smn/SimpleNotificationEndpointConfigurer.java @@ -0,0 +1,115 @@ +/* Generated by camel build tools - do NOT edit this file! */ +package org.apache.camel.component.huaweicloud.smn; + +import java.util.Map; + +import org.apache.camel.CamelContext; +import org.apache.camel.spi.ExtendedPropertyConfigurerGetter; +import org.apache.camel.spi.PropertyConfigurerGetter; +import org.apache.camel.spi.ConfigurerStrategy; +import org.apache.camel.spi.GeneratedPropertyConfigurer; +import org.apache.camel.util.CaseInsensitiveMap; +import org.apache.camel.support.component.PropertyConfigurerSupport; + +/** + * Generated by camel build tools - do NOT edit this file! + */ +@SuppressWarnings("unchecked") +public class SimpleNotificationEndpointConfigurer extends PropertyConfigurerSupport implements GeneratedPropertyConfigurer, PropertyConfigurerGetter { + + @Override + public boolean configure(CamelContext camelContext, Object obj, String name, Object value, boolean ignoreCase) { + SimpleNotificationEndpoint target = (SimpleNotificationEndpoint) obj; + switch (ignoreCase ? name.toLowerCase() : name) { + case "authkey": + case "authKey": target.setAuthKey(property(camelContext, java.lang.String.class, value)); return true; + case "ignoresslverification": + case "ignoreSslVerification": target.setIgnoreSslVerification(property(camelContext, boolean.class, value)); return true; + case "lazystartproducer": + case "lazyStartProducer": target.setLazyStartProducer(property(camelContext, boolean.class, value)); return true; + case "messagettl": + case "messageTtl": target.setMessageTtl(property(camelContext, int.class, value)); return true; + case "operation": target.setOperation(property(camelContext, java.lang.String.class, value)); return true; + case "projectid": + case "projectId": target.setProjectId(property(camelContext, java.lang.String.class, value)); return true; + case "proxyhost": + case "proxyHost": target.setProxyHost(property(camelContext, java.lang.String.class, value)); return true; + case "proxypassword": + case "proxyPassword": target.setProxyPassword(property(camelContext, java.lang.String.class, value)); return true; + case "proxyport": + case "proxyPort": target.setProxyPort(property(camelContext, int.class, value)); return true; + case "proxyuser": + case "proxyUser": target.setProxyUser(property(camelContext, java.lang.String.class, value)); return true; + case "region": target.setRegion(property(camelContext, java.lang.String.class, value)); return true; + case "secretkey": + case "secretKey": target.setSecretKey(property(camelContext, java.lang.String.class, value)); return true; + case "servicekeys": + case "serviceKeys": target.setServiceKeys(property(camelContext, org.apache.camel.component.huaweicloud.smn.models.ServiceKeys.class, value)); return true; + default: return false; + } + } + + @Override + public Class<?> getOptionType(String name, boolean ignoreCase) { + switch (ignoreCase ? name.toLowerCase() : name) { + case "authkey": + case "authKey": return java.lang.String.class; + case "ignoresslverification": + case "ignoreSslVerification": return boolean.class; + case "lazystartproducer": + case "lazyStartProducer": return boolean.class; + case "messagettl": + case "messageTtl": return int.class; + case "operation": return java.lang.String.class; + case "projectid": + case "projectId": return java.lang.String.class; + case "proxyhost": + case "proxyHost": return java.lang.String.class; + case "proxypassword": + case "proxyPassword": return java.lang.String.class; + case "proxyport": + case "proxyPort": return int.class; + case "proxyuser": + case "proxyUser": return java.lang.String.class; + case "region": return java.lang.String.class; + case "secretkey": + case "secretKey": return java.lang.String.class; + case "servicekeys": + case "serviceKeys": return org.apache.camel.component.huaweicloud.smn.models.ServiceKeys.class; + default: return null; + } + } + + @Override + public Object getOptionValue(Object obj, String name, boolean ignoreCase) { + SimpleNotificationEndpoint target = (SimpleNotificationEndpoint) obj; + switch (ignoreCase ? name.toLowerCase() : name) { + case "authkey": + case "authKey": return target.getAuthKey(); + case "ignoresslverification": + case "ignoreSslVerification": return target.isIgnoreSslVerification(); + case "lazystartproducer": + case "lazyStartProducer": return target.isLazyStartProducer(); + case "messagettl": + case "messageTtl": return target.getMessageTtl(); + case "operation": return target.getOperation(); + case "projectid": + case "projectId": return target.getProjectId(); + case "proxyhost": + case "proxyHost": return target.getProxyHost(); + case "proxypassword": + case "proxyPassword": return target.getProxyPassword(); + case "proxyport": + case "proxyPort": return target.getProxyPort(); + case "proxyuser": + case "proxyUser": return target.getProxyUser(); + case "region": return target.getRegion(); + case "secretkey": + case "secretKey": return target.getSecretKey(); + case "servicekeys": + case "serviceKeys": return target.getServiceKeys(); + default: return null; + } + } +} + diff --git a/components/camel-huaweicloud-smn/src/generated/java/org/apache/camel/component/huaweicloud/smn/SimpleNotificationEndpointUriFactory.java b/components/camel-huaweicloud-smn/src/generated/java/org/apache/camel/component/huaweicloud/smn/SimpleNotificationEndpointUriFactory.java new file mode 100644 index 0000000..3e6ed20 --- /dev/null +++ b/components/camel-huaweicloud-smn/src/generated/java/org/apache/camel/component/huaweicloud/smn/SimpleNotificationEndpointUriFactory.java @@ -0,0 +1,80 @@ +/* Generated by camel build tools - do NOT edit this file! */ +package org.apache.camel.component.huaweicloud.smn; + +import java.net.URISyntaxException; +import java.util.Collections; +import java.util.HashMap; +import java.util.HashSet; +import java.util.Map; +import java.util.Set; + +import org.apache.camel.spi.EndpointUriFactory; + +/** + * Generated by camel build tools - do NOT edit this file! + */ +public class SimpleNotificationEndpointUriFactory extends org.apache.camel.support.component.EndpointUriFactorySupport implements EndpointUriFactory { + + private static final String BASE = ":smnService"; + + private static final Set<String> PROPERTY_NAMES; + private static final Set<String> SECRET_PROPERTY_NAMES; + static { + Set<String> props = new HashSet<>(14); + props.add("authKey"); + props.add("serviceKeys"); + props.add("secretKey"); + props.add("proxyPassword"); + props.add("ignoreSslVerification"); + props.add("proxyHost"); + props.add("proxyPort"); + props.add("lazyStartProducer"); + props.add("proxyUser"); + props.add("messageTtl"); + props.add("region"); + props.add("operation"); + props.add("projectId"); + props.add("smnService"); + PROPERTY_NAMES = Collections.unmodifiableSet(props); + Set<String> secretProps = new HashSet<>(5); + secretProps.add("authKey"); + secretProps.add("serviceKeys"); + secretProps.add("secretKey"); + secretProps.add("proxyPassword"); + secretProps.add("proxyUser"); + SECRET_PROPERTY_NAMES = Collections.unmodifiableSet(secretProps); + } + + @Override + public boolean isEnabled(String scheme) { + return "hwcloud-smn".equals(scheme); + } + + @Override + public String buildUri(String scheme, Map<String, Object> properties, boolean encode) throws URISyntaxException { + String syntax = scheme + BASE; + String uri = syntax; + + Map<String, Object> copy = new HashMap<>(properties); + + uri = buildPathParameter(syntax, uri, "smnService", null, true, copy); + uri = buildQueryParameters(uri, copy, encode); + return uri; + } + + @Override + public Set<String> propertyNames() { + return PROPERTY_NAMES; + } + + @Override + public Set<String> secretPropertyNames() { + return SECRET_PROPERTY_NAMES; + } + + @Override + public boolean isLenientProperties() { + return false; + } +} + diff --git a/components/camel-huaweicloud-smn/src/generated/resources/META-INF/services/org/apache/camel/component.properties b/components/camel-huaweicloud-smn/src/generated/resources/META-INF/services/org/apache/camel/component.properties new file mode 100644 index 0000000..841a036 --- /dev/null +++ b/components/camel-huaweicloud-smn/src/generated/resources/META-INF/services/org/apache/camel/component.properties @@ -0,0 +1,7 @@ +# Generated by camel build tools - do NOT edit this file! +components=hwcloud-smn +groupId=org.apache.camel +artifactId=camel-huaweicloud-smn +version=3.8.0-SNAPSHOT +projectName=Camel :: Huawei Cloud SimpleNotification Component +projectDescription=A Camel Huawei Simple Notification Component diff --git a/components/camel-huaweicloud-smn/src/generated/resources/META-INF/services/org/apache/camel/component/hwcloud-smn b/components/camel-huaweicloud-smn/src/generated/resources/META-INF/services/org/apache/camel/component/hwcloud-smn new file mode 100644 index 0000000..f56a34e --- /dev/null +++ b/components/camel-huaweicloud-smn/src/generated/resources/META-INF/services/org/apache/camel/component/hwcloud-smn @@ -0,0 +1,2 @@ +# Generated by camel build tools - do NOT edit this file! +class=org.apache.camel.component.huaweicloud.smn.SimpleNotificationComponent diff --git a/components/camel-huaweicloud-smn/src/generated/resources/META-INF/services/org/apache/camel/configurer/hwcloud-smn-component b/components/camel-huaweicloud-smn/src/generated/resources/META-INF/services/org/apache/camel/configurer/hwcloud-smn-component new file mode 100644 index 0000000..47cfe3b --- /dev/null +++ b/components/camel-huaweicloud-smn/src/generated/resources/META-INF/services/org/apache/camel/configurer/hwcloud-smn-component @@ -0,0 +1,2 @@ +# Generated by camel build tools - do NOT edit this file! +class=org.apache.camel.component.huaweicloud.smn.SimpleNotificationComponentConfigurer diff --git a/components/camel-huaweicloud-smn/src/generated/resources/META-INF/services/org/apache/camel/configurer/hwcloud-smn-endpoint b/components/camel-huaweicloud-smn/src/generated/resources/META-INF/services/org/apache/camel/configurer/hwcloud-smn-endpoint new file mode 100644 index 0000000..35dc561 --- /dev/null +++ b/components/camel-huaweicloud-smn/src/generated/resources/META-INF/services/org/apache/camel/configurer/hwcloud-smn-endpoint @@ -0,0 +1,2 @@ +# Generated by camel build tools - do NOT edit this file! +class=org.apache.camel.component.huaweicloud.smn.SimpleNotificationEndpointConfigurer diff --git a/components/camel-huaweicloud-smn/src/generated/resources/META-INF/services/org/apache/camel/urifactory/hwcloud-smn-endpoint b/components/camel-huaweicloud-smn/src/generated/resources/META-INF/services/org/apache/camel/urifactory/hwcloud-smn-endpoint new file mode 100644 index 0000000..1fd9fa5 --- /dev/null +++ b/components/camel-huaweicloud-smn/src/generated/resources/META-INF/services/org/apache/camel/urifactory/hwcloud-smn-endpoint @@ -0,0 +1,2 @@ +# Generated by camel build tools - do NOT edit this file! +class=org.apache.camel.component.huaweicloud.smn.SimpleNotificationEndpointUriFactory diff --git a/components/camel-huaweicloud-smn/src/generated/resources/org/apache/camel/component/huaweicloud/smn/hwcloud-smn.json b/components/camel-huaweicloud-smn/src/generated/resources/org/apache/camel/component/huaweicloud/smn/hwcloud-smn.json new file mode 100644 index 0000000..340d7d4 --- /dev/null +++ b/components/camel-huaweicloud-smn/src/generated/resources/org/apache/camel/component/huaweicloud/smn/hwcloud-smn.json @@ -0,0 +1,44 @@ +{ + "component": { + "kind": "component", + "name": "hwcloud-smn", + "title": "SimpleNotification", + "description": "Huawei Cloud component to integrate with SimpleNotification services", + "deprecated": false, + "firstVersion": "3.8.0", + "label": "cloud,messaging", + "javaType": "org.apache.camel.component.huaweicloud.smn.SimpleNotificationComponent", + "supportLevel": "Preview", + "groupId": "org.apache.camel", + "artifactId": "camel-huaweicloud-smn", + "version": "3.8.0-SNAPSHOT", + "scheme": "hwcloud-smn", + "extendsScheme": "", + "syntax": "hwcloud-smn:smnService", + "async": false, + "api": false, + "consumerOnly": false, + "producerOnly": true, + "lenientProperties": false + }, + "componentProperties": { + "lazyStartProducer": { "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 during star [...] + "autowiredEnabled": { "kind": "property", "displayName": "Autowired Enabled", "group": "advanced", "label": "advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": true, "description": "Whether autowiring is enabled. This is used for automatic autowiring options (the option must be marked as autowired) by looking up in the registry to find if there is a single instance of matching type, which t [...] + }, + "properties": { + "smnService": { "kind": "path", "displayName": "Service name", "group": "producer", "label": "producer", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "Name of SMN service to invoke" }, + "authKey": { "kind": "parameter", "displayName": "API authentication key (AK)", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": true, "description": "Authentication key for the cloud user" }, + "ignoreSslVerification": { "kind": "parameter", "displayName": "SSL Verification Ignored", "group": "producer", "label": "", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "defaultValue": false, "description": "Ignore SSL verification" }, + "lazyStartProducer": { "kind": "parameter", "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 during sta [...] + "messageTtl": { "kind": "parameter", "displayName": "Message TTL", "group": "producer", "label": "", "required": false, "type": "integer", "javaType": "int", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "defaultValue": 3600, "description": "TTL for published message" }, + "operation": { "kind": "parameter", "displayName": "Operation name", "group": "producer", "label": "producer", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "Name of operation to perform" }, + "projectId": { "kind": "parameter", "displayName": "Project ID", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "Cloud project ID" }, + "proxyHost": { "kind": "parameter", "displayName": "Proxy server host", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "Proxy server ip\/hostname" }, + "proxyPassword": { "kind": "parameter", "displayName": "Proxy password", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": true, "description": "Proxy authentication password" }, + "proxyPort": { "kind": "parameter", "displayName": "Proxy server port", "group": "producer", "label": "", "required": false, "type": "integer", "javaType": "int", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "Proxy server port" }, + "proxyUser": { "kind": "parameter", "displayName": "Proxy user", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": true, "description": "Proxy authentication user" }, + "region": { "kind": "parameter", "displayName": "Service region", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": false, "description": "SMN service region" }, + "secretKey": { "kind": "parameter", "displayName": "API secret key (SK)", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": true, "description": "Secret key for the cloud user" }, + "serviceKeys": { "kind": "parameter", "displayName": "Service Configuration", "group": "producer", "label": "", "required": false, "type": "object", "javaType": "org.apache.camel.component.huaweicloud.smn.models.ServiceKeys", "deprecated": false, "deprecationNote": "", "autowired": false, "secret": true, "description": "Configuration object for cloud service authentication" } + } +} diff --git a/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/HwcloudSmnComponentBuilderFactory.java b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/HwcloudSmnComponentBuilderFactory.java new file mode 100644 index 0000000..82589bb --- /dev/null +++ b/core/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/HwcloudSmnComponentBuilderFactory.java @@ -0,0 +1,121 @@ +/* + * 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.builder.component.dsl; + +import javax.annotation.Generated; +import org.apache.camel.Component; +import org.apache.camel.builder.component.AbstractComponentBuilder; +import org.apache.camel.builder.component.ComponentBuilder; +import org.apache.camel.component.huaweicloud.smn.SimpleNotificationComponent; + +/** + * Huawei Cloud component to integrate with SimpleNotification services + * + * Generated by camel-package-maven-plugin - do not edit this file! + */ +@Generated("org.apache.camel.maven.packaging.ComponentDslMojo") +public interface HwcloudSmnComponentBuilderFactory { + + /** + * SimpleNotification (camel-huaweicloud-smn) + * Huawei Cloud component to integrate with SimpleNotification services + * + * Category: cloud,messaging + * Since: 3.8 + * Maven coordinates: org.apache.camel:camel-huaweicloud-smn + * + * @return the dsl builder + */ + static HwcloudSmnComponentBuilder hwcloudSmn() { + return new HwcloudSmnComponentBuilderImpl(); + } + + /** + * Builder for the SimpleNotification component. + */ + interface HwcloudSmnComponentBuilder + extends + ComponentBuilder<SimpleNotificationComponent> { + /** + * 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 starting the + * producer may take a little time and prolong the total processing time + * of the processing. + * + * The option is a: <code>boolean</code> type. + * + * Default: false + * Group: producer + * + * @param lazyStartProducer the value to set + * @return the dsl builder + */ + default HwcloudSmnComponentBuilder lazyStartProducer( + boolean lazyStartProducer) { + doSetProperty("lazyStartProducer", lazyStartProducer); + return this; + } + /** + * Whether autowiring is enabled. This is used for automatic autowiring + * options (the option must be marked as autowired) by looking up in the + * registry to find if there is a single instance of matching type, + * which then gets configured on the component. This can be used for + * automatic configuring JDBC data sources, JMS connection factories, + * AWS Clients, etc. + * + * The option is a: <code>boolean</code> type. + * + * Default: true + * Group: advanced + * + * @param autowiredEnabled the value to set + * @return the dsl builder + */ + default HwcloudSmnComponentBuilder autowiredEnabled( + boolean autowiredEnabled) { + doSetProperty("autowiredEnabled", autowiredEnabled); + return this; + } + } + + class HwcloudSmnComponentBuilderImpl + extends + AbstractComponentBuilder<SimpleNotificationComponent> + implements + HwcloudSmnComponentBuilder { + @Override + protected SimpleNotificationComponent buildConcreteComponent() { + return new SimpleNotificationComponent(); + } + @Override + protected boolean setPropertyOnComponent( + Component component, + String name, + Object value) { + switch (name) { + case "lazyStartProducer": ((SimpleNotificationComponent) component).setLazyStartProducer((boolean) value); return true; + case "autowiredEnabled": ((SimpleNotificationComponent) component).setAutowiredEnabled((boolean) value); return true; + default: return false; + } + } + } +} \ No newline at end of file diff --git a/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/SimpleNotificationEndpointBuilderFactory.java b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/SimpleNotificationEndpointBuilderFactory.java new file mode 100644 index 0000000..e77fbc5 --- /dev/null +++ b/core/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/SimpleNotificationEndpointBuilderFactory.java @@ -0,0 +1,383 @@ +/* + * 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.builder.endpoint.dsl; + +import javax.annotation.Generated; +import org.apache.camel.builder.EndpointConsumerBuilder; +import org.apache.camel.builder.EndpointProducerBuilder; +import org.apache.camel.builder.endpoint.AbstractEndpointBuilder; + +/** + * Huawei Cloud component to integrate with SimpleNotification services + * + * Generated by camel build tools - do NOT edit this file! + */ +@Generated("org.apache.camel.maven.packaging.EndpointDslMojo") +public interface SimpleNotificationEndpointBuilderFactory { + + + /** + * Builder for endpoint for the SimpleNotification component. + */ + public interface SimpleNotificationEndpointBuilder + extends + EndpointProducerBuilder { + /** + * Authentication key for the cloud user. + * + * The option is a: <code>java.lang.String</code> type. + * + * Required: true + * Group: producer + * + * @param authKey the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder authKey(String authKey) { + doSetProperty("authKey", authKey); + return this; + } + /** + * Ignore SSL verification. + * + * The option is a: <code>boolean</code> type. + * + * Default: false + * Group: producer + * + * @param ignoreSslVerification the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder ignoreSslVerification( + boolean ignoreSslVerification) { + doSetProperty("ignoreSslVerification", ignoreSslVerification); + return this; + } + /** + * Ignore SSL verification. + * + * The option will be converted to a <code>boolean</code> + * type. + * + * Default: false + * Group: producer + * + * @param ignoreSslVerification the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder ignoreSslVerification( + String ignoreSslVerification) { + doSetProperty("ignoreSslVerification", ignoreSslVerification); + return this; + } + /** + * 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 starting the + * producer may take a little time and prolong the total processing time + * of the processing. + * + * The option is a: <code>boolean</code> type. + * + * Default: false + * Group: producer + * + * @param lazyStartProducer the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder lazyStartProducer( + boolean lazyStartProducer) { + doSetProperty("lazyStartProducer", lazyStartProducer); + return this; + } + /** + * 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 starting the + * producer may take a little time and prolong the total processing time + * of the processing. + * + * The option will be converted to a <code>boolean</code> + * type. + * + * Default: false + * Group: producer + * + * @param lazyStartProducer the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder lazyStartProducer( + String lazyStartProducer) { + doSetProperty("lazyStartProducer", lazyStartProducer); + return this; + } + /** + * TTL for published message. + * + * The option is a: <code>int</code> type. + * + * Default: 3600 + * Group: producer + * + * @param messageTtl the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder messageTtl(int messageTtl) { + doSetProperty("messageTtl", messageTtl); + return this; + } + /** + * TTL for published message. + * + * The option will be converted to a <code>int</code> type. + * + * Default: 3600 + * Group: producer + * + * @param messageTtl the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder messageTtl(String messageTtl) { + doSetProperty("messageTtl", messageTtl); + return this; + } + /** + * Name of operation to perform. + * + * The option is a: <code>java.lang.String</code> type. + * + * Required: true + * Group: producer + * + * @param operation the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder operation(String operation) { + doSetProperty("operation", operation); + return this; + } + /** + * Cloud project ID. + * + * The option is a: <code>java.lang.String</code> type. + * + * Required: true + * Group: producer + * + * @param projectId the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder projectId(String projectId) { + doSetProperty("projectId", projectId); + return this; + } + /** + * Proxy server ip/hostname. + * + * The option is a: <code>java.lang.String</code> type. + * + * Group: producer + * + * @param proxyHost the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder proxyHost(String proxyHost) { + doSetProperty("proxyHost", proxyHost); + return this; + } + /** + * Proxy authentication password. + * + * The option is a: <code>java.lang.String</code> type. + * + * Group: producer + * + * @param proxyPassword the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder proxyPassword( + String proxyPassword) { + doSetProperty("proxyPassword", proxyPassword); + return this; + } + /** + * Proxy server port. + * + * The option is a: <code>int</code> type. + * + * Group: producer + * + * @param proxyPort the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder proxyPort(int proxyPort) { + doSetProperty("proxyPort", proxyPort); + return this; + } + /** + * Proxy server port. + * + * The option will be converted to a <code>int</code> type. + * + * Group: producer + * + * @param proxyPort the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder proxyPort(String proxyPort) { + doSetProperty("proxyPort", proxyPort); + return this; + } + /** + * Proxy authentication user. + * + * The option is a: <code>java.lang.String</code> type. + * + * Group: producer + * + * @param proxyUser the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder proxyUser(String proxyUser) { + doSetProperty("proxyUser", proxyUser); + return this; + } + /** + * SMN service region. + * + * The option is a: <code>java.lang.String</code> type. + * + * Required: true + * Group: producer + * + * @param region the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder region(String region) { + doSetProperty("region", region); + return this; + } + /** + * Secret key for the cloud user. + * + * The option is a: <code>java.lang.String</code> type. + * + * Required: true + * Group: producer + * + * @param secretKey the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder secretKey(String secretKey) { + doSetProperty("secretKey", secretKey); + return this; + } + /** + * Configuration object for cloud service authentication. + * + * The option is a: + * <code>org.apache.camel.component.huaweicloud.smn.models.ServiceKeys</code> type. + * + * Group: producer + * + * @param serviceKeys the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder serviceKeys(Object serviceKeys) { + doSetProperty("serviceKeys", serviceKeys); + return this; + } + /** + * Configuration object for cloud service authentication. + * + * The option will be converted to a + * <code>org.apache.camel.component.huaweicloud.smn.models.ServiceKeys</code> type. + * + * Group: producer + * + * @param serviceKeys the value to set + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder serviceKeys(String serviceKeys) { + doSetProperty("serviceKeys", serviceKeys); + return this; + } + } + + public interface SimpleNotificationBuilders { + /** + * SimpleNotification (camel-huaweicloud-smn) + * Huawei Cloud component to integrate with SimpleNotification services + * + * Category: cloud,messaging + * Since: 3.8 + * Maven coordinates: org.apache.camel:camel-huaweicloud-smn + * + * Syntax: <code>hwcloud-smn:smnService</code> + * + * Path parameter: smnService (required) + * Name of SMN service to invoke + * + * @param path smnService + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder hwcloudSmn(String path) { + return SimpleNotificationEndpointBuilderFactory.endpointBuilder("hwcloud-smn", path); + } + /** + * SimpleNotification (camel-huaweicloud-smn) + * Huawei Cloud component to integrate with SimpleNotification services + * + * Category: cloud,messaging + * Since: 3.8 + * Maven coordinates: org.apache.camel:camel-huaweicloud-smn + * + * Syntax: <code>hwcloud-smn:smnService</code> + * + * Path parameter: smnService (required) + * Name of SMN service to invoke + * + * @param componentName to use a custom component name for the endpoint + * instead of the default name + * @param path smnService + * @return the dsl builder + */ + default SimpleNotificationEndpointBuilder hwcloudSmn( + String componentName, + String path) { + return SimpleNotificationEndpointBuilderFactory.endpointBuilder(componentName, path); + } + } + static SimpleNotificationEndpointBuilder endpointBuilder( + String componentName, + String path) { + class SimpleNotificationEndpointBuilderImpl extends AbstractEndpointBuilder implements SimpleNotificationEndpointBuilder { + public SimpleNotificationEndpointBuilderImpl(String path) { + super(componentName, path); + } + } + return new SimpleNotificationEndpointBuilderImpl(path); + } +} \ No newline at end of file