flume-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From P lva <ruvi...@gmail.com>
Subject Re: Flume with ActiveMQ
Date Mon, 24 Feb 2014 20:48:33 GMT
If there is no connection factory called 'GenericConnectionFactory' the
lookup fails and you get this.



On Mon, Feb 24, 2014 at 1:29 PM, richard ross <richard.prionses@gmail.com>wrote:

> Thanks for the reply. No, there is no authentication setup yet.
>
> Here's a little of what I have figured out since the original email. I was
> misinterpreting the error from using "GenericConnectionFactory" or "
> org.apache.activemq.ActiveMQConnectionFactory", as this is just the JNDI
> context name. The error is simply coming from the lookup call from the initial
> context. As to why that error is occurring, I still have no idea.
>
> Richard.
>
>
> On Mon, Feb 24, 2014 at 1:35 PM, P lva <ruvikal@gmail.com> wrote:
>
>> Does the queue need any username and password ?
>>
>>
>> On Mon, Feb 24, 2014 at 11:41 AM, richard ross <
>> richard.prionses@gmail.com> wrote:
>>
>>> Hello:
>>>
>>> I am doing a POC using Flume (1.4) with a JMS (ActiveMQ 5.6) source. I
>>> have used the example source configuration from the documentation:
>>>
>>> a1.sources = r1a1.channels = c1a1.sources.r1.type = jmsa1.sources.r1.channels
= c1a1.sources.r1.initialContextFactory = org.apache.activemq.jndi.ActiveMQInitialContextFactorya1.sources.r1.connectionFactory
= GenericConnectionFactorya1.sources.r1.providerURL = tcp://<myipaddress>:61616a1.sources.r1.destinationName
= TESTa1.sources.r1.destinationType = QUEUE
>>>
>>>
>>> I get the following error:
>>>
>>> 2014-02-24 12:33:05,959 (conf-file-poller-0) [ERROR -
>>> org.apache.flume.node.AbstractConfigurationProvider.loadSources(AbstractConfigurationProvider.java:366)]
>>> Source r1 has been removed due to an error during configuration
>>> org.apache.flume.FlumeException: Could not lookup ConnectionFactory
>>>         at
>>> org.apache.flume.source.jms.JMSSource.doConfigure(JMSSource.java:222)
>>>         at
>>> org.apache.flume.source.BasicSourceSemantics.configure(BasicSourceSemantics.java:65)
>>>         at
>>> org.apache.flume.conf.Configurables.configure(Configurables.java:41)
>>>         at
>>> org.apache.flume.node.AbstractConfigurationProvider.loadSources(AbstractConfigurationProvider.java:331)
>>>         at
>>> org.apache.flume.node.AbstractConfigurationProvider.getConfiguration(AbstractConfigurationProvider.java:102)
>>>         at
>>> org.apache.flume.node.PollingPropertiesFileConfigurationProvider$FileWatcherRunnable.run(PollingPropertiesFileConfigurationProvider.java:140)
>>>         at
>>> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
>>>         at
>>> java.util.concurrent.FutureTask.runAndReset(FutureTask.java:304)
>>>         at
>>> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:178)
>>>         at
>>> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
>>>         at
>>> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
>>>         at
>>> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
>>>         at java.lang.Thread.run(Thread.java:744)
>>> Caused by: javax.naming.NameNotFoundException: GenericConnectionFactory
>>>         at
>>> org.apache.activemq.jndi.ReadOnlyContext.lookup(ReadOnlyContext.java:235)
>>>         at javax.naming.InitialContext.lookup(InitialContext.java:411)
>>>         at
>>> org.apache.flume.source.jms.JMSSource.doConfigure(JMSSource.java:219)
>>>         ... 12 more
>>>
>>> I looked at the ActiveMQ codebase, and it doesn't seem that there is a
>>> GenericConnectionFactory. So I changed it to use org.apache.activemq.ActiveMQConnectionFactory.
>>> I get the same error:
>>>
>>> 2014-02-24 12:36:39,192 (conf-file-poller-0) [ERROR -
>>> org.apache.flume.node.AbstractConfigurationProvider.loadSources(AbstractConfigurationProvider.java:366)]
>>> Source r1 has been removed due to an error during configuration
>>> org.apache.flume.FlumeException: Could not lookup ConnectionFactory
>>>         at
>>> org.apache.flume.source.jms.JMSSource.doConfigure(JMSSource.java:222)
>>>         at
>>> org.apache.flume.source.BasicSourceSemantics.configure(BasicSourceSemantics.java:65)
>>>         at
>>> org.apache.flume.conf.Configurables.configure(Configurables.java:41)
>>>         at
>>> org.apache.flume.node.AbstractConfigurationProvider.loadSources(AbstractConfigurationProvider.java:331)
>>>         at
>>> org.apache.flume.node.AbstractConfigurationProvider.getConfiguration(AbstractConfigurationProvider.java:102)
>>>         at
>>> org.apache.flume.node.PollingPropertiesFileConfigurationProvider$FileWatcherRunnable.run(PollingPropertiesFileConfigurationProvider.java:140)
>>>         at
>>> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
>>>         at
>>> java.util.concurrent.FutureTask.runAndReset(FutureTask.java:304)
>>>         at
>>> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:178)
>>>         at
>>> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293)
>>>         at
>>> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
>>>         at
>>> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
>>>         at java.lang.Thread.run(Thread.java:744)
>>> Caused by: javax.naming.NameNotFoundException:
>>> org.apache.activemq.ActiveMQConnectionFactory
>>>         at
>>> org.apache.activemq.jndi.ReadOnlyContext.lookup(ReadOnlyContext.java:235)
>>>         at javax.naming.InitialContext.lookup(InitialContext.java:411)
>>>         at
>>> org.apache.flume.source.jms.JMSSource.doConfigure(JMSSource.java:219)
>>>         ... 12 more
>>>
>>> I have verified that the ActiveMQ core jar is in the path.
>>>
>>> Any ideas or help appreciated.
>>>
>>> Richard.
>>>
>>>
>>>
>>
>

Mime
View raw message