You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@flink.apache.org by Pankaj Kumar <pa...@gmail.com> on 2016/02/24 11:31:38 UTC

downloading dependency in apache flink

i am trying to write a job, using maven project.

Job is working fine in my editor , but when i am running that job through
flink command line its giving ClassNotFoundException exception . Its not to
find dependency.

If i will create a jar , will flink download all its dependency before
executing that jar. if not that how can we run one-jar.


Thanks

Re: downloading dependency in apache flink

Posted by Pankaj Kumar <pa...@gmail.com>.
I was using wrong method to create fat jar,

after using  mvn clean install -Pbuild-jar i was able to execute code
through flink command line.

On Wed, Feb 24, 2016 at 7:12 PM, Till Rohrmann <tr...@apache.org> wrote:

> What is the error message you receive?
>
> On Wed, Feb 24, 2016 at 1:49 PM, Pankaj Kumar <pa...@gmail.com>
> wrote:
>
>> Hi Till ,
>>
>> I was able to make fat jar, but i am not able to execute this jar through
>> flink command line.
>>
>> On Wed, Feb 24, 2016 at 4:31 PM, Till Rohrmann <tr...@apache.org>
>> wrote:
>>
>>> Hi Pankaj,
>>>
>>> are you creating a fat jar when you create your use code jar? This can
>>> be done using maven's shade plugin or the assembly plugin. We provide a
>>> maven archetype to set up a pom file which will make sure that a fat jar is
>>> built [1].
>>>
>>> [1]
>>> https://ci.apache.org/projects/flink/flink-docs-master/quickstart/java_api_quickstart.html
>>>
>>> Cheers,
>>> Till
>>>
>>> On Wed, Feb 24, 2016 at 11:31 AM, Pankaj Kumar <pa...@gmail.com>
>>> wrote:
>>>
>>>> i am trying to write a job, using maven project.
>>>>
>>>> Job is working fine in my editor , but when i am running that job
>>>> through flink command line its giving ClassNotFoundException exception
>>>> . Its not to find dependency.
>>>>
>>>> If i will create a jar , will flink download all its dependency before
>>>> executing that jar. if not that how can we run one-jar.
>>>>
>>>>
>>>> Thanks
>>>>
>>>
>>>
>>
>

Re: downloading dependency in apache flink

Posted by Till Rohrmann <tr...@apache.org>.
What is the error message you receive?

On Wed, Feb 24, 2016 at 1:49 PM, Pankaj Kumar <pa...@gmail.com> wrote:

> Hi Till ,
>
> I was able to make fat jar, but i am not able to execute this jar through
> flink command line.
>
> On Wed, Feb 24, 2016 at 4:31 PM, Till Rohrmann <tr...@apache.org>
> wrote:
>
>> Hi Pankaj,
>>
>> are you creating a fat jar when you create your use code jar? This can be
>> done using maven's shade plugin or the assembly plugin. We provide a maven
>> archetype to set up a pom file which will make sure that a fat jar is built
>> [1].
>>
>> [1]
>> https://ci.apache.org/projects/flink/flink-docs-master/quickstart/java_api_quickstart.html
>>
>> Cheers,
>> Till
>>
>> On Wed, Feb 24, 2016 at 11:31 AM, Pankaj Kumar <pa...@gmail.com>
>> wrote:
>>
>>> i am trying to write a job, using maven project.
>>>
>>> Job is working fine in my editor , but when i am running that job
>>> through flink command line its giving ClassNotFoundException exception
>>> . Its not to find dependency.
>>>
>>> If i will create a jar , will flink download all its dependency before
>>> executing that jar. if not that how can we run one-jar.
>>>
>>>
>>> Thanks
>>>
>>
>>
>

Re: downloading dependency in apache flink

Posted by Pankaj Kumar <pa...@gmail.com>.
Hi Till ,

I was able to make fat jar, but i am not able to execute this jar through
flink command line.

On Wed, Feb 24, 2016 at 4:31 PM, Till Rohrmann <tr...@apache.org> wrote:

> Hi Pankaj,
>
> are you creating a fat jar when you create your use code jar? This can be
> done using maven's shade plugin or the assembly plugin. We provide a maven
> archetype to set up a pom file which will make sure that a fat jar is built
> [1].
>
> [1]
> https://ci.apache.org/projects/flink/flink-docs-master/quickstart/java_api_quickstart.html
>
> Cheers,
> Till
>
> On Wed, Feb 24, 2016 at 11:31 AM, Pankaj Kumar <pa...@gmail.com>
> wrote:
>
>> i am trying to write a job, using maven project.
>>
>> Job is working fine in my editor , but when i am running that job through
>> flink command line its giving ClassNotFoundException exception . Its not
>> to find dependency.
>>
>> If i will create a jar , will flink download all its dependency before
>> executing that jar. if not that how can we run one-jar.
>>
>>
>> Thanks
>>
>
>

Re: downloading dependency in apache flink

Posted by Till Rohrmann <tr...@apache.org>.
Hi Pankaj,

are you creating a fat jar when you create your use code jar? This can be
done using maven's shade plugin or the assembly plugin. We provide a maven
archetype to set up a pom file which will make sure that a fat jar is built
[1].

[1]
https://ci.apache.org/projects/flink/flink-docs-master/quickstart/java_api_quickstart.html

Cheers,
Till

On Wed, Feb 24, 2016 at 11:31 AM, Pankaj Kumar <pa...@gmail.com> wrote:

> i am trying to write a job, using maven project.
>
> Job is working fine in my editor , but when i am running that job through
> flink command line its giving ClassNotFoundException exception . Its not
> to find dependency.
>
> If i will create a jar , will flink download all its dependency before
> executing that jar. if not that how can we run one-jar.
>
>
> Thanks
>