I have reviewed the ServiceRegistryDaoImpl for 3.5.2.1.  It seems to be
failing at the initDao method inherited from
org.springframework.dao.support.DaoSupport.

If there is any configuration change to the definitions for the
org.jasig.cas.services.JapServiceRegistryDaoImpl class and its nested
classes from 3.4.2.1 to 3.5.2.1, please tell me what they are.

I do see substantial changes noted in the documentation for 4.00 +, but
have not found any indication I need to change between the two versions
noted above.  I searched through every class referenced in the bean
definition for serviceRegistryDao.

They are all contained in spring-tx-3.1.1.RELEASE.jar,
spring-orm-3.1.1.RELEASE.jar or commons-dbcp.jar.  I may need to upgrade my
version of commons-dbcp.jar.  Which version is used for 3.5.2.1?

Linda

Linda Toth
University of Alaska - Office of Information Technology (OIT) - Identity
and Access Management
910 Yukon Drive, Suite 103
Fairbanks, Alaska 99775
Tel: 907-450-8320
Fax: 907-450-8381
linda.t...@alaska.edu | www.alaska.edu/oit/


On Wed, Dec 17, 2014 at 11:17 AM, Linda Toth <ltt...@alaska.edu> wrote:
>
> Good afternoon,
>
> As much as I hate to admit it, I am humbled by the transition from 3.4.2.1
> to 3.5.2.1.
>
> I have used the maven overly 4.0.0 and although I see some later versions
> of libraries come in that what is recommended on the maven repository page
> for dependencies, I have been able to verify I have the correct version.
>
> Nevertheless,  despite checking all versions and all dependencies, I
> continue to get an error when it tries to resolve the
> entityManagerFactory.  From what I can find via web searches, I may be
> caught in the middle of some version conflicts for dependencies, but can
> not find which versions of some jars to use with certainty.  Maven has
> downloaded multiple version of the same jar in some cases.
>
> The pertinent excerpt of the error is:
>
> 2014-12-16 14:18:06,512 ERROR
> [org.springframework.web.context.ContextLoader] - Context initialization
> failed
>
> org.springframework.beans.factory.BeanCreationException: Error creating
> bean with name 'servicesManager' defined in ServletContext resource
> [/WEB-INF/spring-configuration/applicationContext.xml]: Cannot resolve
> reference to bean 'serviceRegistryDao' while setting constructor argument;
> nested exception is
> org.springframework.beans.factory.BeanCreationException: Error creating
> bean with name 'serviceRegistryDao' defined in ServletContext resource
> [/WEB-INF/deployerConfigContext.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 ServletContext resource
> [/WEB-INF/deployerConfigContext.xml]: Invocation of init method failed;
> nested exception is java.lang.NullPointerException
>
> 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.ConstructorResolver.resolveConstructorArguments(ConstructorResolver.java:616)
>
> at
> org.springframework.beans.factory.support.ConstructorResolver.autowireConstructor(ConstructorResolver.java:148)
>
> There is no DB connection error being thrown in the
> localhost.2014-12-xx.log file.
>
> I have everything I have been able to find online about this error and
> this situation in CAS and so far, none of the suggested solutions has
> resolved the error.  *I have not found an example of
> JpaServiceRegistryDaoImpl configuratio for 3.5.2.1. * I am left to assume
> that the error is not in the configuration itself, but in the dependencies.
>
> Nevertheless, here is what I have for the serviceRegistryDao
> configurations:
>
>     <!--
>
>     | Permanent data store for the Service Registry with
>
>     | JPA-backedServiceRegistry
>
>     | DAO. The name of this bean remains "serviceRegistryDao".
>
>     +-->
>
>     <bean id="serviceRegistryDao"
>
>         class="org.jasig.cas.services.JpaServiceRegistryDaoImpl"
>
>         p:entityManagerFactory-ref="entityManagerFactory" />
>
>
>     <bean id="entityManagerFactory" class=
> "org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean">
>
>         <property name="dataSource" ref="dataSource"/>
>
>         <property name="jpaVendorAdapter">
>
>            <bean class=
> "org.springframework.orm.jpa.vendor.HibernateJpaVendorAdapter">
>
>                <property name="generateDdl" value="true"/>
>
>                <property name="showSql" value="true"/>
>
>            </bean>
>
>         </property>
>
>         <property name="jpaProperties">
>
>             <props>
>
>                 <prop key="hibernate.dialect">
> org.hibernate.dialect.OracleDialect</prop>
>
>                 <prop key="hibernate.hbm2ddl.auto">update</prop>
>
>             </props>
>
>         </property>
>
>     </bean>
>
>
>     <bean id="transactionManager" class=
> "org.springframework.orm.jpa.JpaTransactionManager">
>
>         <property name="entityManagerFactory" ref="entityManagerFactory"/>
>
>     </bean>
>
>
>     <tx:annotation-driven transaction-manager="transactionManager"/>
>
>
>     <bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource"
>
>         p:driverClassName="${db.driverClassName}"
>
>         p:url="${db.url}"
>
>         p:password="${db.password}"
>
>         p:username="${db.user}" />
>
>
> ASIDE:
> In the process, I have wondered, why we have multiple versions of the
> javassist-x.jar (3.24.0-GA & 3.7.ga) downloading and why neither of those
> match the current maven documentation stated dependency of 3.12.1.GA
> <http://3.12.1.ga/>.
>
> Anything you can toss my way would be greatly appreciated.
>
> Linda Toth
> University of Alaska - Office of Information Technology (OIT) - Identity
> and Access Management
> 910 Yukon Drive, Suite 103
> Fairbanks, Alaska 99775
> Tel: 907-450-8320
> Fax: 907-450-8381
> linda.t...@alaska.edu | www.alaska.edu/oit/
>
>

-- 
You are currently subscribed to cas-user@lists.jasig.org as: 
arch...@mail-archive.com
To unsubscribe, change settings or access archives, see 
http://www.ja-sig.org/wiki/display/JSG/cas-user

Reply via email to