Taegost
0
Q:

> Task :run FAILED Error: Could not find or load main class Caused by: java.lang.ClassNotFoundException:

Sounds silly, but if you've copied .bashrc lines from somewhere
check that the quotation marks are like this:
    export HADOOP_OPTS="-Djava.library.path=$HADOOP_HOME/lib/native"
and not like this
    export HADOOP_OPTS=”-Djava.library.path=$HADOOP_HOME/lib/native”

...took me some time
0
Check your build.gradle file and update the application block:

application {
    // Define the main class for the application.
  	// insert the entire name of the class
    mainClassName = 'packageName.MainClass'
}
0
// Run configurations -> Run -> Run configurations
// In the Classpath tab select "Advanced"
// Add where Eclipse usually put the *.class for the projects, which is (usually) "bin". 
0

New to Communities?

Join the community