1 Reply Latest reply on Jun 24, 2009 7:55 AM by Kostya Piterskiy

    seam and spring...again

    Kostya Piterskiy Newbie

      Hi!
      I want use seam conversation.


          <bean id="userPageController" class="net.project.classes.Controllers.UserPageController" scope="prototype">
              <seam:component scope="CONVERSATION"/>
          </bean>


      it's work fine. But i don't understand how use @Begin and @End with spring bean.


      I try create class with annotation


       
      @Name("userPageController")
      @Scope(CONVERSATION)
      public class UserPageController
      


      but i have exception


      2009-06-24 00:37:27,859 ERROR [org.jboss.seam.jsf.SeamPhaseListener] - swallowing exception
      java.lang.RuntimeException: exception invoking: getTransaction



      my web.xml


          <!--===========================JBoss Seam================================================================-->
                      <listener>
                          <listener-class>org.jboss.seam.servlet.SeamListener</listener-class>
                      </listener>
      
                      <filter>
                          <filter-name>Seam Filter</filter-name>
                          <filter-class>org.jboss.seam.servlet.SeamFilter</filter-class>
                      </filter>
      
                      <filter-mapping>
                          <filter-name>Seam Filter</filter-name>
                          <url-pattern>/pages/*</url-pattern>
                      </filter-mapping>
      
                      <servlet>
                          <servlet-name>Seam Resource Servlet</servlet-name>
                          <servlet-class>org.jboss.seam.servlet.SeamResourceServlet</servlet-class>
                      </servlet>
      
                      <servlet-mapping>
                          <servlet-name>Seam Resource Servlet</servlet-name>
                          <url-pattern>/seam/resource/*</url-pattern>
                      </servlet-mapping>
      <filter>
              <filter-name>springSecurityFilterChain</filter-name>
              <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
          </filter>
      <!--========================Spring configuration===============================================-->
          <listener>
                <listener-class>org.springframework.web.context.request.RequestContextListener</listener-class>
           </listener>
      
          <filter-mapping>
              <filter-name>springSecurityFilterChain</filter-name>
              <url-pattern>/*</url-pattern>
              <servlet-name>Faces Servlet</servlet-name>
              <dispatcher>FORWARD</dispatcher>
              <dispatcher>REQUEST</dispatcher>
              <dispatcher>INCLUDE</dispatcher>
          </filter-mapping>
      


      application.xml


          <core:manager conversation-timeout="120000"
                        concurrent-request-timeout="500"
                        conversation-id-parameter="cid"/>
          <core:init debug="true"/>
          <spring:context-loader>
              <spring:config-locations>
                  <value>/WEB-INF/applicationContext.xml</value>
                  <value>/WEB-INF/applicationContext-security.xml</value>
              </spring:config-locations>
          </spring:context-loader>
      


      If i unclude


      <spring:spring-transaction platform-transaction-manager="#{transactionManager}"/>


      and use xml spring configuration exception is


      Caused by: java.lang.IllegalStateException: No conversation context active
      



      and with annotations


      java.lang.ClassNotFoundException: org.hibernate.search.Version
      



      Thanks!









      .