title: Exception in sent of the initiat request (lifecycle) for instance of listener class (listener event) com.sun.faces.config.ConfigureListener
body: <p>Hi Please help I would like to create a Dynamic project Spring/JSF.
  I use the technology :</p>
  
  <ul>
  <li>JSF 2.2 (javax.faces-2.2.10.jar)</li>
  <li>Springframework 4.1.5</li>
  <li>Tomcat 7.0.59    </li>
  <li>Eclipse Luna</li>
  </ul>
  
  <p>I have this ERROR:</p>
  
  <pre><code>GRAVE: Une exception lors de l'envoi de requête a initié un évènement cycle de vie (lifecycle event) pour l'instance de classe à l'écoute (listener event) com.sun.faces.config.ConfigureListener
  java.lang.UnsupportedOperationException
      at javax.faces.context.FacesContext.getExceptionHandler(FacesContext.java:287)
      at javax.faces.event.ExceptionQueuedEventContext.getListenersForEventClass(ExceptionQueuedEventContext.java:262)
      at com.sun.faces.application.ApplicationImpl.invokeComponentListenersFor(ApplicationImpl.java:2107)
      at com.sun.faces.application.ApplicationImpl.publishEvent(ApplicationImpl.java:287)
      at com.sun.faces.application.ApplicationImpl.publishEvent(ApplicationImpl.java:245)
      at com.sun.faces.application.WebappLifecycleListener.requestDestroyed(WebappLifecycleListener.java:125)
      at com.sun.faces.config.ConfigureListener.requestDestroyed(ConfigureListener.java:375)
      at org.apache.catalina.core.StandardContext.fireRequestDestroyEvent(StandardContext.java:6223)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:215)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
      at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:950)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:421)
      at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1074)
      at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:611)
      at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:314)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
      at java.lang.Thread.run(Thread.java:745)
  </code></pre>
  
  <p>There is the codes :
  Web.xml</p>
  
  <pre><code>    &lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xmlns="http://java.sun.com/xml/ns/javaee"
      xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"
      id="WebApp_ID" version="3.0"&gt;
      &lt;display-name&gt;DemandeAch&lt;/display-name&gt;
      &lt;welcome-file-list&gt;
          &lt;welcome-file&gt;index.xhtml&lt;/welcome-file&gt;
      &lt;/welcome-file-list&gt;
  
      &lt;listener&gt;
          &lt;listener-class&gt;com.sun.faces.config.ConfigureListener&lt;/listener-class&gt;
      &lt;/listener&gt;
      &lt;context-param&gt;
          &lt;param-name&gt;javax.faces.FACELETS_REFRESH_PERIOD&lt;/param-name&gt;
          &lt;param-value&gt;0&lt;/param-value&gt;
      &lt;/context-param&gt;
      &lt;context-param&gt;
          &lt;param-name&gt;javax.faces.PROJECT_STAGE&lt;/param-name&gt;
          &lt;param-value&gt;Development&lt;/param-value&gt;
      &lt;/context-param&gt;
      &lt;context-param&gt;
          &lt;param-name&gt;javax.faces.FACELETS_SKIP_COMMENTS&lt;/param-name&gt;
          &lt;param-value&gt;true&lt;/param-value&gt;
      &lt;/context-param&gt;
  &lt;/web-app&gt;
  </code></pre>
  
  <p>SpringConfiguration.java/MyWebAppInitializer.java</p>
  
  <pre><code>@Configuration
  @ComponentScan
  public class SpringConfiguration {
  
  }
  
  public class MyWebAppInitializer implements WebApplicationInitializer {
  
  @Override
  public void onStartup(ServletContext container) throws ServletException {
      // create the 'root' Spring application context
      AnnotationConfigWebApplicationContext rootContext = new AnnotationConfigWebApplicationContext();
      rootContext.register(SpringConfiguration.class);
  
      // Manage lifecycle of the root application context
      container.addListener(new ContextLoaderListener(rootContext));
  
  }
  }
  </code></pre>
  
  <p>HelloSpringService.java</p>
  
  <pre><code>@Service
  public class HelloSpringService {
  public String sayHello(){
          return "Hello from Spring Service";
      }
  }
  </code></pre>
  
  <p>Controller</p>
  
  <pre><code>@ManagedBean
  public class HelloController {
  
      @ManagedProperty("#{helloSpringService}")
      private HelloSpringService helloSpringService;
      public String showHello(){
          return helloSpringService.sayHello();
      }
  }
  </code></pre>
  
  <p>index.xhtml</p>
  
  <pre><code>&lt;h:head&gt;&lt;/h:head&gt;
  &lt;h:body&gt;
      managed bean says :
      #{helloController.showHello()}
  &lt;/h:body&gt;
  </code></pre>
  
  <p>Please help :/
  Thanks a lot.</p>