I am getting following error while starting my source connector:
[2022-03-14 09:48:10,669] INFO [http-source|task-0] TemplateHttpRequestFactoryConfig values:
http.request.body =
http.request.headers = Accept:application/json
http.request.method = GET
http.request.params =
http.request.template.factory = class com.github.castorm.kafka.connect.http.request.template.freemarker.BackwardsCompatibleFreeMarkerTemplateFactory
http.request.url = http://localhost:8080/api/messages
(com.github.castorm.kafka.connect.http.request.template.TemplateHttpRequestFactoryConfig:376)
[2022-03-14 09:48:10,671] ERROR [http-source|task-0] WorkerSourceTask{id=http-source-0} Task threw an uncaught and unrecoverable exception. Task is being killed and will not recover until manually restarted (org.apache.kafka.connect.runtime.WorkerTask:195)
java.lang.NoClassDefFoundError: freemarker/template/Configuration
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2671)
at java.lang.Class.getConstructor0(Class.java:3075)
at java.lang.Class.getDeclaredConstructor(Class.java:2178)
at org.apache.kafka.common.utils.Utils.newInstance(Utils.java:390)
at org.apache.kafka.common.config.AbstractConfig.getConfiguredInstance(AbstractConfig.java:399)
at org.apache.kafka.common.config.AbstractConfig.getConfiguredInstance(AbstractConfig.java:434)
at org.apache.kafka.common.config.AbstractConfig.getConfiguredInstance(AbstractConfig.java:419)
at com.github.castorm.kafka.connect.http.request.template.TemplateHttpRequestFactoryConfig.(TemplateHttpRequestFactoryConfig.java:66)
at com.github.castorm.kafka.connect.http.request.template.TemplateHttpRequestFactory.configure(TemplateHttpRequestFactory.java:48)
at org.apache.kafka.common.config.AbstractConfig.getConfiguredInstance(AbstractConfig.java:405)
at org.apache.kafka.common.config.AbstractConfig.getConfiguredInstance(AbstractConfig.java:434)
at org.apache.kafka.common.config.AbstractConfig.getConfiguredInstance(AbstractConfig.java:419)
at com.github.castorm.kafka.connect.http.HttpSourceConnectorConfig.(HttpSourceConnectorConfig.java:71)
at com.github.castorm.kafka.connect.http.HttpSourceTask.start(HttpSourceTask.java:86)
at org.apache.kafka.connect.runtime.WorkerSourceTask.initializeAndStart(WorkerSourceTask.java:225)
at org.apache.kafka.connect.runtime.WorkerTask.doRun(WorkerTask.java:186)
at org.apache.kafka.connect.runtime.WorkerTask.run(WorkerTask.java:243)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.ClassNotFoundException: freemarker.template.Configuration
at java.net.URLClassLoader.findClass(URLClassLoader.java:382)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at org.apache.kafka.connect.runtime.isolation.PluginClassLoader.loadClass(PluginClassLoader.java:103)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
... 23 more
[2022-03-14 09:48:10,675] INFO [http-source|task-0] [Producer clientId=connector-producer-http-source-0] Closing the Kafka producer with timeoutMillis = 30000 ms. (org.apache.kafka.clients.producer.KafkaProducer:1208)
Same issue!
OS - Linux 36c83fe51c20 5.10.76-linuxkit
Java - openjdk version "1.8.0_131
Confluent OSS v3.3.0 - Kafka v0.11.0.0
Http connector version - castorm-kafka-connect-http-0.8.11
I am getting following error while starting my source connector:
My Source connector properties are:
I am using following version:
I can also see
freemarker-2.3.31.jar
in my libraries with others:Environment Details: OS - Windows10 Java 1.8 Confluent version - 7.0.1 (standalone) Http connector version - v0.8.11