Resolving dependency problems in Apache Spark

Apache Spark’s classpath is built dynamically (to accommodate per-application user code) which makes it vulnerable to such issues. @user7337271‘s answer is correct, but there are some more concerns, depending on the cluster manager (“master”) you’re using. First, a Spark application consists of these components (each one is a separate JVM, therefore potentially contains different classes … Read more

How to install JDBC driver in Eclipse web project without facing java.lang.ClassNotFoundexception

As for every “3rd-party” library in flavor of a JAR file which is to be used by the webapp, just copy/drop the physical JAR file in webapp’s /WEB-INF/lib. It will then be available in webapp’s default classpath. Also, Eclipse is smart enough to notice that. No need to hassle with buildpath. However, make sure to … Read more

What causes and what are the differences between NoClassDefFoundError and ClassNotFoundException?

The difference from the Java API Specifications is as follows. For ClassNotFoundException: Thrown when an application tries to load in a class through its string name using: The forName method in class Class. The findSystemClass method in class ClassLoader. The loadClass method in class ClassLoader. but no definition for the class with the specified name … Read more