Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,7 @@ hwcloud-smn
ibm-secrets-manager
iec60870-client
iec60870-server
iggy
ignite-cache
ignite-compute
ignite-events
Expand Down

Large diffs are not rendered by default.

48 changes: 48 additions & 0 deletions components-starter/camel-iggy-starter/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--

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.

-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.apache.camel.springboot</groupId>
<artifactId>components-starter</artifactId>
<version>4.14.0-SNAPSHOT</version>
</parent>
<artifactId>camel-iggy-starter</artifactId>
<packaging>jar</packaging>
<name>Camel SB Starters :: iggy</name>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter</artifactId>
<version>${spring-boot-version}</version>
</dependency>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-iggy</artifactId>
<version>${camel-version}</version>
</dependency>
<!--START OF GENERATED CODE-->
<dependency>
<groupId>org.apache.camel.springboot</groupId>
<artifactId>camel-core-starter</artifactId>
</dependency>
<!--END OF GENERATED CODE-->
</dependencies>
</project>
212 changes: 212 additions & 0 deletions components-starter/camel-iggy-starter/src/main/docs/iggy.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,212 @@
{
"groups": [
{
"name": "camel.component.iggy",
"type": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration"
},
{
"name": "camel.component.iggy.customizer",
"type": "org.apache.camel.spring.boot.ComponentConfigurationPropertiesCommon$CustomizerProperties",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"sourceMethod": "getCustomizer()"
}
],
"properties": [
{
"name": "camel.component.iggy.auto-commit",
"type": "java.lang.Boolean",
"description": "Controls message acknowledgment behavior. When true, messages are automatically marked as processed after consumption. When false, enables manual offset management and allows setting a custom starting offset position",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": true
},
{
"name": "camel.component.iggy.auto-create-stream",
"type": "java.lang.Boolean",
"description": "Whether to automatically create stream if it does not exist",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": true
},
{
"name": "camel.component.iggy.auto-create-topic",
"type": "java.lang.Boolean",
"description": "Whether to automatically create topic if it does not exist",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": true
},
{
"name": "camel.component.iggy.autowired-enabled",
"type": "java.lang.Boolean",
"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 then gets configured on the component. This can be used for automatic configuring JDBC data sources, JMS connection factories, AWS Clients, etc.",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": true
},
{
"name": "camel.component.iggy.bridge-error-handler",
"type": "java.lang.Boolean",
"description": "Allows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions (if possible) occurred while the Camel consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled by the routing Error Handler. Important: This is only possible if the 3rd party component allows Camel to be alerted if an exception was thrown. Some components handle this internally only, and therefore bridgeErrorHandler is not possible. In other situations we may improve the Camel component to hook into the 3rd party component and make this possible for future releases. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions, that will be logged at WARN or ERROR level and ignored.",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": false
},
{
"name": "camel.component.iggy.client-transport",
"type": "java.lang.String",
"description": "Polling strategy",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": "TCP"
},
{
"name": "camel.component.iggy.compression-algorithm",
"type": "org.apache.iggy.topic.CompressionAlgorithm",
"description": "Compression algorithm for message payload",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": "none"
},
{
"name": "camel.component.iggy.configuration",
"type": "org.apache.camel.component.iggy.IggyConfiguration",
"description": "Allows to pre-configure the Iggy component with common options that the endpoints will reuse. The option is a org.apache.camel.component.iggy.IggyConfiguration type.",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration"
},
{
"name": "camel.component.iggy.consumer-group-name",
"type": "java.lang.String",
"description": "The name of the consumer group",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration"
},
{
"name": "camel.component.iggy.consumers-count",
"type": "java.lang.Integer",
"description": "Camel Iggy consumers count",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": 1
},
{
"name": "camel.component.iggy.customizer.enabled",
"type": "java.lang.Boolean",
"sourceType": "org.apache.camel.spring.boot.ComponentConfigurationPropertiesCommon$CustomizerProperties"
},
{
"name": "camel.component.iggy.enabled",
"type": "java.lang.Boolean",
"description": "Whether to enable auto configuration of the iggy component. This is enabled by default.",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration"
},
{
"name": "camel.component.iggy.host",
"type": "java.lang.String",
"description": "Iggy server hostname or IP address",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": "localhost"
},
{
"name": "camel.component.iggy.lazy-start-producer",
"type": "java.lang.Boolean",
"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 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.",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": false
},
{
"name": "camel.component.iggy.max-topic-size",
"type": "java.lang.Long",
"description": "Maximum topic size in bytes (0 means unlimited)",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": 0
},
{
"name": "camel.component.iggy.message-expiry",
"type": "java.lang.Long",
"description": "Message expiry time in seconds (0 means no expiry)",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": 0
},
{
"name": "camel.component.iggy.partition-id",
"type": "java.lang.Long",
"description": "The consumer partition id",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration"
},
{
"name": "camel.component.iggy.partitioning",
"type": "org.apache.iggy.message.Partitioning",
"description": "Partitioning strategy for message distribution. The option is a org.apache.iggy.message.Partitioning type.",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration"
},
{
"name": "camel.component.iggy.partitions-count",
"type": "java.lang.Long",
"description": "Number of partitions for the topic",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": 1
},
{
"name": "camel.component.iggy.password",
"type": "java.lang.String",
"description": "Iggy password",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration"
},
{
"name": "camel.component.iggy.poll-batch-size",
"type": "java.lang.Long",
"description": "The consumer poll batch size",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": 10
},
{
"name": "camel.component.iggy.polling-strategy",
"type": "java.lang.String",
"description": "Polling strategy",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": "next"
},
{
"name": "camel.component.iggy.port",
"type": "java.lang.Integer",
"description": "Iggy server port number",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": 8090
},
{
"name": "camel.component.iggy.replication-factor",
"type": "java.lang.Short",
"description": "Replication factor for the topic",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration"
},
{
"name": "camel.component.iggy.shutdown-timeout",
"type": "java.lang.Integer",
"description": "Camel Iggy shutdown timeout",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": 30000
},
{
"name": "camel.component.iggy.starting-offset",
"type": "java.lang.Long",
"description": "Defines the initial message offset position when autoCommit is disabled. Use 0 to start from the beginning of the stream, or specify a custom offset to resume from a particular point",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration",
"defaultValue": 0
},
{
"name": "camel.component.iggy.stream-id",
"type": "java.lang.Long",
"description": "Stream identifier",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration"
},
{
"name": "camel.component.iggy.stream-name",
"type": "java.lang.String",
"description": "Stream name",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration"
},
{
"name": "camel.component.iggy.username",
"type": "java.lang.String",
"description": "Iggy username",
"sourceType": "org.apache.camel.component.iggy.springboot.IggyComponentConfiguration"
}
],
"hints": [],
"ignored": {
"properties": []
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
/*
* 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.iggy.springboot;

import org.apache.camel.CamelContext;
import org.apache.camel.Component;
import org.apache.camel.component.iggy.IggyComponent;
import org.apache.camel.spi.ComponentCustomizer;
import org.apache.camel.spring.boot.CamelAutoConfiguration;
import org.apache.camel.spring.boot.ComponentConfigurationProperties;
import org.apache.camel.spring.boot.util.CamelPropertiesHelper;
import org.apache.camel.spring.boot.util.ConditionalOnCamelContextAndAutoConfigurationBeans;
import org.apache.camel.spring.boot.util.ConditionalOnHierarchicalProperties;
import org.apache.camel.spring.boot.util.HierarchicalPropertiesEvaluator;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.autoconfigure.AutoConfigureAfter;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Conditional;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Lazy;

/**
* Generated by camel-package-maven-plugin - do not edit this file!
*/
@Configuration(proxyBeanMethods = false)
@Conditional(ConditionalOnCamelContextAndAutoConfigurationBeans.class)
@EnableConfigurationProperties({ComponentConfigurationProperties.class,IggyComponentConfiguration.class})
@ConditionalOnHierarchicalProperties({"camel.component", "camel.component.iggy"})
@AutoConfigureAfter({CamelAutoConfiguration.class, IggyComponentConverter.class})
public class IggyComponentAutoConfiguration {

@Autowired
private ApplicationContext applicationContext;
private final CamelContext camelContext;
@Autowired
private IggyComponentConfiguration configuration;

public IggyComponentAutoConfiguration(
org.apache.camel.CamelContext camelContext) {
this.camelContext = camelContext;
}

@Lazy
@Bean
public ComponentCustomizer configureIggyComponent() {
return new ComponentCustomizer() {
@Override
public void configure(String name, Component target) {
CamelPropertiesHelper.copyProperties(camelContext, configuration, target);
}
@Override
public boolean isEnabled(String name, Component target) {
return HierarchicalPropertiesEvaluator.evaluate(
applicationContext,
"camel.component.customizer",
"camel.component.iggy.customizer")
&& target instanceof IggyComponent;
}
};
}
}
Loading
Loading