How to make a monolithic jar.file?

后端 未结 5 1649
眼角桃花
眼角桃花 2021-01-17 06:29

I need to create a hadoop job jar file that uses mahout and a bunch of other libraries. I need ti be able to run the job without needing additional jar.files such that all r

5条回答
  •  一整个雨季
    2021-01-17 06:56

    Hadoop has the ability to read jars-in-jar. Amend you Ant script to include all the dependency jars in a folder called lib, and add this lib folder to your output Jar. This is sometimes a better choice if you have number of larger jars as it decreases your jar build time.

    See this article on a number of options you have when using 3rd party libs with hadoop

    • http://www.cloudera.com/blog/2011/01/how-to-include-third-party-libraries-in-your-map-reduce-job/

提交回复
热议问题