Announcement Announcement Module
Collapse
No announcement yet.
problem occured when deploy application in weblogic platform Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • problem occured when deploy application in weblogic platform

    I deploy my application both in tomcat 5.0 and weblogic 8.0 .
    In tomcat platform it is ok for everything.But in weblogic platform , I got many problem in it . Especially in applicaion-context files.

    When I deploy my applcation at weblogic ,there are some problem
    occured in my way.

    Code:
    <2005-6-30 上午09时25分50秒 CST> <Warning> <HTTP> <BEA-101162> <User defined listener org.springframework.web.context.Co
    ntextLoaderListener failed&#58; org.springframework.beans.factory.BeanCreationException&#58; Error creating bean with name 'sess
    ionFactory' defined in resource &#91;/WEB-INF/applicationContext-all.xml&#93; of ServletContext&#58; Initialization of bean failed;
    nested exception is java.io.FileNotFoundException&#58; Could not open class path resource &#91;WEB-INF/config/hibernate/com/some/model/SomeDevice.hbm.xml&#93;.>
    There is the ComicDevice.hbm.xml file avaliable in the /WEB-INF/config/hibernate/com/some/model/ directory.

    There is the block of my applicationContext-all.xml


    Code:
    <bean id="sessionFactory" class="org.springframework.orm.hibernate.LocalSessionFactoryBean">
            <property name="dataSource">
                <ref bean="dataSource"/>
            </property>
    
    
                    <property name="mappingResources">
                        <list>
                            <value>WEB-INF/config/hibernate/com/some/model/SomeDevice.hbm.xml</value>
                        </list>
                    </property>
      
            <property name="hibernateProperties">
                <props>
                    <prop key="hibernate.dialect">net.sf.hibernate.dialect.OracleDialect</prop>
                </props>
            </property>
        </bean>
    There are the other strange problem in this file .When I use

    Code:
          <property name="mappingJarLocations">
                <list>
                    <value>/WEB-INF/lib/some-dao.jar</value>
                </list>
            </property>
    (some-dao.jar contain some hbm configure files)
    weblogic platform log told me some exception when I deploy the application.

    Code:
    <2005-6-30 上午10时37分37秒 CST> <Warning> <HTTP> <BEA-101162> <User defined listener org.springframework.web.context.Co
    ntextLoaderListener failed&#58; org.springframework.beans.factory.BeanCreationException&#58; Error creating bean with name 'sess
    ionFactory' defined in resource &#91;/WEB-INF/applicationContext-all.xml&#93; of ServletContext&#58; Initialization of bean failed;
    nested exception is java.io.FileNotFoundException&#58; resource &#91;/WEB-INF/lib/some-dao.jar&#93; of ServletContext cannot be res
    olved to absolute file path - web application archive not expanded?.>
    I have no idea about these problem because in tomcat it is ok .
    pls some one help me .

  • #2
    Re: problem occured when deploy application in weblogic plat

    Originally posted by hk2000c
    Code:
                    <property name="mappingResources">
                        <list>
                            <value>WEB-INF/config/hibernate/com/some/model/SomeDevice.hbm.xml</value>
                        </list>
                    </property>
    Try placing a slash (/) before WEB-INF:
    /WEB-INF/config/hibernate/com/some/model/SomeDevice.hbm.xml

    Regards,
    Andreas

    Comment

    Working...
    X