Please explain the options in the compilation command.

javac -classpath ${HADOOP_HOME}/hadoop-${HADOOP_VERSION}-core.jar -d wordcount_classes 

(why they are needed) on ?

  • @ Kotik_hochet_kushat, the -d option, as I understand it, creates a folder for a class in, and why the -classpath option is used in this case, and why does the $ {HADOOP_HOME} / hadoop archive - $ {HADOOP_VERSION} -core.jar archive be specified? - ivan89
  • five
    @ ivan31, how can you work with frameworks without knowing how to work with java ??? Read at least java for dummies, I'm sure that it will even be described there, this is the FIRST about what they write in any book on java. - Viacheslav
  • @Viacheslav nea. In books for teapots in java they write about syntax and powerful OOP. Pro compiler on the strength of a couple of times mentioned. - zenith
  • Well, about -classpath in many textbooks they write. - skegg

1 answer 1

@ ivan31 you are not tired?

I tell in order what happens. It says something like this:

Take the Java compiler (javac), run it to compile the class and, allow external links using the ${HADOOP_HOME}/hadoop-${HADOOP_VERSION}-core.jar (it is assumed that the HADOOP_HOME and HADOOP_VERSION environment variables are defined. Compiled Object codes ( WordCount.class file) throw in the directory wordcount_classes

  • @Barmaley, what are external links? - ivan89 September
  • 2
    look at the source code on import org.apache.hadoop.* - these are external links. do not disgrace - take any java tutorial and read - Barmaley