title: How to resolve the warning message :" No configuration found."
body: <p>I want to make a test to get the value of Analyzer and Directory but the console shows the following warning message:</p>
  
  <pre><code>WARN - No configuration found. Configuring ehcache from ehcache-failsafe.xml  found in the classpath: jar:file:/C:/Program%20Files/Apache%20Software%20Foundation/Tomcat%206.0/webapps/shop1/WebRoot/WEB-INF/lib/ehcache-1.2.3.jar!/ehcache-failsafe.xml
  Analyzer:null
  configurationnull
  </code></pre>
  
  <p>My Spring configuration:</p>
  
  <pre><code>&lt;bean id="configuration" class="cn.cultivator.shop1.lucene.Configuration" init-method="init"&gt;
          &lt;property name="dirPath" value="C:/apache-tomcat-6.0.43/webapps/shop1/indexDir"&gt;&lt;/property&gt;
  &lt;/bean&gt;
  </code></pre>
  
  <p>The Configuration class:</p>
  
  <pre><code>public class Configuration {
  
  private Analyzer analyzer= null ;
  
  private Directory directory =null;
  
  public Analyzer getAnalyzer() {
      return analyzer;
  }
  
  public Directory getDirectory() {
      return directory;
  }
  
  private String dirPath = null;
  
  public void setDirPath(String dirPath) {
      this.dirPath = dirPath;
  }
  
  public void init(){
      try {
          analyzer = new IKAnalyzer(true);
          directory = FSDirectory.open(new File(dirPath));
      } catch (IOException e) {
          throw new RuntimeException(e);
      }
  }
  }
  </code></pre>
  
  <p>The test code is:</p>
  
  <pre><code>    @Test
  public void testConfiguratin() {
      System.out.println("Analyzer:"+configuration.getAnalyzer());
      System.out.println("configuration"+configuration.getDirectory());
  }
  </code></pre>
  
  <p>Why is the value null and how do I resolve the warning message?</p>