4 Replies Latest reply on Jun 9, 2010 4:18 AM by krikor paol

    Spring,Hibernate,Servicelocator,Richfaces JBOSS Integration error

    krikor paol Newbie

      BasedDAO.java

       

      package com.fp.common.model.dao;
      
      import javax.sql.DataSource;
      
      import org.springframework.orm.hibernate3.support.HibernateDaoSupport;
      
      public abstract class BaseDAO extends HibernateDaoSupport {
          protected DataSource dataSource;
      
          public void setDataSource(DataSource dataSource) {
              this.dataSource = dataSource;
          }
      }
      

       

       

       


      BaseBean.java

       

      package com.fp.common.view.bean;
      
      import javax.faces.context.FacesContext;
      
      import javax.servlet.http.HttpServletResponse;
      
      import com.fp.common.view.servicelocator.ServiceLocator;
      
      public class BaseBean {
          //the service locator of the business services
          protected ServiceLocator serviceLocator;
      
          public ServiceLocator getServiceLocator() {
              return this.serviceLocator;
          }
      
          public void setServiceLocator(ServiceLocator newServiceLocator) throws Exception {
              this.serviceLocator = newServiceLocator;
              this.init();
          }
      
          /**
           * Used to initialize the managed bean.
           * <p>
           * Called after the service locator is set.
           * It is a workaround.
           * <p>
           * Once the JSF bean management facility can support init method,
           * the init method can be configured and called from the JSF implementation directly.
           */
          protected void init() throws Exception {
              HttpServletResponse response = 
                  (HttpServletResponse)FacesContext.getCurrentInstance().getExternalContext().getResponse();
              ;
              response.setHeader("Cache-Control", "no-store");
              response.setHeader("Pragma\"", "no-cache"); 
              response.setDateHeader("Expires", 
                                     0); 
          }
      }
      

       


      servicelocator

       

      package com.fp.common.view.servicelocator;
      
      
      
      import com.fp.Event.model.service.EventsService;
      
      
      public interface ServiceLocator {
          public EventsService getEventsService();
      
      
      
      }
      

       

       

       


      servicelocatorbean

      package com.fp.common.view.servicelocator.impl;
      
      
      
      import javax.faces.context.FacesContext;
      
      import javax.servlet.ServletContext;
      
      import org.springframework.context.ApplicationContext;
      import org.springframework.web.context.support.WebApplicationContextUtils;
      
      
      import com.fp.common.view.servicelocator.ServiceLocator;
      
      
      import com.fp.Event.model.service.EventsService;
      
      
      
      public class ServiceLocatorBean implements ServiceLocator {
          private ApplicationContext appContext;
      
          public EventsService eventsService;
      
          public ServiceLocatorBean() throws Exception {
              ServletContext context = 
                  (ServletContext)FacesContext.getCurrentInstance().getExternalContext().getContext();
              appContext = 
                      WebApplicationContextUtils.getRequiredWebApplicationContext(context);
              
              appContext = 
                  WebApplicationContextUtils.getRequiredWebApplicationContext(context);
              eventsService = (EventsService)appContext.getBean("eventsService");
              
          }
      
         
          public EventsService getEventsService() {
              return eventsService;
          }
      
      
          public void setEventsService(EventsService eventsService) {
              this.eventsService = eventsService;
          }
      
         
      }
      

       


      EventBB

      package com.fp.Event.view.backing;
      
      import java.util.ArrayList;
      import java.util.List;
      
      import com.fp.Event.model.bo.Events;
      import com.fp.common.view.bean.BaseBean;
      
      public class EventBB  extends BaseBean {
           List<Events> Events = new ArrayList<Events>();
           
           public void init()
           {
               Events = this.serviceLocator.getEventsService().getEvents();
           }
      
              public void setEvents(List<Events> events) {
                  this.Events = events;
              }
              
              public List<Events> getEvents()
              {
                  return Events;
              }
      }
      

       


      eventsservice

       

      package com.fp.Event.model.service;
      
      import java.util.List;
      
      import com.fp.Event.model.bo.Events;
      
      public interface EventsService {
      
          public List<Events> getEvents();
      
      }
      

       

       

       

      evebtserviceimpl

      package com.fp.Event.model.service.impl;
      
      import java.util.List;
      
      import com.fp.Event.model.service.EventsService;
      import com.fp.Event.model.bo.Events;
      import com.fp.Event.model.dao.EventsDAO;
      
      public class EventsServiceIMPL implements EventsService {
      
          private EventsDAO eventsDao;
      
      
          public List<Events> getEvents() {
              return eventsDao.getEvents();
          }
          
      }
      

       

       

       

       

      eventsdao

       

      package com.fp.Event.model.dao;
      
      import java.util.List;
      
      import com.fp.Event.model.bo.Events;
      
      public interface EventsDAO {
          public List<Events> getEvents();
      }
      


      eventsdaohibernateimpl

       

      package com.fp.Event.model.dao.hibernate;
      
      import java.util.ArrayList;
      import java.util.List;
      
      import com.fp.Event.model.bo.Events;
      import com.fp.common.model.dao.BaseDAO;
      import com.fp.Event.model.dao.EventsDAO;
      
      public class EventsDAOHibernateIMPL extends BaseDAO implements EventsDAO {
            public List<Events> getEvents() {
               List<Events> eventList;
      
                  eventList = 
                          (ArrayList<Events>)getHibernateTemplate().find(" from Events where type_Code is null and deal_Id is null and global_Flag = 'Y'  and name is not null order by name  ");
      
                  return eventList;
          
            }
      }
      

       


      events.java

      package com.fp.Event.model.bo;
      
      import java.math.BigDecimal;
      import java.util.Date;
      
      
      public class Events {
              int id;
              String typeCode;
              String name;
              public int getId() {
                  return id;
              }
              public void setId(int id) {
                  this.id = id;
              }
              public String getTypeCode() {
                  return typeCode;
              }
              public void setTypeCode(String typeCode) {
                  this.typeCode = typeCode;
              }
              public String getName() {
                  return name;
              }
              public void setName(String name) {
                  this.name = name;
              }
      
      
          
      }
      

       

       

       

      Events.hbm.xml

       

      <?xml version="1.0"?>
      
      <!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN" "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
      
      <hibernate-mapping package="com.fp.events.model.bo" auto-import="true"
          default-lazy="false">
      
          <class name="Events" table="fpi_deal_events">
              <id name="id" column="deal_event_id">
                  <generator>
                  </generator>
              </id>
              <property name="typeCode" column="type_code" />
              <property name="name" column="name" />
      
          </class>
      </hibernate-mapping>
      

       

       

      web.xml

      <?xml version="1.0"?>
      
      <web-app version="2.5"
      
                      xmlns="http://java.sun.com/xml/ns/javaee"
      
                      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      
                      xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
      
      <display-name>Greeter</display-name>
      
      
      
      <context-param>
      
         <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
      
         <param-value>server</param-value>
      
      </context-param>
      
      
      
      <context-param>
      
         <param-name>org.richfaces.SKIN</param-name>
      
         <param-value>blueSky</param-value>
      
      </context-param>
      
      
      <context-param>
      
            <param-name>org.richfaces.CONTROL_SKINNING</param-name>
      
            <param-value>enable</param-value>
      
      </context-param>
      
      
      
      <filter>
      
         <display-name>RichFaces Filter</display-name>
      
         <filter-name>richfaces</filter-name>
      
         <filter-class>org.ajax4jsf.Filter</filter-class>
      
      </filter>
      
      
      <filter-mapping>
      
         <filter-name>richfaces</filter-name>
      
         <servlet-name>Faces Servlet</servlet-name>
      
         <dispatcher>REQUEST</dispatcher>
      
         <dispatcher>FORWARD</dispatcher>
      
         <dispatcher>INCLUDE</dispatcher>
      
      </filter-mapping>
      
      
      
      <listener>
      
         <listener-class>com.sun.faces.config.ConfigureListener</listener-class>
      
      </listener>
      
      
      
      
              
              
      <servlet>
      
         <servlet-name>Faces Servlet</servlet-name>
      
         <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
      
         <load-on-startup>1</load-on-startup>
      
      </servlet>
      
      
      
      <!-- Faces Servlet Mapping -->
      
      <servlet-mapping>
       
         <servlet-name>Faces Servlet</servlet-name>
      
         <url-pattern>*.jsf</url-pattern>
      
      </servlet-mapping>
      
      
      
      <login-config>
      
         <auth-method>BASIC</auth-method>
      
         </login-config>
      
      </web-app>
      
      


      faces-config.xml

       

      <?xml version="1.0"?>
      <!DOCTYPE faces-config PUBLIC "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.0//EN"
                                    "http://java.sun.com/dtd/web-facesconfig_1_0.dtd">
      <faces-config>
          <managed-bean>
              <description>
                  Service locator of the business services
              </description>
              <managed-bean-name>serviceLocatorBean</managed-bean-name>
              <managed-bean-class>
                  com.fp.common.view.servicelocator.impl.ServiceLocatorBean
              </managed-bean-class>
              <managed-bean-scope>session</managed-bean-scope>
          </managed-bean>
          <managed-bean>
              <managed-bean-name>events</managed-bean-name>
              <managed-bean-class>
                  com.fp.Event.view.backing.EventBB
              </managed-bean-class>
              <managed-bean-scope>session</managed-bean-scope>
              <managed-property>
                  <property-name>serviceLocator</property-name>
                  <value>#{serviceLocatorBean}</value>
              </managed-property>
          </managed-bean>
      
      
      </faces-config>
      

       


      daoContext.xml

       

      <?xml version="1.0" encoding="UTF-8"?>
      <!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd">
      
      <beans>
      
          <bean parent="BaseDAO" id="eventsDao"
              class="com.fp.Event.model.dao.hibernate.EventsDAOHibernateIMPL">
          </bean>
      
      
      
      </beans>
      

       

      serviceContext.xml

       

      <?xml version="1.0" encoding="UTF-8"?>
      <!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd">
      
      <beans>
      
          <bean singleton="true" id="eventsService"
              class="com.fp.Event.model.service.impl.EventsServiceIMPL">
              <property name="eventsDao">
                  <ref bean="eventsDao" />
              </property>
          </bean>
      
      
      </beans>
      

       

       


      jboss-web.xml

       

      <?xml version="1.0" encoding="UTF-8"?>
      
      <!DOCTYPE jboss-web PUBLIC
          "-//JBoss//DTD Web Application 2.4//EN"
          "http://www.jboss.org/j2ee/dtd/jboss-web_4_2.dtd">
      
      <jboss-web>
      
        <context-root>Hibernate</context-root>
      
      </jboss-web>
      

       

       


      There is also applicationcontext.xml

      <?xml version="1.0" encoding="UTF-8"?>

      <!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd">
      
      <beans>
          <!--JNDI based - Please make sure this is enabled when deploying-->
          <!--<bean id="dataSource">
              <property name="jndiName">
              <value>jdbc/DMDataSource</value>
              </property>
              </bean>-->
      
      
          <!-- OTDEV -->
          <bean id="dataSource"
              class="org.springframework.jdbc.datasource.DriverManagerDataSource">
              <property name="driverClassName">
                  <value>oracle.jdbc.driver.OracleDriver</value>
              </property>
              <property name="url">
                  <value>jdbc:oracle:thin:@jok.jok.com:1439:OT2</value>
              </property>
              <property name="username">
                  <value>USER</value>
              </property>
              <property name="password">
                  <value>password</value>
              </property>
          </bean>
      
      
          <bean id="sessionFactory"
              class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
              <property name="mappingDirectoryLocations">
                  <list>
                      <value>classpath:/com/fp/Events/model/bo</value>
                      
                  </list>
              </property>
      
              <property name="hibernateProperties">
                  <props>
                      <prop key="hibernate.dialect">
                          org.hibernate.dialect.OracleDialect
                      </prop>
                      <!--<prop key="hibernate.transaction.flush_before_completion">true</prop>-->
                      <!--<prop key="hibernate.transaction.auto_close_session">true</prop>-->
                      <!--<prop key="hibernate.connection.release_mode">after_transaction</prop>-->
                      <prop key="hibernate.show_sql">false</prop>
                      <prop
                          key="hibernate.bytecode.use_reflection_optimizer">
                          false
                      </prop>
                      <!--org.hibernate.cache.HashtableCacheProvider EhCacheProvider-->
                      <prop key="hibernate.jdbc.batch_versioned_data">
                          true
                      </prop>
                      <prop key="hibernate.generate_statistics">false</prop>
                      <prop key="hibernate.order_inserts">true</prop>
                      <prop key="hibernate.order_updates">true</prop>
                      <prop key="hibernate.cache.provider_class">
                          org.hibernate.cache.EhCacheProvider
                      </prop>
                      <prop key="hibernate.cache.use_second_level_cache">
                          false
                      </prop>
                      <prop key="hibernate.cache.use_query_cache">false</prop>
                      <prop key="hibernate.query.factory_class">
                          org.hibernate.hql.classic.ClassicQueryTranslatorFactory
                      </prop>
                      <prop key="hibernate.jdbc.batch_size">20</prop>
                      <prop key="hibernate.current_session_context_class">
                          thread
                      </prop>
                      <prop key="hibernate.transaction.factory_class">
                          org.hibernate.transaction.JDBCTransactionFactory
                      </prop>
                  </props>
              </property>
      
              <property name="dataSource">
                  <ref local="dataSource" />
              </property>
          </bean>
      
          <bean id="jdbcExceptionTranslator"
              class="org.springframework.jdbc.support.SQLErrorCodeSQLExceptionTranslator">
              <property name="dataSource">
                  <ref bean="dataSource" />
              </property>
          </bean>
      
          <bean id="hibernateTemplate"
              class="org.springframework.orm.hibernate3.HibernateTemplate">
              <property name="sessionFactory">
                  <ref bean="sessionFactory" />
              </property>
              <property name="jdbcExceptionTranslator">
                  <ref bean="jdbcExceptionTranslator" />
              </property>
          </bean>
      
      
          <bean id="baseTransactionProxy" abstract="true"
              class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean">
      
              <property name="transactionManager">
                  <bean id="transactionManager"
                      class="org.springframework.orm.hibernate3.HibernateTransactionManager">
                      <property name="sessionFactory">
                          <ref local="sessionFactory" />
                      </property>
                  </bean>
              </property>
      
              <property name="transactionAttributes">
                  <props>
                      <prop key="save*">PROPAGATION_REQUIRED,-Exception</prop>
                  </props>
              </property>
          </bean>
      
      
          <bean abstract="true" id="BaseDAO">
              <property name="dataSource">
                  <ref bean="dataSource" />
              </property>
              <property name="hibernateTemplate">
                  <ref bean="hibernateTemplate" />
              </property>
          </bean>
      
      </beans>
      

       

       

       

      Last but not least I run index.jsp

       

       

       

       

      Libraries I have used

      aspectjrt-1.6.8.jar
      sprin.oxm-3.0.2.jar
      spring.aop-3.0.2.jar
      spring.asm-3.0.2.jar
      spring.beans-3.0.2.jar
      spring.context.support-3.0.2.jar
      spring.core-3.0.2.jar
      spring.expression-3.0.2.jar
      spring.jdbc-3.0.2.jar
      spring.orm-3.0.2.jar
      spring.test-3.0.2.jar
      spring.transaction-3.0.2.jar
      spring.web.portlet-3.0.2.jar
      spring.web.servlet-3.0.2.jar
      spring.web.struts-3.0.2.jar
      spring.web-3.0.2.jar
      spring-security-acl-3.0.2.RELEASE.jar
      spring-security-config-3.0.2.RELEASE.jar
      spring-security-core-3.0.2.RELEASE.jar
      spring-security-taglibs-3.0.2.RELEASE.jar
      spring-security-web-3.0.2.RELEASE.jar
      aspectjweaver-1.6.8.jar
      commons-beanutils-1.8.0.jar
      commons-collections-3.2.jar
      commons-digester-2.0.jar
      commons-logging.jar
      hibernate3.jar
      hibernate-annotations.jar
      hibernate-commons-annotations.jar
      hibernate-entitymanager.jar
      hibernate-validator-4.0.2.GA.jar
      richfaces-api-3.3.1.GA.jar
      richfaces-impl-3.3.1.GA.jar
      richfaces-ui-3.3.1.GA.jar
      standard-1.1.2.jar

       

       

      Please help me with this error.

        • 1. Re: Spring,Hibernate,Servicelocator,Richfaces JBOSS Integration error
          krikor paol Newbie

          the full error

           

           

          10:41:50,886 ERROR [org.ajax4jsf.webapp.BaseXMLFilter] Exception in the filter chain: javax.servlet.ServletException: Unable to set property serviceLocator for managed bean events
              at javax.faces.webapp.FacesServlet.service(FacesServlet.java:325)
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:336)
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:242)
              at org.ajax4jsf.webapp.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:178)
              at org.ajax4jsf.webapp.BaseFilter.handleRequest(BaseFilter.java:290)
              at org.ajax4jsf.webapp.BaseFilter.processUploadsAndHandleRequest(BaseFilter.java:368)
              at org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:495)
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:274)
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:242)
              at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:276)
              at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
              at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:183)
              at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:95)
              at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
              at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
              at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
              at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
              at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
              at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
              at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:368)
              at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:872)
              at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:653)
              at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:951)
              at java.lang.Thread.run(Thread.java:619)
          Caused by: com.sun.faces.mgbean.ManagedBeanCreationException: Unable to set property serviceLocator for managed bean events
              at com.sun.faces.mgbean.ManagedBeanBuilder$BakedBeanProperty.set(ManagedBeanBuilder.java:615)
              at com.sun.faces.mgbean.ManagedBeanBuilder.buildBean(ManagedBeanBuilder.java:133)
              at com.sun.faces.mgbean.BeanBuilder.build(BeanBuilder.java:104)
              at com.sun.faces.mgbean.BeanManager.createAndPush(BeanManager.java:405)
              at com.sun.faces.mgbean.BeanManager.create(BeanManager.java:267)
              at com.sun.faces.el.ManagedBeanELResolver.getValue(ManagedBeanELResolver.java:86)
              at javax.el.CompositeELResolver.getValue(CompositeELResolver.java:175)
              at com.sun.faces.el.FacesCompositeELResolver.getValue(FacesCompositeELResolver.java:72)
              at org.apache.el.parser.AstIdentifier.getValue(AstIdentifier.java:67)
              at org.apache.el.parser.AstValue.getValue(AstValue.java:115)
              at org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:187)
              at org.apache.jasper.el.JspValueExpression.getValue(JspValueExpression.java:101)
              at javax.faces.component.ComponentStateHelper.eval(ComponentStateHelper.java:190)
              at javax.faces.component.ComponentStateHelper.eval(ComponentStateHelper.java:178)
              at javax.faces.component.UIData.getValue(UIData.java:554)
              at org.ajax4jsf.component.UIDataAdaptor.getValue(UIDataAdaptor.java:1624)
              at org.ajax4jsf.component.SequenceDataAdaptor.getDataModel(SequenceDataAdaptor.java:65)
              at org.ajax4jsf.component.SequenceDataAdaptor.createDataModel(SequenceDataAdaptor.java:59)
              at org.richfaces.component.UIDataTable.createDataModel(UIDataTable.java:120)
              at org.ajax4jsf.component.UIDataAdaptor.getExtendedDataModel(UIDataAdaptor.java:621)
              at org.ajax4jsf.component.UIDataAdaptor.setRowKey(UIDataAdaptor.java:339)
              at org.richfaces.renderkit.AbstractTableRenderer.encodeTableStructure(AbstractTableRenderer.java:138)
              at org.richfaces.renderkit.html.DataTableRenderer.doEncodeBegin(DataTableRenderer.java:160)
              at org.richfaces.renderkit.html.DataTableRenderer.doEncodeBegin(DataTableRenderer.java:148)
              at org.ajax4jsf.renderkit.RendererBase.encodeBegin(RendererBase.java:100)
              at javax.faces.component.UIComponentBase.encodeBegin(UIComponentBase.java:823)
              at javax.faces.component.UIData.encodeBegin(UIData.java:937)
              at org.ajax4jsf.component.UIDataAdaptor.encodeBegin(UIDataAdaptor.java:1202)
              at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1611)
              at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1616)
              at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1616)
              at com.sun.faces.application.view.JspViewHandlingStrategy.doRenderView(JspViewHandlingStrategy.java:420)
              at com.sun.faces.application.view.JspViewHandlingStrategy.renderView(JspViewHandlingStrategy.java:209)
              at com.sun.faces.application.view.MultiViewHandler.renderView(MultiViewHandler.java:126)
              at org.ajax4jsf.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:100)
              at org.ajax4jsf.application.AjaxViewHandler.renderView(AjaxViewHandler.java:176)
              at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:127)
              at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
              at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139)
              at javax.faces.webapp.FacesServlet.service(FacesServlet.java:313)
              ... 23 more
          Caused by: com.sun.faces.mgbean.ManagedBeanCreationException: Cant instantiate class: com.fp.common.view.servicelocator.impl.ServiceLocatorBean.
              at com.sun.faces.mgbean.BeanBuilder.newBeanInstance(BeanBuilder.java:193)
              at com.sun.faces.mgbean.BeanBuilder.build(BeanBuilder.java:102)
              at com.sun.faces.mgbean.BeanManager.createAndPush(BeanManager.java:405)
              at com.sun.faces.mgbean.BeanManager.create(BeanManager.java:267)
              at com.sun.faces.el.ManagedBeanELResolver.getValue(ManagedBeanELResolver.java:86)
              at javax.el.CompositeELResolver.getValue(CompositeELResolver.java:175)
              at com.sun.faces.el.FacesCompositeELResolver.getValue(FacesCompositeELResolver.java:72)
              at org.apache.el.parser.AstIdentifier.getValue(AstIdentifier.java:67)
              at org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:187)
              at com.sun.faces.mgbean.BeanBuilder$Expression.evaluate(BeanBuilder.java:591)
              at com.sun.faces.mgbean.ManagedBeanBuilder$BakedBeanProperty.set(ManagedBeanBuilder.java:606)
              ... 62 more
          Caused by: java.lang.IllegalStateException: No WebApplicationContext found: no ContextLoaderListener registered?
              at org.springframework.web.context.support.WebApplicationContextUtils.getRequiredWebApplicationContext(WebApplicationContextUtils.java:84)
              at com.fp.common.view.servicelocator.impl.ServiceLocatorBean.<init>(ServiceLocatorBean.java:31)
              at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
              at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
              at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
              at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
              at java.lang.Class.newInstance0(Class.java:355)
              at java.lang.Class.newInstance(Class.java:308)
              at com.sun.faces.mgbean.BeanBuilder.newBeanInstance(BeanBuilder.java:188)
              ... 72 more

           

          10:41:50,894 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/Hibernate].[Faces Servlet]] Servlet.service() for servlet Faces Servlet threw exception: java.lang.IllegalStateException: No WebApplicationContext found: no ContextLoaderListener registered?
              at org.springframework.web.context.support.WebApplicationContextUtils.getRequiredWebApplicationContext(WebApplicationContextUtils.java:84)
              at com.fp.common.view.servicelocator.impl.ServiceLocatorBean.<init>(ServiceLocatorBean.java:31)
              at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
              at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
              at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
              at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
              at java.lang.Class.newInstance0(Class.java:355)
              at java.lang.Class.newInstance(Class.java:308)
              at com.sun.faces.mgbean.BeanBuilder.newBeanInstance(BeanBuilder.java:188)
              at com.sun.faces.mgbean.BeanBuilder.build(BeanBuilder.java:102)
              at com.sun.faces.mgbean.BeanManager.createAndPush(BeanManager.java:405)
              at com.sun.faces.mgbean.BeanManager.create(BeanManager.java:267)
              at com.sun.faces.el.ManagedBeanELResolver.getValue(ManagedBeanELResolver.java:86)
              at javax.el.CompositeELResolver.getValue(CompositeELResolver.java:175)
              at com.sun.faces.el.FacesCompositeELResolver.getValue(FacesCompositeELResolver.java:72)
              at org.apache.el.parser.AstIdentifier.getValue(AstIdentifier.java:67)
              at org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:187)
              at com.sun.faces.mgbean.BeanBuilder$Expression.evaluate(BeanBuilder.java:591)
              at com.sun.faces.mgbean.ManagedBeanBuilder$BakedBeanProperty.set(ManagedBeanBuilder.java:606)
              at com.sun.faces.mgbean.ManagedBeanBuilder.buildBean(ManagedBeanBuilder.java:133)
              at com.sun.faces.mgbean.BeanBuilder.build(BeanBuilder.java:104)
              at com.sun.faces.mgbean.BeanManager.createAndPush(BeanManager.java:405)
              at com.sun.faces.mgbean.BeanManager.create(BeanManager.java:267)
              at com.sun.faces.el.ManagedBeanELResolver.getValue(ManagedBeanELResolver.java:86)
              at javax.el.CompositeELResolver.getValue(CompositeELResolver.java:175)
              at com.sun.faces.el.FacesCompositeELResolver.getValue(FacesCompositeELResolver.java:72)
              at org.apache.el.parser.AstIdentifier.getValue(AstIdentifier.java:67)
              at org.apache.el.parser.AstValue.getValue(AstValue.java:115)
              at org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:187)
              at org.apache.jasper.el.JspValueExpression.getValue(JspValueExpression.java:101)
              at javax.faces.component.ComponentStateHelper.eval(ComponentStateHelper.java:190)
              at javax.faces.component.ComponentStateHelper.eval(ComponentStateHelper.java:178)
              at javax.faces.component.UIData.getValue(UIData.java:554)
              at org.ajax4jsf.component.UIDataAdaptor.getValue(UIDataAdaptor.java:1624)
              at org.ajax4jsf.component.SequenceDataAdaptor.getDataModel(SequenceDataAdaptor.java:65)
              at org.ajax4jsf.component.SequenceDataAdaptor.createDataModel(SequenceDataAdaptor.java:59)
              at org.richfaces.component.UIDataTable.createDataModel(UIDataTable.java:120)
              at org.ajax4jsf.component.UIDataAdaptor.getExtendedDataModel(UIDataAdaptor.java:621)
              at org.ajax4jsf.component.UIDataAdaptor.setRowKey(UIDataAdaptor.java:339)
              at org.richfaces.renderkit.AbstractTableRenderer.encodeTableStructure(AbstractTableRenderer.java:138)
              at org.richfaces.renderkit.html.DataTableRenderer.doEncodeBegin(DataTableRenderer.java:160)
              at org.richfaces.renderkit.html.DataTableRenderer.doEncodeBegin(DataTableRenderer.java:148)
              at org.ajax4jsf.renderkit.RendererBase.encodeBegin(RendererBase.java:100)
              at javax.faces.component.UIComponentBase.encodeBegin(UIComponentBase.java:823)
              at javax.faces.component.UIData.encodeBegin(UIData.java:937)
              at org.ajax4jsf.component.UIDataAdaptor.encodeBegin(UIDataAdaptor.java:1202)
              at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1611)
              at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1616)
              at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1616)
              at com.sun.faces.application.view.JspViewHandlingStrategy.doRenderView(JspViewHandlingStrategy.java:420)
              at com.sun.faces.application.view.JspViewHandlingStrategy.renderView(JspViewHandlingStrategy.java:209)
              at com.sun.faces.application.view.MultiViewHandler.renderView(MultiViewHandler.java:126)
              at org.ajax4jsf.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:100)
              at org.ajax4jsf.application.AjaxViewHandler.renderView(AjaxViewHandler.java:176)
              at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:127)
              at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
              at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139)
              at javax.faces.webapp.FacesServlet.service(FacesServlet.java:313)
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:336)
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:242)
              at org.ajax4jsf.webapp.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:178)
              at org.ajax4jsf.webapp.BaseFilter.handleRequest(BaseFilter.java:290)
              at org.ajax4jsf.webapp.BaseFilter.processUploadsAndHandleRequest(BaseFilter.java:368)
              at org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:495)
              at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:274)
              at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:242)
              at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:276)
              at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
              at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:183)
              at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:95)
              at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
              at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
              at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
              at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
              at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
              at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
              at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:368)
              at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:872)
              at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:653)
              at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:951)
              at java.lang.Thread.run(Thread.java:619)

           

          10:42:00,972 INFO  [org.jboss.web.tomcat.service.deployers.TomcatDeployment] undeploy, ctxPath=/Hibernate
          10:42:47,744 INFO  [org.jboss.web.tomcat.service.deployers.TomcatDeployment] deploy, ctxPath=/Hibernate
          10:42:47,834 INFO  [org.apache.catalina.core.StandardContext] The listener "com.sun.faces.config.ConfigureListener" is already configured for this context. The duplicate definition has been ignored.
          10:42:47,855 INFO  [javax.enterprise.resource.webcontainer.jsf.config] Initializing Mojarra 2.0.2 (FCS b10) for context '/Hibernate'
          10:42:55,663 INFO  [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/Hibernate]] Initializing Spring root WebApplicationContext
          10:42:55,741 ERROR [org.springframework.web.context.ContextLoader] Context initialization failed: org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find class [org.springframework.orm.hibernate3.LocalSessionFactoryBean] for bean with name 'sessionFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]; nested exception is java.lang.ClassNotFoundException: org.springframework.orm.hibernate3.LocalSessionFactoryBean
              at org.springframework.beans.factory.support.AbstractBeanFactory.resolveBeanClass(AbstractBeanFactory.java:1208)
              at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.predictBeanType(AbstractAutowireCapableBeanFactory.java:570)
              at org.springframework.beans.factory.support.AbstractBeanFactory.isFactoryBean(AbstractBeanFactory.java:1277)
              at org.springframework.beans.factory.support.AbstractBeanFactory.isFactoryBean(AbstractBeanFactory.java:844)
              at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:544)
              at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:871)
              at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:423)
              at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:272)
              at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:196)
              at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:47)
              at org.apache.catalina.core.StandardContext.contextListenerStart(StandardContext.java:3926)
              at org.apache.catalina.core.StandardContext.start(StandardContext.java:4447)
              at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeployInternal(TomcatDeployment.java:315)
              at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeploy(TomcatDeployment.java:145)
              at org.jboss.web.deployers.AbstractWarDeployment.start(AbstractWarDeployment.java:462)
              at org.jboss.web.deployers.WebModule.startModule(WebModule.java:116)
              at org.jboss.web.deployers.WebModule.start(WebModule.java:95)
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
              at java.lang.reflect.Method.invoke(Method.java:597)
              at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:157)
              at org.jboss.mx.server.Invocation.dispatch(Invocation.java:96)
              at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
              at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:271)
              at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:670)
              at org.jboss.system.microcontainer.ServiceProxy.invoke(ServiceProxy.java:206)
              at $Proxy41.start(Unknown Source)
              at org.jboss.system.microcontainer.StartStopLifecycleAction.installAction(StartStopLifecycleAction.java:53)
              at org.jboss.system.microcontainer.StartStopLifecycleAction.installAction(StartStopLifecycleAction.java:41)
              at org.jboss.dependency.plugins.action.SimpleControllerContextAction.simpleInstallAction(SimpleControllerContextAction.java:62)
              at org.jboss.dependency.plugins.action.AccessControllerContextAction.install(AccessControllerContextAction.java:71)
              at org.jboss.dependency.plugins.AbstractControllerContextActions.install(AbstractControllerContextActions.java:51)
              at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:378)
              at org.jboss.system.microcontainer.ServiceControllerContext.install(ServiceControllerContext.java:301)
              at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:2029)
              at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:1050)
              at org.jboss.dependency.plugins.AbstractController.executeOrIncrementStateDirectly(AbstractController.java:1289)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1213)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1107)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:918)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:633)
              at org.jboss.system.ServiceController.doChange(ServiceController.java:671)
              at org.jboss.system.ServiceController.start(ServiceController.java:443)
              at org.jboss.system.deployers.ServiceDeployer.start(ServiceDeployer.java:189)
              at org.jboss.system.deployers.ServiceDeployer.deploy(ServiceDeployer.java:102)
              at org.jboss.system.deployers.ServiceDeployer.deploy(ServiceDeployer.java:49)
              at org.jboss.deployers.spi.deployer.helpers.AbstractSimpleRealDeployer.internalDeploy(AbstractSimpleRealDeployer.java:62)
              at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(AbstractRealDeployer.java:55)
              at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:179)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1660)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1378)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1399)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:1319)
              at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:378)
              at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:2029)
              at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:1050)
              at org.jboss.dependency.plugins.AbstractController.executeOrIncrementStateDirectly(AbstractController.java:1289)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1213)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1107)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:918)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:633)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:898)
              at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:677)
              at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.process(MainDeployerAdapter.java:117)
              at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:409)
              at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:294)
              at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
              at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
              at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
              at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
              at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:181)
              at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:205)
              at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
              at java.lang.Thread.run(Thread.java:619)
          Caused by: java.lang.ClassNotFoundException: org.springframework.orm.hibernate3.LocalSessionFactoryBean
              at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
              at java.security.AccessController.doPrivileged(Native Method)
              at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
              at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
              at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
              at org.springframework.util.ClassUtils.forName(ClassUtils.java:258)
              at org.springframework.beans.factory.support.AbstractBeanDefinition.resolveBeanClass(AbstractBeanDefinition.java:408)
              at org.springframework.beans.factory.support.AbstractBeanFactory.doResolveBeanClass(AbstractBeanFactory.java:1229)
              at org.springframework.beans.factory.support.AbstractBeanFactory.resolveBeanClass(AbstractBeanFactory.java:1200)
              ... 75 more

           

          10:42:55,746 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/Hibernate]] Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener: org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find class [org.springframework.orm.hibernate3.LocalSessionFactoryBean] for bean with name 'sessionFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]; nested exception is java.lang.ClassNotFoundException: org.springframework.orm.hibernate3.LocalSessionFactoryBean
              at org.springframework.beans.factory.support.AbstractBeanFactory.resolveBeanClass(AbstractBeanFactory.java:1208)
              at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.predictBeanType(AbstractAutowireCapableBeanFactory.java:570)
              at org.springframework.beans.factory.support.AbstractBeanFactory.isFactoryBean(AbstractBeanFactory.java:1277)
              at org.springframework.beans.factory.support.AbstractBeanFactory.isFactoryBean(AbstractBeanFactory.java:844)
              at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:544)
              at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:871)
              at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:423)
              at org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:272)
              at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:196)
              at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:47)
              at org.apache.catalina.core.StandardContext.contextListenerStart(StandardContext.java:3926)
              at org.apache.catalina.core.StandardContext.start(StandardContext.java:4447)
              at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeployInternal(TomcatDeployment.java:315)
              at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeploy(TomcatDeployment.java:145)
              at org.jboss.web.deployers.AbstractWarDeployment.start(AbstractWarDeployment.java:462)
              at org.jboss.web.deployers.WebModule.startModule(WebModule.java:116)
              at org.jboss.web.deployers.WebModule.start(WebModule.java:95)
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
              at java.lang.reflect.Method.invoke(Method.java:597)
              at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:157)
              at org.jboss.mx.server.Invocation.dispatch(Invocation.java:96)
              at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
              at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:271)
              at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:670)
              at org.jboss.system.microcontainer.ServiceProxy.invoke(ServiceProxy.java:206)
              at $Proxy41.start(Unknown Source)
              at org.jboss.system.microcontainer.StartStopLifecycleAction.installAction(StartStopLifecycleAction.java:53)
              at org.jboss.system.microcontainer.StartStopLifecycleAction.installAction(StartStopLifecycleAction.java:41)
              at org.jboss.dependency.plugins.action.SimpleControllerContextAction.simpleInstallAction(SimpleControllerContextAction.java:62)
              at org.jboss.dependency.plugins.action.AccessControllerContextAction.install(AccessControllerContextAction.java:71)
              at org.jboss.dependency.plugins.AbstractControllerContextActions.install(AbstractControllerContextActions.java:51)
              at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:378)
              at org.jboss.system.microcontainer.ServiceControllerContext.install(ServiceControllerContext.java:301)
              at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:2029)
              at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:1050)
              at org.jboss.dependency.plugins.AbstractController.executeOrIncrementStateDirectly(AbstractController.java:1289)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1213)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1107)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:918)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:633)
              at org.jboss.system.ServiceController.doChange(ServiceController.java:671)
              at org.jboss.system.ServiceController.start(ServiceController.java:443)
              at org.jboss.system.deployers.ServiceDeployer.start(ServiceDeployer.java:189)
              at org.jboss.system.deployers.ServiceDeployer.deploy(ServiceDeployer.java:102)
              at org.jboss.system.deployers.ServiceDeployer.deploy(ServiceDeployer.java:49)
              at org.jboss.deployers.spi.deployer.helpers.AbstractSimpleRealDeployer.internalDeploy(AbstractSimpleRealDeployer.java:62)
              at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(AbstractRealDeployer.java:55)
              at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:179)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1660)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1378)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1399)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:1319)
              at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:378)
              at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:2029)
              at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:1050)
              at org.jboss.dependency.plugins.AbstractController.executeOrIncrementStateDirectly(AbstractController.java:1289)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1213)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1107)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:918)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:633)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:898)
              at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:677)
              at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.process(MainDeployerAdapter.java:117)
              at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:409)
              at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:294)
              at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
              at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
              at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
              at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
              at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:181)
              at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:205)
              at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
              at java.lang.Thread.run(Thread.java:619)
          Caused by: java.lang.ClassNotFoundException: org.springframework.orm.hibernate3.LocalSessionFactoryBean
              at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
              at java.security.AccessController.doPrivileged(Native Method)
              at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
              at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
              at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
              at org.springframework.util.ClassUtils.forName(ClassUtils.java:258)
              at org.springframework.beans.factory.support.AbstractBeanDefinition.resolveBeanClass(AbstractBeanDefinition.java:408)
              at org.springframework.beans.factory.support.AbstractBeanFactory.doResolveBeanClass(AbstractBeanFactory.java:1229)
              at org.springframework.beans.factory.support.AbstractBeanFactory.resolveBeanClass(AbstractBeanFactory.java:1200)
              ... 75 more

           

          10:42:55,750 ERROR [org.apache.catalina.core.StandardContext] Error listenerStart
          10:42:55,751 ERROR [org.apache.catalina.core.StandardContext] Context [/Hibernate] startup failed due to previous errors
          10:42:55,751 INFO  [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/Hibernate]] Closing Spring root WebApplicationContext
          10:42:55,757 ERROR [org.jboss.kernel.plugins.dependency.AbstractKernelController] Error installing to Start: name=jboss.web.deployment:war=/Hibernate state=Create mode=Manual requiredState=Installed: org.jboss.deployers.spi.DeploymentException: URL file:/C:/jboss-6.0.0.20100216-M2/server/default/tmp/5c4o132-kusjko-ga8g3mjk-1-ga8g6qxz-9v/Hibernate.war/ deployment failed
              at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeployInternal(TomcatDeployment.java:337)
              at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeploy(TomcatDeployment.java:145)
              at org.jboss.web.deployers.AbstractWarDeployment.start(AbstractWarDeployment.java:462)
              at org.jboss.web.deployers.WebModule.startModule(WebModule.java:116)
              at org.jboss.web.deployers.WebModule.start(WebModule.java:95)
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
              at java.lang.reflect.Method.invoke(Method.java:597)
              at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:157)
              at org.jboss.mx.server.Invocation.dispatch(Invocation.java:96)
              at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
              at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:271)
              at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:670)
              at org.jboss.system.microcontainer.ServiceProxy.invoke(ServiceProxy.java:206)
              at $Proxy41.start(Unknown Source)
              at org.jboss.system.microcontainer.StartStopLifecycleAction.installAction(StartStopLifecycleAction.java:53)
              at org.jboss.system.microcontainer.StartStopLifecycleAction.installAction(StartStopLifecycleAction.java:41)
              at org.jboss.dependency.plugins.action.SimpleControllerContextAction.simpleInstallAction(SimpleControllerContextAction.java:62)
              at org.jboss.dependency.plugins.action.AccessControllerContextAction.install(AccessControllerContextAction.java:71)
              at org.jboss.dependency.plugins.AbstractControllerContextActions.install(AbstractControllerContextActions.java:51)
              at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:378)
              at org.jboss.system.microcontainer.ServiceControllerContext.install(ServiceControllerContext.java:301)
              at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:2029)
              at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:1050)
              at org.jboss.dependency.plugins.AbstractController.executeOrIncrementStateDirectly(AbstractController.java:1289)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1213)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1107)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:918)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:633)
              at org.jboss.system.ServiceController.doChange(ServiceController.java:671)
              at org.jboss.system.ServiceController.start(ServiceController.java:443)
              at org.jboss.system.deployers.ServiceDeployer.start(ServiceDeployer.java:189)
              at org.jboss.system.deployers.ServiceDeployer.deploy(ServiceDeployer.java:102)
              at org.jboss.system.deployers.ServiceDeployer.deploy(ServiceDeployer.java:49)
              at org.jboss.deployers.spi.deployer.helpers.AbstractSimpleRealDeployer.internalDeploy(AbstractSimpleRealDeployer.java:62)
              at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(AbstractRealDeployer.java:55)
              at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:179)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1660)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1378)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1399)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:1319)
              at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:378)
              at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:2029)
              at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:1050)
              at org.jboss.dependency.plugins.AbstractController.executeOrIncrementStateDirectly(AbstractController.java:1289)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1213)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1107)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:918)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:633)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:898)
              at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:677)
              at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.process(MainDeployerAdapter.java:117)
              at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:409)
              at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:294)
              at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
              at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
              at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
              at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
              at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:181)
              at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:205)
              at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
              at java.lang.Thread.run(Thread.java:619)

           

          10:42:55,767 ERROR [org.jboss.kernel.plugins.dependency.AbstractKernelController] Error installing to Real: name=vfszip:/C:/jboss-6.0.0.20100216-M2/server/default/deploy/Hibernate.war/ state=PreReal mode=Manual requiredState=Real: org.jboss.deployers.spi.DeploymentException: URL file:/C:/jboss-6.0.0.20100216-M2/server/default/tmp/5c4o132-kusjko-ga8g3mjk-1-ga8g6qxz-9v/Hibernate.war/ deployment failed
              at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeployInternal(TomcatDeployment.java:337)
              at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeploy(TomcatDeployment.java:145)
              at org.jboss.web.deployers.AbstractWarDeployment.start(AbstractWarDeployment.java:462)
              at org.jboss.web.deployers.WebModule.startModule(WebModule.java:116)
              at org.jboss.web.deployers.WebModule.start(WebModule.java:95)
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
              at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
              at java.lang.reflect.Method.invoke(Method.java:597)
              at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:157)
              at org.jboss.mx.server.Invocation.dispatch(Invocation.java:96)
              at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
              at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:271)
              at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:670)
              at org.jboss.system.microcontainer.ServiceProxy.invoke(ServiceProxy.java:206)
              at $Proxy41.start(Unknown Source)
              at org.jboss.system.microcontainer.StartStopLifecycleAction.installAction(StartStopLifecycleAction.java:53)
              at org.jboss.system.microcontainer.StartStopLifecycleAction.installAction(StartStopLifecycleAction.java:41)
              at org.jboss.dependency.plugins.action.SimpleControllerContextAction.simpleInstallAction(SimpleControllerContextAction.java:62)
              at org.jboss.dependency.plugins.action.AccessControllerContextAction.install(AccessControllerContextAction.java:71)
              at org.jboss.dependency.plugins.AbstractControllerContextActions.install(AbstractControllerContextActions.java:51)
              at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:378)
              at org.jboss.system.microcontainer.ServiceControllerContext.install(ServiceControllerContext.java:301)
              at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:2029)
              at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:1050)
              at org.jboss.dependency.plugins.AbstractController.executeOrIncrementStateDirectly(AbstractController.java:1289)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1213)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1107)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:918)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:633)
              at org.jboss.system.ServiceController.doChange(ServiceController.java:671)
              at org.jboss.system.ServiceController.start(ServiceController.java:443)
              at org.jboss.system.deployers.ServiceDeployer.start(ServiceDeployer.java:189)
              at org.jboss.system.deployers.ServiceDeployer.deploy(ServiceDeployer.java:102)
              at org.jboss.system.deployers.ServiceDeployer.deploy(ServiceDeployer.java:49)
              at org.jboss.deployers.spi.deployer.helpers.AbstractSimpleRealDeployer.internalDeploy(AbstractSimpleRealDeployer.java:62)
              at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(AbstractRealDeployer.java:55)
              at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:179)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1660)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1378)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1399)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:1319)
              at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:378)
              at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:2029)
              at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:1050)
              at org.jboss.dependency.plugins.AbstractController.executeOrIncrementStateDirectly(AbstractController.java:1289)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1213)
              at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1107)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:918)
              at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:633)
              at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:898)
              at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:677)
              at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.process(MainDeployerAdapter.java:117)
              at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:409)
              at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:294)
              at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
              at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
              at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
              at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
              at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:181)
              at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:205)
              at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
              at java.lang.Thread.run(Thread.java:619)

           

          • 2. Re: Spring,Hibernate,Servicelocator,Richfaces JBOSS Integration error
            krikor paol Newbie

            index.jsp in case u dont see

             

             

            <!doctype html public "-//w3c//dtd html 4.0 transitional//en">
            <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
            <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
            <!-- RichFaces tag library declaration -->
            <%@ taglib uri="http://richfaces.org/a4j" prefix="a4j"%>
            <%@ taglib uri="http://richfaces.org/rich" prefix="rich"%>



            <html>

                  <head>
                <style type="text/css">
                    .col1 { vertical-align:top; }
                    .col2 { vertical-align:top; width:450px; }
                    .wizard { width:400px; }
                    .wform td { vertical-align:top; }
                    .wfcol1 { text-align: right; white-space:nowrap;}
                    .wfcol2 { }
                    .wfcol3 { }
                    .s1row td { height:30px; }
                    .rich-message { color:red;  }
                   
                    .navPanel {
                        position:absolute;
                        bottom:0;
                        height:23px;
                        margin:0;
                        padding:2px;
                    }

                </style>
                        <title>RichFaces Greeter</title>

                  </head>

               

                        <f:view>
            <a4j:form>
            <rich:dataTable
                                onRowMouseOver="this.style.backgroundColor='#FF0000'"
                                onRowMouseOut="this.style.backgroundColor='#{a4jSkin.tableBackgroundColor}'"
                                cellpadding="0" cellspacing="0"
                                width="700" border="0" var="record" value="#{events.Events}">
                           
                                <f:facet name="header">
                                    <rich:columnGroup>
                                        <rich:column rowspan="2">
                                            <rich:spacer />
                                        </rich:column>
                                        <rich:column colspan="3">
                                            <h:outputText value="Name" />
                                        </rich:column>
                                    </rich:columnGroup>
                                </f:facet>
               
                                 <rich:column>
                                <h:outputText value="" /></rich:column>
                                <rich:column>
                                <h:outputText value="#{record.name}" /></rich:column>
                

                              
                
                   
                            </rich:dataTable>
            </a4j:form>
            </f:view>
            </html>

            • 3. Re: Spring,Hibernate,Servicelocator,Richfaces JBOSS Integration error
              krikor paol Newbie

              And sometimes I get this error

              ERROR [ContextLoader] Context initialization failed: org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find class [org.springframework.orm.hibernate3.LocalSessionFactoryBean] for bean with name 'sessionFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]; nested exception is java.lang.ClassNotFoundException: org.springframework.orm.hibernate3.LocalSessionFactoryBean

               

               

              Caused by: java.lang.ClassNotFoundException: org.springframework.orm.hibernate3.LocalSessionFactoryBean
                  at java.net.URLClassLoader$1.run(URLClassLoader.java:200)

               

              ERROR [[/Hibernate]] Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener: org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find class [org.springframework.orm.hibernate3.LocalSessionFactoryBean] for bean with name 'sessionFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]; nested exception is java.lang.ClassNotFoundException: org.springframework.orm.hibernate3.LocalSessionFactoryBean

              • 4. Re: Spring,Hibernate,Servicelocator,Richfaces JBOSS Integration error
                krikor paol Newbie

                And sometimes I get this error

                 

                ERROR [[/Hibernate]] Error configuring application listener of class org.springframework.web.context.ContextLoaderListener: java.lang.NoClassDefFoundError: org/springframework/context/ApplicationContextException

                 

                I am absolutely clueless