title: Could not initialize class org.apache.axis.client.AxisClient thrown even though axis jar was there
body: <p>I am writing a plugin for nexus oss . where I am using axis for making webservice calls . It throws an</p>
  
  <p><strong>InvocationTargetException : target : java.lang.NoClassDefFoundError: Could not initialize class org.apache.axis.client.AxisClient</strong></p>
  
  <p>so i was apprehensive if nexus could not find my axis jar as it threw this NoClassDefFoundError. so I started debugging step by step  to check if nexus knows my axis jar and while debugging I found that the the control goes inside the axis jar (so my assumption that nexus did not see axis jar is wrong ). It went inside <a href="http://grepcode.com/file/repo1.maven.org/maven2/axis/axis/1.4/org/apache/axis/client/Service.java#103" rel="nofollow">Service.java</a> in axis and there the code was like </p>
  
  <pre><code>protected AxisClient getAxisClient() {
      return new AxisClient(getEngineConfiguration());
  }
  
  /**
   * Constructs a new Service object - this assumes the caller will set
   * the appropriate fields by hand rather than getting them from the
   * WSDL.
   */
  public Service() {
      engine = getAxisClient();
  }
  </code></pre>
  
  <p>It was throwing this exception at line engine = getAxisClient(); that is actually at line return new AxisClient(getEngineConfiguration()); inside getAxisClient method . 
  so if it can find service.java which is inside axis.jar , there cannot be any reason why it cannot find the AxisClient class which is in the same package in axis jar.</p>
  
  <p>So can you please help me in spotting out the reasons for this exception.</p>
  
  <p>Is my axis jar not fetched by nexus ? 
  How to find if the jar was fetched by nexus ?</p>