You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@storm.apache.org by Chen Wang <ch...@gmail.com> on 2014/01/17 09:01:39 UTC

ClassNotFound only in cluster mode

Hi, Guys,
I have copied all my external jars under storm/lib. I have two nodes in the
cluster, and I copied them to the storm lib folder of both of them.

Running the topology in local mode has no issue, however, it throws class
not found error when submitting to the cluster.

Is there something obvious that i am missing?
Thanks for help!
chen

Re: ClassNotFound only in cluster mode

Posted by Chen Wang <ch...@gmail.com>.
So to answer my own question..
yes i will need to restart the supervisor.
Chen


On Tue, Jan 21, 2014 at 12:36 PM, Chen Wang <ch...@gmail.com>wrote:

> It seems that if I drop the dependent jars into storm lib folder, I will
> have to restart the supervisor to make them take effect?
> Chen
>
>
> On Mon, Jan 20, 2014 at 10:55 AM, Chen Wang <ch...@gmail.com>wrote:
>
>> Make sense, Richards.
>> Thanks for the advice
>> Chen
>>
>>
>> On Fri, Jan 17, 2014 at 10:25 PM, Richards Peter <hb...@gmail.com>wrote:
>>
>>> Hi,
>>>
>>> I do the following in my project:
>>>
>>> 1. I maintain all the dependencies of the topology jar file, which is
>>> submitted to the cluster, in storm lib.
>>> 2. I maintain the topology jar outside storm directories.
>>> 3. I submit the topology by passing the path of the topology jar file.
>>>
>>> I used to face problems if the topology jar is maintained within storm
>>> lib. If you maintain topology jar within storm lib directory, I think you
>>> will have to restart the daemons every time you make changes to the
>>> topology jar file.
>>>
>>> Thanks,
>>> Richards Peter.
>>>
>>
>>
>

Re: ClassNotFound only in cluster mode

Posted by Chen Wang <ch...@gmail.com>.
It seems that if I drop the dependent jars into storm lib folder, I will
have to restart the supervisor to make them take effect?
Chen


On Mon, Jan 20, 2014 at 10:55 AM, Chen Wang <ch...@gmail.com>wrote:

> Make sense, Richards.
> Thanks for the advice
> Chen
>
>
> On Fri, Jan 17, 2014 at 10:25 PM, Richards Peter <hb...@gmail.com>wrote:
>
>> Hi,
>>
>> I do the following in my project:
>>
>> 1. I maintain all the dependencies of the topology jar file, which is
>> submitted to the cluster, in storm lib.
>> 2. I maintain the topology jar outside storm directories.
>> 3. I submit the topology by passing the path of the topology jar file.
>>
>> I used to face problems if the topology jar is maintained within storm
>> lib. If you maintain topology jar within storm lib directory, I think you
>> will have to restart the daemons every time you make changes to the
>> topology jar file.
>>
>> Thanks,
>> Richards Peter.
>>
>
>

Re: ClassNotFound only in cluster mode

Posted by Chen Wang <ch...@gmail.com>.
Make sense, Richards.
Thanks for the advice
Chen


On Fri, Jan 17, 2014 at 10:25 PM, Richards Peter <hb...@gmail.com>wrote:

> Hi,
>
> I do the following in my project:
>
> 1. I maintain all the dependencies of the topology jar file, which is
> submitted to the cluster, in storm lib.
> 2. I maintain the topology jar outside storm directories.
> 3. I submit the topology by passing the path of the topology jar file.
>
> I used to face problems if the topology jar is maintained within storm
> lib. If you maintain topology jar within storm lib directory, I think you
> will have to restart the daemons every time you make changes to the
> topology jar file.
>
> Thanks,
> Richards Peter.
>

Re: ClassNotFound only in cluster mode

Posted by Richards Peter <hb...@gmail.com>.
Hi,

I do the following in my project:

1. I maintain all the dependencies of the topology jar file, which is
submitted to the cluster, in storm lib.
2. I maintain the topology jar outside storm directories.
3. I submit the topology by passing the path of the topology jar file.

I used to face problems if the topology jar is maintained within storm lib.
If you maintain topology jar within storm lib directory, I think you will
have to restart the daemons every time you make changes to the topology jar
file.

Thanks,
Richards Peter.

Re: ClassNotFound only in cluster mode

Posted by Chen Wang <ch...@gmail.com>.
Able to answer my own question:
I put my jar under a separate folder, and ran from there.
so it looks like:
storm-0.8.2
myfolder

From
https://github.com/nathanmarz/storm/blob/8cd0c067a5f176e07d66c90c5c4fa3624c0199f6/bin/storm
it seems that storm loads its lib jars from current folder. Thus I move my
topology jar one up level:
stor-0.8.2
mytopology.jar

and run from there. The error is gone.

Thanks,
Chen


On Fri, Jan 17, 2014 at 12:01 AM, Chen Wang <ch...@gmail.com>wrote:

> Hi, Guys,
> I have copied all my external jars under storm/lib. I have two nodes in
> the cluster, and I copied them to the storm lib folder of both of them.
>
> Running the topology in local mode has no issue, however, it throws class
> not found error when submitting to the cluster.
>
> Is there something obvious that i am missing?
> Thanks for help!
> chen
>