I am trying to create a bundled jar file for running using the hadoop ‘jar’ command. However, when I try to do this it fails to
find the jar files and other resources that I have placed into the jar (pointed at by the Class-Path property in the MANIFEST.MF).
I have unpacked the jar file into a temporary directory and run it manually using the java -jar command (after manually listing
the various hadoop jar files that are required in the classpath) and it works fine in this mode.
I have read on some places that the workaround is to put my jar files and other resources into the hadoop ‘lib’ directory, but
I really don’t want to do this, since it feels horribly kludgy. I don’t mind creating a ‘lib’ directory in my jar file, since this will be
hidden, but I would appreciate more documentation as to why/how I need to do this.
Can anybody advise as to how I can get 'hadoop jar’ to honour the Class-Path entry in the MANIFEST.MF?