title: Why Jenkins cannot run a compiled jar file
body: <p>Inside Jenkins, I already setup a build.xml to use Ant to compile the Java code and output as a jar.
  I can run the compiled jar without problem in command line.
  However, after letting Jenkins to run the same jar file, I met an error "[exec] Error: Could not find or load main class".</p>
  
  <p>I checked the classpath in these two situations (in command-line vs. in Jenkins) and got identical results.</p>
  
  <p>This is so bizarre. My Jenkins is the latest long-term-support version and Java is 1.7.</p>