flume 1.2.0自定义源代码

hjzp0vay  于 2021-06-03  发布在  Hadoop
关注(0)|答案(1)|浏览(335)

我有一个自己开发的事件收集和处理框架,我希望在开始将数据加载到hadoop时,用apacheflume 1.2.0替代它。因为flume没有http源代码,所以我正在编写一个带有嵌入式tomcat服务器的自定义源代码。我正在跟踪http://flume.apache.org/flumeuserguide.html#custom-但是,当我开始时,出现以下异常:
java.lang.illegalargumentexception:没有源com...flume的已知运行程序类型。testsource@5219f360 在org.apache.flume.sourcerunner.forsource(sourcerunner。java:54)在org.apache.flume.conf.properties.propertiesfileconfigurationprovider.loadsources(propertiesfileconfigurationprovider。java:340)在org.apache.flume.conf.properties.propertiesfileconfigurationprovider.load(propertiesfileconfigurationprovider。java:222)位于org.apache.flume.conf.file.abstractfileconfigurationprovider.doload(abstractfileconfigurationprovider)。java:123)在org.apache.flume.conf.file.abstractfileconfigurationprovider.access$300(abstractfileconfigurationprovider。java:38)在org.apache.flume.conf.file.abstractfileconfigurationprovider$filewatcherrunnable.run(abstractfileconfigurationprovider)中。java:202)在java.util.concurrent.executors$runnableadapter.call(executors。java:471)在java.util.concurrent.futuretask$sync.innerrunandreset(futuretask。java:351)在java.util.concurrent.futuretask.runandreset(futuretask。java:178)在java.util.concurrent.scheduledthreadpoolexecutor$scheduledfuturetask.access$301(scheduledthreadpoolexecutor。java:178)在java.util.concurrent.scheduledthreadpoolexecutor$scheduledfuturetask.run(scheduledthreadpoolexecutor。java:293)位于java.util.concurrent.threadpoolexecutor.runworker(threadpoolexecutor。java:1110)在java.util.concurrent.threadpoolexecutor$worker.run(threadpoolexecutor。java:603)在java.lang.thread.run(线程。java:722)

56lgkhnf

56lgkhnf1#

我想我知道了。flume网站上的文档没有提到一个定制的实现,它不应该实现源接口,而应该实现eventdrivensource或pollablesource接口。

相关问题