Skip to content
Closed
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
5 changes: 5 additions & 0 deletions bom/camel-bom/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1102,6 +1102,11 @@
<artifactId>camel-health</artifactId>
<version>4.23.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-hivemq</artifactId>
<version>4.23.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-hl7</artifactId>
Expand Down
5 changes: 5 additions & 0 deletions catalog/camel-allcomponents/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -972,6 +972,11 @@
<artifactId>camel-hazelcast</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-hivemq</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-hl7</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,7 @@ hazelcast-ringbuffer
hazelcast-seda
hazelcast-set
hazelcast-topic
hivemq
http
https
huggingface
Expand Down

Large diffs are not rendered by default.

71 changes: 71 additions & 0 deletions components/camel-hivemq/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
<?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/xsd/maven-4.0.0.xsd">

<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.apache.camel</groupId>
<artifactId>components</artifactId>
<version>4.23.0-SNAPSHOT</version>
</parent>

<artifactId>camel-hivemq</artifactId>
<packaging>jar</packaging>
<name>Camel :: HiveMQ</name>
<description>Camel HiveMQ MQTT Client support</description>

<dependencies>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-support</artifactId>
</dependency>
<dependency>
<groupId>com.hivemq</groupId>
<artifactId>hivemq-mqtt-client</artifactId>
<version>${hivemq-mqtt-client-version}</version>
</dependency>

<!-- Test Infra -->
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-test-junit6</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.assertj</groupId>
<artifactId>assertj-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-test-infra-core</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-test-infra-hivemq</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
</dependencies>

</project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
/* Generated by camel build tools - do NOT edit this file! */
package org.apache.camel.component.hivemq;

