Announcement Announcement Module
Collapse
No announcement yet.
Error creating beans on solaris Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • inyo
    started a topic Error creating beans on solaris

    Error creating beans on solaris

    I am getting the below error on deploying the application on Solaris server, I have deployed the same application on 2 Linux servers (same files / the WLS server has the exact configuration) and it worked fine.

    The application uses hibernate (The transaction manager for the datasource used below is defined in the hibernate mapping file)

    The error says "Unsatisfied dependency expressed through constructor argument with index 1 of type [boolean]" for the inventoryJdbcTemplate, Where as the app context (pasted below) defines it otherwise!!!

    Caused by: org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'msdE2ELoggingFactory' defined in URL [zip:/scratch/bealims/wls/weblogic9.2.3/user_projects/domains/LimsMSDDomain/servers/MSDWLS9SERVER/tmp/_WL_user/lims-featureline/7ltygn/war/WEB-INF/lib/lims-common.jar!/spring/applicationContext-auditLogging.xml]: Instantiation of bean failed; nested exception is java.lang.NoClassDefFoundError
    Related cause: org.springframework.beans.factory.UnsatisfiedDepen dencyException: Error creating bean with name 'inventoryJdbcTemplate' defined in URL [zip:/scratch/bealims/wls/weblogic9.2.3/user_projects/domains/LimsMSDDomain/servers/MSDWLS9SERVER/tmp/_WL_user/lims-featureline/7ltygn/war/WEB-INF/lib/lims-common.jar!/spring/applicationContext-jdbc.xml]: Unsatisfied dependency expressed through constructor argument with index 1 of type [boolean]: Ambiguous constructor argument types - did you specify the correct bean references as constructor arguments?
    at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.instantiateBean(Abstrac tAutowireCapableBeanFactory.java:851)
    at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.createBeanInstance(Abst ractAutowireCapableBeanFactory.java:807)
    at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.doCreateBean(AbstractAu towireCapableBeanFactory.java:437)

    ********************************

    This is the app context file:

    <bean id="serviceRepositoryDataSource" class="com.bt.lims.common.persistancelayer.Invento ryBasicDataSource">
    <constructor-arg index="0">
    <bean class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close">
    <property name="url" value="${repository.cramer.url}"/>
    <property name="username" value="${repository.cramer.user}"/>
    <property name="password" value="${repository.cramer.password}"/>
    <property name="driverClassName" value="${repository.cramer.driver}"/>
    <property name="accessToUnderlyingConnectionAllowed" value="true"/>
    <property name="initialSize" value="1"/>
    <property name="maxActive" value="${repository.maxActive}"/>
    <property name="minIdle" value="0"/>

    <property name="validationQuery" value="SELECT SYSDATE FROM DUAL" />
    <property name="testOnBorrow" value="true" />
    <property name="testOnReturn" value="true" />
    <property name="testWhileIdle" value="true" />
    <property name="timeBetweenEvictionRunsMillis" value="300000" />
    <property name="numTestsPerEvictionRun" value="3" />
    <property name="minEvictableIdleTimeMillis" value="300000" />
    <property name="poolPreparedStatements" value="true" />
    <property name="removeAbandoned" value="true" />
    <property name="removeAbandonedTimeout" value="300" />
    <property name="logAbandoned" value="true" />
    </bean>
    </constructor-arg>
    </bean>


    <bean id="inventoryJdbcTemplate" class="org.springframework.jdbc.core.JdbcTemplate" >
    <constructor-arg index="0" ref="serviceRepositoryDataSource" />
    </bean>


    ******************

  • vinod.singh
    replied
    See if something is missing in your classpath-
    Instantiation of bean failed; nested exception is java.lang.NoClassDefFoundError

    Leave a comment:

Working...
X