Announcement Announcement Module
Collapse
No announcement yet.
Error creating bean with name 'transactionManager' Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Error creating bean with name 'transactionManager'

    Getting this error -

    Code:
    16:11:45,521 ERROR main CommandLineJobRunner:211 - Job Terminated in error:
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'transactionManager' defined in class path resource [jobs/iosample/fixedLengthFileDbDump.xml]: Cannot resolve reference to bean 'entityManagerFactory' while setting bean property 'entityManagerFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in class path resource [jobs/iosample/fixedLengthFileDbDump.xml]: Invocation of init method failed; nested exception is org.hibernate.AnnotationException: java.lang.NoSuchMethodException: org.hibernate.validator.ClassValidator.<init>(java.lang.Class, java.util.ResourceBundle, org.hibernate.validator.MessageInterpolator, java.util.Map, org.hibernate.annotations.common.reflection.ReflectionManager)
    	at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:275)
    Here's my xml -
    Code:
    <?xml version="1.0" encoding="UTF-8"?>
    <beans:beans xmlns="http://www.springframework.org/schema/batch"
    	xmlns:beans="http://www.springframework.org/schema/beans"
    	xmlns:aop="http://www.springframework.org/schema/aop"
    	xmlns:tx="http://www.springframework.org/schema/tx"
    	xmlns:p="http://www.springframework.org/schema/p"
    	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    	xmlns:context="http://www.springframework.org/schema/context"
    	xsi:schemaLocation="
    		http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
    		http://www.springframework.org/schema/batch http://www.springframework.org/schema/batch/spring-batch-2.0.xsd
    		http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd
    		http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.0.xsd
    		http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd
    		http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-2.0.xsd">
    			
    	<job id="fixedLengthFileDbDumpJob">
    		<step id="step1">
    			<tasklet>
    				<chunk reader="itemReader" writer="itemWriter" commit-interval="2"/>
    			</tasklet>
    		</step>
    	</job>
    	
    	<beans:bean id="itemReader" class="org.springframework.batch.item.file.FlatFileItemReader">
    		<beans:property name="resource" value="data/iosample/input/Mn405d01.txt" />
    		<beans:property name="lineMapper">
    			<beans:bean class="org.springframework.batch.item.file.mapping.DefaultLineMapper">
    				<beans:property name="lineTokenizer">
    					<beans:bean
    						class="org.springframework.batch.item.file.transform.FixedLengthTokenizer">
    						<beans:property name="names" value="kshGuid,acctId,localStockNbr, stdUi, acqnCd, nomen, errcCd,sos" />
    						<beans:property name="columns" value="1-32,33-40,41-55,56-57,58-58,59-88,89-89,90-92" />
    					</beans:bean>
    				</beans:property>
    				<beans:property name="fieldSetMapper">
    					<beans:bean
    						class="org.springframework.batch.item.file.mapping.BeanWrapperFieldSetMapper">
    						<beans:property name="targetType"
    							value="org.springframework.batch.sample.domain.trade.CustomerCredit" />
    					</beans:bean>
    				</beans:property>
    			</beans:bean>
    		</beans:property>
    	</beans:bean>
    	
    	<tx:annotation-driven transaction-manager="transactionManager"/>
    	
    	<beans:bean class="org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor"/>
    	
    	<beans:bean id="itemWriter" class="org.springframework.batch.sample.domain.testdb.TestDAOImpl">
    		<beans:property name="entityManagerFactory" ref="entityManagerFactory"/>
    	</beans:bean>
    	
    	<!-- <bean id="itemWriter" class="org.springframework.batch.sample.domain.testdb.TestDAOImpl"/>-->
    	
    	<beans:bean id="transactionManager" class="org.springframework.orm.jpa.JpaTransactionManager">
    		<beans:property name="entityManagerFactory" ref="entityManagerFactory" />
    	</beans:bean>
    	
    	
    
    	<beans:bean id="entityManagerFactory"
    		class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean">
    		<beans:property name="dataSource" ref="dataSource" />
    		<beans:property name="persistenceUnitName" value="nimms" />
    		<beans:property name="jpaVendorAdapter">
    			<beans:bean class="org.springframework.orm.jpa.vendor.HibernateJpaVendorAdapter">
    				<beans:property name="showSql" value="true" />
               		<beans:property name="generateDdl" value="true" />
               		<beans:property name="databasePlatform" value="org.hibernate.dialect.Oracle10gDialect" />
    			</beans:bean>
    		</beans:property>
    	</beans:bean>
    
    	<!--
    		Hibernate JPA dialect does not support custom tx isolation levels =>
    		overwrite with ISOLATION_DEFAULT
    	-->
    	<beans:bean id="jobRepository"
    		class="org.springframework.batch.core.repository.support.JobRepositoryFactoryBean">
    		<beans:property name="isolationLevelForCreate" value="ISOLATION_DEFAULT" />
    		<beans:property name="dataSource" ref="dataSource" />
    		<beans:property name="transactionManager" ref="transactionManager" />
    	</beans:bean>
    	<context:annotation-config/>
    
    </beans:beans>
    Here's the code -

    Code:
    @Transactional
    public class TestDAOImpl implements TestDAO {
    	@Autowired
    	@PersistenceContext(unitName="nimms")
    	private EntityManager entityManager;
    	private EntityManagerFactory entityManagerFactory;
    	
    	public void setEntityManagerFactory(EntityManagerFactory entityManagerFactory) {
            this.entityManagerFactory = entityManagerFactory;
        }
    	
    	
    
    
    	//public void updateExpenseRecord(Mn405d01 mn405d01) {
    	public void updateExpenseRecord(CustomerCredit mn405d01) {
    		
    		System.out.println("TARIQ: Now doing em.merge");
    		entityManager.persist(mn405d01);
    		entityManager.flush();
    		
    	}
    
    	public void setEntityManager(EntityManager entityManager) {
    		this.entityManager = entityManager;
    	}
    
    	public EntityManager getEntityManager() {
    		return entityManager;
    	}
    Any idea?

  • #2
    Here's the persistence.xml -

    Code:
    <?xml version="1.0" encoding="UTF-8"?>   
    <persistence version="1.0" xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd">   
        <persistence-unit name="nimms">   
            <provider>org.hibernate.ejb.HibernatePersistence</provider>   
             <properties>   
               <property name="hibernate.dialect" value="org.hibernate.dialect.Oracle10gDialect"/>   
               <property name="connection.pool_size" value="1"/>   
               <property name="cache.provider_class" value="org.hibernate.cache.NoCacheProvider" />   
               <property name="hibernate.show_sql" value="false" />   
               <property name="hibernate.connection.url" value="jdbc:oracle:thin:@my.oracle.db:1521:mydb"/>
    		   <property name="hibernate.connection.driver_class" value="oracle.jdbc.OracleDriver"/>
    		   <property name="hibernate.connection.username" value="myid"/>
    		   <property name="hibernate.connection.password" value="XXXXXXX"/>
            </properties>
         </persistence-unit>   
    </persistence>

    Comment


    • #3
      @tariqahsan,

      Code:
      NoSuchMethodException: org.hibernate.validator.ClassValidator
      usually happens if you have two sets of hibernate jars (e.g. if you use JBoss, it has its own hibernate jars ( that you may remove ).

      Comment


      • #4
        Thanks for the response. Yes, also I found something similar in the Hibernate forum about duplicate jars

        Comment


        • #5
          Now I am getting this error -

          Code:
          13:19:29,691 ERROR main CommandLineJobRunner:211 - Job Terminated in error:
          org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'transactionManager' defined in class path resource [jobs/iosample/fixedLengthFileDbTest.xml]: Cannot resolve reference to bean 'entityManagerFactory' while setting bean property 'entityManagerFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in class path resource [jobs/iosample/fixedLengthFileDbTest.xml]: Invocation of init method failed; nested exception is javax.persistence.PersistenceException: [PersistenceUnit: nimms] Unable to build EntityManagerFactory
          	at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:275)
          Does it mean that it can't use the persistenceunitname - 'nimms' property from the entitymanagerfactory bean while trying to create the transactionmanager class bean?

          Comment


          • #6
            @tariqahsan,

            This looks like a top level exception saying that it cannot create a 'nimms' persistence unit. The real reason is probably hidden at the last "caused by" of this Exception. Can you post the full stack trace?

            Comment


            • #7
              Thanks litius for your response. The whole of it is pretty big. Here's a whole of lot of it from the end -
              Code:
              15:16:20,115  INFO main SettingsFactory:309 - Default entity-mode: pojo
              15:16:20,115  INFO main SettingsFactory:313 - Named query checking : enabled
              15:16:20,275  INFO main SessionFactoryImpl:161 - building session factory
              15:16:25,220  INFO main SessionFactoryObjectFactory:82 - Not binding factory to JNDI, no JNDI name configured
              15:16:25,260  INFO main DefaultListableBeanFactory:421 - Destroying singletons in org.s[email protected]1df280b: defining beans [dataSourceInitializer,dataSource,transactionManager,environment,overrideProperties,placeholderProperties,lobHandler,incrementerParent,customEditorConfigurer,jobLauncher,org.springframework.batch.core.configuration.support.JobRegistryBeanPostProcessor#0,jobRepository,jobOperator,jobExplorer,jobRegistry,jdbcTemplate,logAdvice,eventAdvice,org.springframework.batch.core.scope.internalStepScope,org.springframework.beans.factory.config.CustomEditorConfigurer,step1,fixedLengthFileDbTestJob,itemReader,org.springframework.aop.config.internalAutoProxyCreator,org.springframework.transaction.annotation.AnnotationTransactionAttributeSource#0,org.springframework.transaction.interceptor.TransactionInterceptor#0,org.springframework.transaction.config.internalTransactionAdvisor,org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor#0,itemWriter,entityManagerFactory,org.springframework.context.annotation.internalPersistenceAnnotationProcessor,org.springframework.context.annotation.internalCommonAnnotationProcessor,org.springframework.context.annotation.internalAutowiredAnnotationProcessor,org.springframework.context.annotation.internalRequiredAnnotationProcessor]; root of factory hierarchy
              15:16:25,260 ERROR main CommandLineJobRunner:211 - Job Terminated in error:
              org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'transactionManager' defined in class path resource [jobs/iosample/fixedLengthFileDbTest.xml]: Cannot resolve reference to bean 'entityManagerFactory' while setting bean property 'entityManagerFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in class path resource [jobs/iosample/fixedLengthFileDbTest.xml]: Invocation of init method failed; nested exception is javax.persistence.PersistenceException: [PersistenceUnit: nimms] Unable to build EntityManagerFactory
              	at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:275)
              	at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:104)
              	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1245)
              	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1010)
              	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:472)
              	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:409)
              	at java.security.AccessController.doPrivileged(Native Method)
              	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:380)
              	at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:264)
              	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
              	at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:261)
              	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:185)
              	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:164)
              	at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:429)
              	at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:728)
              	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:380)
              	at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:139)
              	at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:83)
              	at org.springframework.batch.core.launch.support.CommandLineJobRunner.start(CommandLineJobRunner.java:190)
              	at org.springframework.batch.core.launch.support.CommandLineJobRunner.main(CommandLineJobRunner.java:254)
              Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in class path resource [jobs/iosample/fixedLengthFileDbTest.xml]: Invocation of init method failed; nested exception is javax.persistence.PersistenceException: [PersistenceUnit: nimms] Unable to build EntityManagerFactory
              	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1338)
              	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:473)
              	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(AbstractAutowireCapableBeanFactory.java:409)
              	at java.security.AccessController.doPrivileged(Native Method)
              	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:380)
              	at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:264)
              	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
              	at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:261)
              	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:185)
              	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:164)
              	at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:269)
              	... 19 more
              Caused by: javax.persistence.PersistenceException: [PersistenceUnit: nimms] Unable to build EntityManagerFactory
              	at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:677)
              	at org.hibernate.ejb.HibernatePersistence.createContainerEntityManagerFactory(HibernatePersistence.java:132)
              	at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalContainerEntityManagerFactoryBean.java:224)
              	at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:291)
              	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1369)
              	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1335)
              	... 29 more
              Caused by: org.hibernate.HibernateException: The chosen transaction strategy requires access to the JTA TransactionManager
              	at org.hibernate.impl.SessionFactoryImpl.<init>(SessionFactoryImpl.java:329)
              	at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1300)
              	at org.hibernate.cfg.AnnotationConfiguration.buildSessionFactory(AnnotationConfiguration.java:859)
              	at org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:669)
              	... 34 more

              Comment


              • #8
                Litius,

                Wondering if you would have any similar sample I can take look? As you can see I am just trying to use EntityManager object to do a database transaction in the code. We are trying to use our entities packaged in a jar file included in the classpath from our existing JBoss Seam web project where the persistence.xml and ejb-jar.xml file also resides along with the entity classess. Other than that we are basically trying to use Spring Batch related jars.

                Thanks

                Comment


                • #9
                  I mentioned in my earlier posting that along with the entity classes we have the persistence.xml and ejb-jar.xml bundled up in a jar which is in the classpath. Here's the content of the persistence.xml in the jar -
                  Code:
                  <?xml version="1.0" encoding="UTF-8"?>
                  <persistence version="1.0" xmlns="http://java.sun.com/xml/ns/persistence"
                  		xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"	
                  		xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd">
                  		
                     <persistence-unit name="nimms" transaction-type="JTA">
                        <provider>org.hibernate.ejb.HibernatePersistence</provider>
                        <jta-data-source>java:/nimms-DS</jta-data-source>
                        <properties>
                           <property name="hibernate.cache.use_query_cache" value="true"/>
                           <property name="hibernate.show_sql" value="true"/>
                           <property name="jboss.entity.manager.jndi.name" value="java:/nimms"/>
                           <property name="jboss.entity.manager.factory.jndi.name" value="java:/nimmsFactory"/>  
                           <property name="hibernate.dialect" value="org.hibernate.dialect.Oracle9iDialect"/>
                        </properties>
                     </persistence-unit>
                  </persistence>

                  Is the error below could possibly for the above persistence.xml?
                  Code:
                  Caused by: org.hibernate.HibernateException: The chosen transaction strategy requires access to the JTA TransactionManager
                  	at org.hibernate.impl.SessionFactoryImpl.<init>(SessionFactoryImpl.java:329)

                  Comment


                  • #10
                    @tariqahsan,

                    Yeap, from the stack trace, Hibernate's SessionFactory is expecting JTA transaction manager, that is of course due to the fact that you configured it to expect it:

                    Code:
                       <persistence-unit name="nimms" transaction-type="JTA">
                          <provider>org.hibernate.ejb.HibernatePersistence</provider>
                          <jta-data-source>java:/nimms-DS</jta-data-source>
                          ... ... ...
                    However, from your configuration, you are using a JPA transaction manager:

                    Code:
                       <beans:bean id="transactionManager" class="org.springframework.orm.jpa.JpaTransactionManager">
                           <beans:property name="entityManagerFactory" ref="entityManagerFactory" />
                       </beans:bean>

                    Comment


                    • #11
                      @tariqahsan,

                      I would not use JTA transaction manager unless you absolutely need to (manage different transactional resources).

                      As to your persistence.xml, I don't think you need to specifically set the provider unless you are using several JPA providers.

                      Here is a quick example from Hibernate guys:

                      Code:
                      <persistence xmlns="http://java.sun.com/xml/ns/persistence"
                         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                         xsi:schemaLocation="http://java.sun.com/xml/ns/persistence
                          http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd"
                         version="1.0">
                      
                         <persistence-unit name="helloworld">
                      
                             <!-- The provider only needs to be set if you use several JPA providers
                             <provider>org.hibernate.ejb.HibernatePersistence</provider>
                              -->
                             <!-- This is required to be spec compliant, Hibernate however supports
                                  auto-detection even in JSE.
                             <class>hello.Message</class>
                              -->
                      
                            <properties>
                                <!-- Scan for annotated classes and Hibernate mapping XML files -->
                                <property name="hibernate.archive.autodetection" value="class, hbm"/>
                      
                                <!-- SQL stdout logging
                                <property name="hibernate.show_sql" value="true"/>
                                <property name="hibernate.format_sql" value="true"/>
                                <property name="use_sql_comments" value="true"/>
                                -->
                      
                                <property name="hibernate.connection.driver_class"
                                                  value="org.hsqldb.jdbcDriver"/>
                                <property name="hibernate.connection.url"
                                                  value="jdbc:hsqldb:hsql://localhost"/>
                                <property name="hibernate.connection.username"
                                                  value="sa"/>
                      
                                <property name="hibernate.c3p0.min_size"
                                                  value="5"/>
                                <property name="hibernate.c3p0.max_size"
                                                  value="20"/>
                                <property name="hibernate.c3p0.timeout"
                                                  value="300"/>
                                <property name="hibernate.c3p0.max_statements"
                                                  value="50"/>
                                <property name="hibernate.c3p0.idle_test_period"
                                                  value="3000"/>
                      
                                <property name="hibernate.dialect"
                                                  value="org.hibernate.dialect.HSQLDialect"/>
                      
                            </properties>
                         </persistence-unit>
                      
                      </persistence>
                      Here is a sample (and very simple) project you can look at: http://www.hibernate.org/hib_files/j...ted-070401.zip

                      Comment


                      • #12
                        I'm getting this error:

                        PHP Code:
                        Error creating bean with name 'transactionManager' defined in file [C:\Users\Tecnico1\Documents\workspace-sts-3.2.0.RELEASE\.metadata\.plugins\org.eclipse.wst.server.core\tmp1\wtpwebapps\marshall\WEB-INF\classes\META-INF\spring\applicationContext.xml]: Cannot resolve reference to bean 'entityManagerFactory' while setting bean property 'entityManagerFactory'nested exception is org.springframework.beans.factory.BeanCreationExceptionError creating bean with name 'entityManagerFactory' defined in file [C:\Users\Tecnico1\Documents\workspace-sts-3.2.0.RELEASE\.metadata\.plugins\org.eclipse.wst.server.core\tmp1\wtpwebapps\marshall\WEB-INF\classes\META-INF\spring\applicationContext.xml]: Invocation of init method failednested exception is org.hibernate.AnnotationException: @OneToOne or @ManyToOne on com.springsource.marshall.domain.DocumentoReservaHabitacion.reservaHabitacionId references an unknown entitycom.springsource.marshall.domain.ReservaHabitacion
                            at org
                        .springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:328)
                            
                        at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:106)
                            
                        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1360)
                            
                        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1118)
                        …………..
                            
                        at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4797)
                            
                        at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5291)
                            
                        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
                            
                        at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1559)
                        …………..

                        Caused byorg.springframework.beans.factory.BeanCreationExceptionError creating bean with name 'entityManagerFactory' defined in file [C:\Users\Tecnico1\Documents\workspace-sts-3.2.0.RELEASE\.metadata\.plugins\org.eclipse.wst.server.core\tmp1\wtpwebapps\marshall\WEB-INF\classes\META-INF\spring\applicationContext.xml]: Invocation of init method failednested exception is org.hibernate.AnnotationException: @OneToOne or @ManyToOne on com.springsource.marshall.domain.DocumentoReservaHabitacion.reservaHabitacionId references an unknown entitycom.springsource.marshall.domain.ReservaHabitacion
                            at org
                        .springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1455)
                            
                        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)
                            
                        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
                            
                        at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:294)
                            ... 
                        25 more
                        Caused by
                        org.hibernate.AnnotationException: @OneToOne or @ManyToOne on com.springsource.marshall.domain.DocumentoReservaHabitacion.reservaHabitacionId references an unknown entitycom.springsource.marshall.domain.ReservaHabitacion
                            at org
                        .hibernate.cfg.ToOneFkSecondPass.doSecondPass(ToOneFkSecondPass.java:107)
                            
                        at org.hibernate.cfg.Configuration.processEndOfQueue(Configuration.java:1580)
                            
                        at org.hibernate.cfg.Configuration.processFkSecondPassInOrder(Configuration.java:1503)
                            
                        at org.hibernate.cfg.Configuration.secondPassCompile(Configuration.java:1419)
                            
                        at org.hibernate.cfg.Configuration.buildMappings(Configuration.java:1375)
                            
                        at org.hibernate.ejb.Ejb3Configuration.buildMappings(Ejb3Configuration.java:1519)
                            
                        at org.hibernate.ejb.EventListenerConfigurator.configure(EventListenerConfigurator.java:193)
                            
                        at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:1100)
                            
                        at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:689)
                            
                        at org.hibernate.ejb.HibernatePersistence.createContainerEntityManagerFactory(HibernatePersistence.java:73)
                            ... 
                        32 more
                        02
                        -may-2013 9:36:54 org.apache.catalina.core.StandardContext listenerStart
                        GRAVE
                        Excepción enviando evento inicializado de contexto a instancia de escuchador de clase org.springframework.web.context.ContextLoaderListener
                        org
                        .springframework.beans.factory.BeanCreationExceptionError creating bean with name 'transactionManager' defined in file [C:\Users\Tecnico1\Documents\workspace-sts-3.2.0.RELEASE\.metadata\.plugins\org.eclipse.wst.server.core\tmp1\wtpwebapps\marshall\WEB-INF\classes\META-INF\spring\applicationContext.xml]: Cannot resolve reference to bean 'entityManagerFactory' while setting bean property 'entityManagerFactory'nested exception is org.springframework.beans.factory.BeanCreationExceptionError creating bean with name 'entityManagerFactory' defined in file [C:\Users\Tecnico1\Documents\workspace-sts-3.2.0.RELEASE\.metadata\.plugins\org.eclipse.wst.server.core\tmp1\wtpwebapps\marshall\WEB-INF\classes\META-INF\spring\applicationContext.xml]: Invocation of init method failednested exception is org.hibernate.AnnotationException: @OneToOne or @ManyToOne on com.springsource.marshall.domain.DocumentoReservaHabitacion.reservaHabitacionId references an unknown entitycom.springsource.marshall.domain.ReservaHabitacion
                            at org
                        .springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:328)
                            
                        at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:106)
                            
                        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1360)
                            
                        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1118)
                            
                        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:517)
                            
                        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
                        …………..
                            
                        at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4797)
                            
                        at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5291)
                            
                        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
                            
                        at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1559)
                            
                        at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1549)
                            
                        at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
                            
                        at java.util.concurrent.FutureTask.run(FutureTask.java:138)
                            
                        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:662)
                        Caused byorg.springframework.beans.factory.BeanCreationExceptionError creating bean with name 'entityManagerFactory' defined in file [C:\Users\Tecnico1\Documents\workspace-sts-3.2.0.RELEASE\.metadata\.plugins\org.eclipse.wst.server.core\tmp1\wtpwebapps\marshall\WEB-INF\classes\META-INF\spring\applicationContext.xml]: Invocation of init method failednested exception is org.hibernate.AnnotationException: @OneToOne or @ManyToOne on com.springsource.marshall.domain.DocumentoReservaHabitacion.reservaHabitacionId references an unknown entitycom.springsource.marshall.domain.ReservaHabitacion
                            at org
                        .springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1455)
                            
                        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)
                            
                        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
                            
                        at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:294)
                            
                        at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:225)
                            ... 
                        25 more
                        Caused by
                        org.hibernate.AnnotationException: @OneToOne or @ManyToOne on com.springsource.marshall.domain.DocumentoReservaHabitacion.reservaHabitacionId references an unknown entitycom.springsource.marshall.domain.ReservaHabitacion
                            at org
                        .hibernate.cfg.ToOneFkSecondPass.doSecondPass(ToOneFkSecondPass.java:107)
                            
                        at org.hibernate.cfg.Configuration.processEndOfQueue(Configuration.java:1580)
                            
                        at org.hibernate.cfg.Configuration.processFkSecondPassInOrder(Configuration.java:1503)
                            
                        at org.hibernate.cfg.Configuration.secondPassCompile(Configuration.java:1419)
                            
                        at org.hibernate.cfg.Configuration.buildMappings(Configuration.java:1375)
                            
                        at org.hibernate.ejb.Ejb3Configuration.buildMappings(Ejb3Configuration.java:1519)
                            
                        at org.hibernate.ejb.EventListenerConfigurator.configure(EventListenerConfigurator.java:193)
                            
                        at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:1100)
                            
                        at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:689)
                            
                        at org.hibernate.ejb.HibernatePersistence.createContainerEntityManagerFactory(HibernatePersistence.java:73)
                            
                        at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalContainerEntityManagerFactoryBean.java:268)
                            ... 
                        32 more 

                        I'm a begginer and I don't find the mistake... Maybe I have duplicate jars... In that case... what jar I have to remove??


                        Thanks!!
                        Last edited by Carol22; May 2nd, 2013, 05:21 AM.

                        Comment


                        • #13
                          Here is my applicationContext.xml
                          PHP Code:
                          <?xml version="1.0" encoding="UTF-8" standalone="no"?>
                          <beans xmlns="http://www.springframework.org/schema/beans" xmlns:aop="http://www.springframework.org/schema/aop" xmlns:context="http://www.springframework.org/schema/context" xmlns:jee="http://www.springframework.org/schema/jee" xmlns:tx="http://www.springframework.org/schema/tx" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/aop [url]http://www.springframework.org/schema/aop/spring-aop-3.1.xsd[/url]         [url]http://www.springframework.org/schema/beans[/url] [url]http://www.springframework.org/schema/beans/spring-beans-3.1.xsd[/url]         [url]http://www.springframework.org/schema/context[/url] [url]http://www.springframework.org/schema/context/spring-context-3.1.xsd[/url]         [url]http://www.springframework.org/schema/jee[/url] [url]http://www.springframework.org/schema/jee/spring-jee-3.1.xsd[/url]         [url]http://www.springframework.org/schema/tx[/url] http://www.springframework.org/schema/tx/spring-tx-3.1.xsd">
                              <context:property-placeholder location="classpath*:META-INF/spring/*.properties"/>
                              <context:spring-configured/>
                              <context:component-scan base-package="com.springsource.marshall">
                                  <context:exclude-filter expression=".*_Roo_.*" type="regex"/>
                                  <context:exclude-filter expression="org.springframework.stereotype.Controller" type="annotation"/>
                              </context:component-scan>
                              <bean class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close" id="dataSource">
                                  <property name="driverClassName" value="${database.driverClassName}"/>
                                  <property name="url" value="${database.url}"/>
                                  <property name="username" value="${database.username}"/>
                                  <property name="password" value="${database.password}"/>
                                  <property name="testOnBorrow" value="true"/>
                                  <property name="testOnReturn" value="true"/>
                                  <property name="testWhileIdle" value="true"/>
                                  <property name="timeBetweenEvictionRunsMillis" value="1800000"/>
                                  <property name="numTestsPerEvictionRun" value="3"/>
                                  <property name="minEvictableIdleTimeMillis" value="1800000"/>
                                  <property name="validationQuery" value="SELECT 1"/>
                              </bean>
                              <bean class="org.springframework.orm.jpa.JpaTransactionManager" id="transactionManager">
                                  <property name="entityManagerFactory" ref="entityManagerFactory"/>
                              </bean>
                              <tx:annotation-driven mode="aspectj" transaction-manager="transactionManager"/>
                              <bean class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean" id="entityManagerFactory">
                                  <property name="persistenceUnitName" value="persistenceUnit"/>
                                  <property name="dataSource" ref="dataSource"/>
                              </bean>
                          </beans>

                          Here is my applicationContext-security.xml
                          PHP Code:
                          <?xml version="1.0" encoding="UTF-8"?>
                          <beans:beans xmlns="http://www.springframework.org/schema/security" 
                              xmlns:beans="http://www.springframework.org/schema/beans" 
                              xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
                              xsi:schemaLocation="http://www.springframework.org/schema/beans [url]http://www.springframework.org/schema/beans/spring-beans-3.1.xsd[/url]
                                  [url]http://www.springframework.org/schema/security[/url] http://www.springframework.org/schema/security/spring-security-3.1.xsd">
                              <!-- HTTP security configurations -->
                              <http auto-config="true" use-expressions="true">
                                  <form-login login-processing-url="/resources/j_spring_security_check" login-page="/login" authentication-failure-url="/login?login_error=t" />
                                  <logout logout-url="/resources/j_spring_security_logout" />
                                  <!-- Configure these elements to secure URIs in your application -->
                                  <intercept-url pattern="/choices/**" access="hasRole('ROLE_ADMIN')" />
                                  <intercept-url pattern="/member/**" access="isAuthenticated()" />
                                  <intercept-url pattern="/resources/**" access="permitAll" />
                                  <intercept-url pattern="/**" access="permitAll" />
                              </http>
                              <!-- Configure Authentication mechanism -->
                              <authentication-manager alias="authenticationManager">
                                  <!-- SHA-256 values can be produced using 'echo -n your_desired_password | sha256sum' (using normal *nix environments) -->
                                  <authentication-provider>
                                      <password-encoder hash="sha-256" />
                                      <user-service>
                                          <user name="admin" password="8c6976e5b5410415bde908bd4dee15dfb167a9c873fc4bb8a81f6f2ab448a918" authorities="ROLE_ADMIN" />
                                          <user name="user" password="04f8996da763b7a969b1028ee3007569eaf3a635486ddab211d512c85b9df8fb" authorities="ROLE_USER" />
                                      </user-service>
                                  </authentication-provider>
                              </authentication-manager>
                          </beans:beans>
                          Last edited by Carol22; May 2nd, 2013, 05:20 AM.

                          Comment


                          • #14
                            And here is my POM (part 1):
                            PHP Code:
                            <?xml version="1.0" encoding="UTF-8" standalone="no"?>
                            <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
                                <modelVersion>4.0.0</modelVersion>
                                <groupId>com.springsource.marshall</groupId>
                                <artifactId>marshall</artifactId>
                                <packaging>war</packaging>
                                <version>0.1.0.BUILD-SNAPSHOT</version>
                                <name>marshall</name>
                                <properties>
                                    <aspectj.version>1.7.0.RC1</aspectj.version>
                                    <java.version>6</java.version>
                                    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
                                    <roo.version>1.2.2.RELEASE</roo.version>
                                    <slf4j.version>1.6.4</slf4j.version>
                                    <spring.version>3.1.1.RELEASE</spring.version>
                                <spring-security.version>3.1.0.RELEASE</spring-security.version>
                                </properties>
                                <repositories>
                                    <repository>
                                        <id>spring-maven-release</id>
                                        <name>Spring Maven Release Repository</name>
                                        <url>http://maven.springframework.org/release</url>
                                    </repository>
                                    <repository>
                                        <id>spring-maven-milestone</id>
                                        <name>Spring Maven Milestone Repository</name>
                                        <url>http://maven.springframework.org/milestone</url>
                                    </repository>
                                    <repository>
                                        <id>spring-roo-repository</id>
                                        <name>Spring Roo Repository</name>
                                        <url>http://spring-roo-repository.springsource.org/release</url>
                                    </repository>
                                </repositories>
                                <pluginRepositories>
                                    <pluginRepository>
                                        <id>spring-maven-release</id>
                                        <name>Spring Maven Release Repository</name>
                                        <url>http://maven.springframework.org/release</url>
                                    </pluginRepository>
                                    <pluginRepository>
                                        <id>spring-maven-milestone</id>
                                        <name>Spring Maven Milestone Repository</name>
                                        <url>http://maven.springframework.org/milestone</url>
                                    </pluginRepository>
                                    <pluginRepository>
                                        <id>spring-roo-repository</id>
                                        <name>Spring Roo Repository</name>
                                        <url>http://spring-roo-repository.springsource.org/release</url>
                                    </pluginRepository>
                                </pluginRepositories>
                                <dependencies>
                                    <!-- General dependencies for standard applications -->
                                    <dependency>
                                        <groupId>junit</groupId>
                                        <artifactId>junit</artifactId>
                                        <version>4.10</version>
                                        <scope>test</scope>
                                    </dependency>
                                    <dependency>
                                        <groupId>log4j</groupId>
                                        <artifactId>log4j</artifactId>
                                        <version>1.2.16</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.slf4j</groupId>
                                        <artifactId>slf4j-api</artifactId>
                                        <version>${slf4j.version}</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.slf4j</groupId>
                                        <artifactId>jcl-over-slf4j</artifactId>
                                        <version>${slf4j.version}</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.slf4j</groupId>
                                        <artifactId>slf4j-log4j12</artifactId>
                                        <version>${slf4j.version}</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.aspectj</groupId>
                                        <artifactId>aspectjrt</artifactId>
                                        <version>${aspectj.version}</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.aspectj</groupId>
                                        <artifactId>aspectjweaver</artifactId>
                                        <version>${aspectj.version}</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>javax.servlet</groupId>
                                        <artifactId>servlet-api</artifactId>
                                        <version>2.5</version>
                                        <scope>provided</scope>
                                    </dependency>
                                    <dependency>
                                        <groupId>net.sf.flexjson</groupId>
                                        <artifactId>flexjson</artifactId>
                                        <version>2.1</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.apache.commons</groupId>
                                        <artifactId>commons-lang3</artifactId>
                                        <version>3.1</version>
                                    </dependency>
                                    <!-- ROO dependencies -->
                                    <dependency>
                                        <groupId>org.springframework.roo</groupId>
                                        <artifactId>org.springframework.roo.annotations</artifactId>
                                        <version>${roo.version}</version>
                                        <scope>provided</scope>
                                    </dependency>
                                    <!-- Spring dependencies -->
                                    <dependency>
                                        <groupId>org.springframework</groupId>
                                        <artifactId>spring-core</artifactId>
                                        <version>${spring.version}</version>
                                        <exclusions>
                                            <exclusion>
                                                <groupId>commons-logging</groupId>
                                                <artifactId>commons-logging</artifactId>
                                            </exclusion>
                                        </exclusions>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.springframework</groupId>
                                        <artifactId>spring-test</artifactId>
                                        <version>${spring.version}</version>
                                        <scope>test</scope>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.springframework</groupId>
                                        <artifactId>spring-context</artifactId>
                                        <version>${spring.version}</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.springframework</groupId>
                                        <artifactId>spring-aop</artifactId>
                                        <version>${spring.version}</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.springframework</groupId>
                                        <artifactId>spring-aspects</artifactId>
                                        <version>${spring.version}</version>
                                    </dependency>
                                <dependency>
                                        <groupId>mysql</groupId>
                                        <artifactId>mysql-connector-java</artifactId>
                                        <version>5.1.18</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.hibernate</groupId>
                                        <artifactId>hibernate-core</artifactId>
                                        <version>3.6.9.Final</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.hibernate</groupId>
                                        <artifactId>hibernate-entitymanager</artifactId>
                                        <version>3.6.9.Final</version>
                                        <exclusions>
                                            <exclusion>
                                                <groupId>cglib</groupId>
                                                <artifactId>cglib</artifactId>
                                            </exclusion>
                                            <exclusion>
                                                <groupId>dom4j</groupId>
                                                <artifactId>dom4j</artifactId>
                                            </exclusion>
                                        </exclusions>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.hibernate.javax.persistence</groupId>
                                        <artifactId>hibernate-jpa-2.0-api</artifactId>
                                        <version>1.0.1.Final</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>commons-collections</groupId>
                                        <artifactId>commons-collections</artifactId>
                                        <version>3.2.1</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.hibernate</groupId>
                                        <artifactId>hibernate-validator</artifactId>
                                        <version>4.2.0.Final</version>
                                        <exclusions>
                                            <exclusion>
                                                <groupId>javax.xml.bind</groupId>
                                                <artifactId>jaxb-api</artifactId>
                                            </exclusion>
                                            <exclusion>
                                                <groupId>com.sun.xml.bind</groupId>
                                                <artifactId>jaxb-impl</artifactId>
                                            </exclusion>
                                        </exclusions>
                                    </dependency>
                                    <dependency>
                                        <groupId>javax.validation</groupId>
                                        <artifactId>validation-api</artifactId>
                                        <version>1.0.0.GA</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>cglib</groupId>
                                        <artifactId>cglib-nodep</artifactId>
                                        <version>2.2.2</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>javax.transaction</groupId>
                                        <artifactId>jta</artifactId>
                                        <version>1.1</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.springframework</groupId>
                                        <artifactId>spring-jdbc</artifactId>
                                        <version>${spring.version}</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>org.springframework</groupId>
                                        <artifactId>spring-orm</artifactId>
                                        <version>${spring.version}</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>commons-pool</groupId>
                                        <artifactId>commons-pool</artifactId>
                                        <version>1.5.6</version>
                                    </dependency>
                                    <dependency>
                                        <groupId>commons-dbcp</groupId>
                                        <artifactId>commons-dbcp</artifactId>
                                        <version>1.3</version>
                                        <exclusions>
                                            <exclusion>
                                                <groupId>commons-logging</groupId>
                                                <artifactId>commons-logging</artifactId>
                                            </exclusion>
                                            <exclusion>
                                                <groupId>xml-apis</groupId>
                                                <artifactId>xml-apis</artifactId>
                                            </exclusion>
                                        </exclusions>
                                    </dependency>
                                <dependency>
                            Last edited by Carol22; May 2nd, 2013, 05:23 AM.

                            Comment


                            • #15
                              POM part 2:
                              PHP Code:
                                          <groupId>org.springframework</groupId>
                                          <
                              artifactId>spring-webmvc</artifactId>
                                          <
                              version>${spring.version}</version>
                                      </
                              dependency>
                                      <
                              dependency>
                                          <
                              groupId>org.springframework.webflow</groupId>
                                          <
                              artifactId>spring-js-resources</artifactId>
                                          <
                              version>2.2.1.RELEASE</version>
                                      </
                              dependency>
                                      <
                              dependency>
                                          <
                              groupId>commons-digester</groupId>
                                          <
                              artifactId>commons-digester</artifactId>
                                          <
                              version>2.1</version>
                                          <
                              exclusions>
                                              <
                              exclusion>
                                                  <
                              groupId>commons-logging</groupId>
                                                  <
                              artifactId>commons-logging</artifactId>
                                              </
                              exclusion>
                                          </
                              exclusions>
                                      </
                              dependency>
                                      <
                              dependency>
                                          <
                              groupId>commons-fileupload</groupId>
                                          <
                              artifactId>commons-fileupload</artifactId>
                                          <
                              version>1.2.2</version>
                                      </
                              dependency>
                                      <
                              dependency>
                                          <
                              groupId>javax.servlet.jsp.jstl</groupId>
                                          <
                              artifactId>jstl-api</artifactId>
                                          <
                              version>1.2</version>
                                      </
                              dependency>
                                      <
                              dependency>
                                          <
                              groupId>org.glassfish.web</groupId>
                                          <
                              artifactId>jstl-impl</artifactId>
                                          <
                              version>1.2</version>
                                      </
                              dependency>
                                      <
                              dependency>
                                          <
                              groupId>javax.el</groupId>
                                          <
                              artifactId>el-api</artifactId>
                                          <
                              version>1.0</version>
                                          <
                              scope>provided</scope>
                                      </
                              dependency>
                                      <
                              dependency>
                                          <
                              groupId>joda-time</groupId>
                                          <
                              artifactId>joda-time</artifactId>
                                          <
                              version>1.6</version>
                                      </
                              dependency>
                                      <
                              dependency>
                                          <
                              groupId>javax.servlet.jsp</groupId>
                                          <
                              artifactId>jsp-api</artifactId>
                                          <
                              version>2.1</version>
                                          <
                              scope>provided</scope>
                                      </
                              dependency>
                                      <
                              dependency>
                                          <
                              groupId>commons-codec</groupId>
                                          <
                              artifactId>commons-codec</artifactId>
                                          <
                              version>1.5</version>
                                      </
                              dependency>
                                  <
                              dependency>
                                          <
                              groupId>org.apache.tiles</groupId>
                                          <
                              artifactId>tiles-jsp</artifactId>
                                          <
                              version>2.2.2</version>
                                      </
                              dependency>
                                  <
                              dependency>
                                          <
                              groupId>org.springframework.security</groupId>
                                          <
                              artifactId>spring-security-core</artifactId>
                                          <
                              version>${spring-security.version}</version>
                                          <
                              exclusions>
                                              <
                              exclusion>
                                                  <
                              groupId>commons-logging</groupId>
                                                  <
                              artifactId>commons-logging</artifactId>
                                              </
                              exclusion>
                                          </
                              exclusions>
                                      </
                              dependency>
                                      <
                              dependency>
                                          <
                              groupId>org.springframework.security</groupId>
                                          <
                              artifactId>spring-security-config</artifactId>
                                          <
                              version>${spring-security.version}</version>
                                          <
                              exclusions>
                                              <
                              exclusion>
                                                  <
                              groupId>commons-logging</groupId>
                                                  <
                              artifactId>commons-logging</artifactId>
                                              </
                              exclusion>
                                          </
                              exclusions>
                                      </
                              dependency>
                                      <
                              dependency>
                                          <
                              groupId>org.springframework.security</groupId>
                                          <
                              artifactId>spring-security-web</artifactId>
                                          <
                              version>${spring-security.version}</version>
                                      </
                              dependency>
                                      <
                              dependency>
                                          <
                              groupId>org.springframework.security</groupId>
                                          <
                              artifactId>spring-security-taglibs</artifactId>
                                          <
                              version>${spring-security.version}</version>
                                      </
                              dependency>
                                  </
                              dependencies>
                                  <
                              build>
                                      <
                              plugins>
                                          <
                              plugin>
                                              <
                              groupId>org.apache.maven.plugins</groupId>
                                              <
                              artifactId>maven-war-plugin</artifactId>
                                              <
                              version>2.2</version>
                                              <!-- <
                              configuration> <webXml>target/web.xml</webXml> </configuration> -->
                                              <
                              configuration>
                                                  <
                              webResources>
                                                      <
                              resource>
                                                          <
                              excludes>
                                                              <
                              exclude>dbre.xml</exclude>
                                                          </
                              excludes
                              Last edited by Carol22; May 2nd, 2013, 05:22 AM.

                              Comment

                              Working...
                              X