import javax.annotation.processing.Generated;
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!
*/
@Generated("org.apache.camel.maven.packaging.EndpointSchemaGeneratorMojo")
@SuppressWarnings("unchecked")
public class HiveMQComponentConfigurer extends PropertyConfigurerSupport implements GeneratedPropertyConfigurer, PropertyConfigurerGetter {

private org.apache.camel.component.hivemq.HiveMQConfiguration getOrCreateConfiguration(HiveMQComponent target) {
if (target.getConfiguration() == null) {
target.setConfiguration(new org.apache.camel.component.hivemq.HiveMQConfiguration());
}
return target.getConfiguration();
}

@Override
public boolean configure(CamelContext camelContext, Object obj, String name, Object value, boolean ignoreCase) {
HiveMQComponent target = (HiveMQComponent) obj;
switch (ignoreCase ? name.toLowerCase() : name) {
case "autowiredenabled":
case "autowiredEnabled": target.setAutowiredEnabled(property(camelContext, boolean.class, value)); return true;
case "bridgeerrorhandler":
case "bridgeErrorHandler": target.setBridgeErrorHandler(property(camelContext, boolean.class, value)); return true;
case "cleanstart":
case "cleanStart": getOrCreateConfiguration(target).setCleanStart(property(camelContext, boolean.class, value)); return true;
case "clientid":
case "clientId": getOrCreateConfiguration(target).setClientId(property(camelContext, java.lang.String.class, value)); return true;
case "configuration": target.setConfiguration(property(camelContext, org.apache.camel.component.hivemq.HiveMQConfiguration.class, value)); return true;
case "host": getOrCreateConfiguration(target).setHost(property(camelContext, java.lang.String.class, value)); return true;
case "lazystartproducer":
case "lazyStartProducer": target.setLazyStartProducer(property(camelContext, boolean.class, value)); return true;
case "password": getOrCreateConfiguration(target).setPassword(property(camelContext, java.lang.String.class, value)); return true;
case "port": getOrCreateConfiguration(target).setPort(property(camelContext, int.class, value)); return true;
case "qos": getOrCreateConfiguration(target).setQos(property(camelContext, com.hivemq.client.mqtt.datatypes.MqttQos.class, value)); return true;
case "retained": getOrCreateConfiguration(target).setRetained(property(camelContext, boolean.class, value)); return true;
case "ssl": getOrCreateConfiguration(target).setSsl(property(camelContext, boolean.class, value)); return true;
case "username": getOrCreateConfiguration(target).setUsername(property(camelContext, java.lang.String.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 "bridgeerrorhandler":
case "bridgeErrorHandler": return boolean.class;
case "cleanstart":
case "cleanStart": return boolean.class;
case "clientid":
case "clientId": return java.lang.String.class;
case "configuration": return org.apache.camel.component.hivemq.HiveMQConfiguration.class;
case "host": return java.lang.String.class;
case "lazystartproducer":
case "lazyStartProducer": return boolean.class;
case "password": return java.lang.String.class;
case "port": return int.class;
case "qos": return com.hivemq.client.mqtt.datatypes.MqttQos.class;
case "retained": return boolean.class;
case "ssl": return boolean.class;
case "username": return java.lang.String.class;
default: return null;
}
}

@Override
public Object getOptionValue(Object obj, String name, boolean ignoreCase) {
HiveMQComponent target = (HiveMQComponent) obj;
switch (ignoreCase ? name.toLowerCase() : name) {
case "autowiredenabled":
case "autowiredEnabled": return target.isAutowiredEnabled();
case "bridgeerrorhandler":
case "bridgeErrorHandler": return target.isBridgeErrorHandler();
case "cleanstart":
case "cleanStart": return getOrCreateConfiguration(target).isCleanStart();
case "clientid":
case "clientId": return getOrCreateConfiguration(target).getClientId();
case "configuration": return target.getConfiguration();
case "host": return getOrCreateConfiguration(target).getHost();
case "lazystartproducer":
case "lazyStartProducer": return target.isLazyStartProducer();
case "password": return getOrCreateConfiguration(target).getPassword();
case "port": return getOrCreateConfiguration(target).getPort();
case "qos": return getOrCreateConfiguration(target).getQos();
case "retained": return getOrCreateConfiguration(target).isRetained();
case "ssl": return getOrCreateConfiguration(target).isSsl();
case "username": return getOrCreateConfiguration(target).getUsername();
default: return null;
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
/* Generated by camel build tools - do NOT edit this file! */
package org.apache.camel.component.hivemq;

import javax.annotation.processing.Generated;
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!
*/
@Generated("org.apache.camel.maven.packaging.EndpointSchemaGeneratorMojo")
@SuppressWarnings("unchecked")
public class HiveMQEndpointConfigurer extends PropertyConfigurerSupport implements GeneratedPropertyConfigurer, PropertyConfigurerGetter {

@Override
public boolean configure(CamelContext camelContext, Object obj, String name, Object value, boolean ignoreCase) {
HiveMQEndpoint target = (HiveMQEndpoint) obj;
switch (ignoreCase ? name.toLowerCase() : name) {
case "bridgeerrorhandler":
case "bridgeErrorHandler": target.setBridgeErrorHandler(property(camelContext, boolean.class, value)); return true;
case "cleanstart":
case "cleanStart": target.getConfiguration().setCleanStart(property(camelContext, boolean.class, value)); return true;
case "clientid":
case "clientId": target.getConfiguration().setClientId(property(camelContext, java.lang.String.class, value)); return true;
case "exceptionhandler":
case "exceptionHandler": target.setExceptionHandler(property(camelContext, org.apache.camel.spi.ExceptionHandler.class, value)); return true;
case "exchangepattern":
case "exchangePattern": target.setExchangePattern(property(camelContext, org.apache.camel.ExchangePattern.class, value)); return true;
case "host": target.getConfiguration().setHost(property(camelContext, java.lang.String.class, value)); return true;
case "lazystartproducer":
case "lazyStartProducer": target.setLazyStartProducer(property(camelContext, boolean.class, value)); return true;
case "password": target.getConfiguration().setPassword(property(camelContext, java.lang.String.class, value)); return true;
case "port": target.getConfiguration().setPort(property(camelContext, int.class, value)); return true;
case "qos": target.getConfiguration().setQos(property(camelContext, com.hivemq.client.mqtt.datatypes.MqttQos.class, value)); return true;
case "retained": target.getConfiguration().setRetained(property(camelContext, boolean.class, value)); return true;
case "ssl": target.getConfiguration().setSsl(property(camelContext, boolean.class, value)); return true;
case "username": target.getConfiguration().setUsername(property(camelContext, java.lang.String.class, value)); return true;
default: return false;
}
}

@Override
public Class<?> getOptionType(String name, boolean ignoreCase) {
switch (ignoreCase ? name.toLowerCase() : name) {
case "bridgeerrorhandler":
case "bridgeErrorHandler": return boolean.class;
case "cleanstart":
case "cleanStart": return boolean.class;
case "clientid":
case "clientId": return java.lang.String.class;
case "exceptionhandler":
case "exceptionHandler": return org.apache.camel.spi.ExceptionHandler.class;
case "exchangepattern":
case "exchangePattern": return org.apache.camel.ExchangePattern.class;
case "host": return java.lang.String.class;
case "lazystartproducer":
case "lazyStartProducer": return boolean.class;
case "password": return java.lang.String.class;
case "port": return int.class;
case "qos": return com.hivemq.client.mqtt.datatypes.MqttQos.class;
case "retained": return boolean.class;
case "ssl": return boolean.class;
case "username": return java.lang.String.class;
default: return null;
}
}

@Override
public Object getOptionValue(Object obj, String name, boolean ignoreCase) {
HiveMQEndpoint target = (HiveMQEndpoint) obj;
switch (ignoreCase ? name.toLowerCase() : name) {
case "bridgeerrorhandler":
case "bridgeErrorHandler": return target.isBridgeErrorHandler();
case "cleanstart":
case "cleanStart": return target.getConfiguration().isCleanStart();
case "clientid":
case "clientId": return target.getConfiguration().getClientId();
case "exceptionhandler":
case "exceptionHandler": return target.getExceptionHandler();
case "exchangepattern":
case "exchangePattern": return target.getExchangePattern();
case "host": return target.getConfiguration().getHost();
case "lazystartproducer":
case "lazyStartProducer": return target.isLazyStartProducer();
case "password": return target.getConfiguration().getPassword();
case "port": return target.getConfiguration().getPort();
case "qos": return target.getConfiguration().getQos();
case "retained": return target.getConfiguration().isRetained();
case "ssl": return target.getConfiguration().isSsl();
case "username": return target.getConfiguration().getUsername();
default: return null;
}
}
}
Loading
Loading