Deploying an SSH project to WebLogic server

Source: Internet
Author: User

The local webserver is TOMCAT7 and eventually deployed to WebLogic 11g. The following methods are all Google results.


1. Post-deployment says ClassNotFoundException

WebLogic class Load order problem, create weblogic.xml under the Web-inf directory.

<?xml version= "1.0" encoding= "UTF-8"? ><weblogic-web-appxmlns= "http://www.bea.com/ns/weblogic/ Weblogic-web-app "xmlns:xsi=" http://www.w3.org/2001/XMLSchema-instance "xsi:schemalocation=" http://www.bea.com/ Ns/weblogic/weblogic-web-app http://www.bea.com/ns/weblogic/weblogic-web-app/1.0/weblogic-web-app.xsd "> < Container-descriptor> <index-directory-enabled>true</index-directory-enabled> <prefer-web- Inf-classes>true</prefer-web-inf-classes> <show-archived-real-path-enabled>true</ Show-archived-real-path-enabled> </container-descriptor></weblogic-web-app>

means let WebLogic load the jar package below Web-inf/lib first


2. Unable to instantiate action


The Web. XML in WebLogic does not support wildcard notation, such as:

Deployed to Tomcat can be written like this

<context-param> <param-name>contextConfigLocation</param-name> <param-value>classpath*:/ Applicationcontext*.xml</param-value></context-param>

But it has to be written in WebLogic.

<context-param> <param-name>contextConfigLocation</param-name> <param-value> Class Path:/applicationcontext.xml Classpath:/applicationcontext-bean.xml </param-value> </context-param> ;


3. Sessionfactory Configuration

Tomcat under:

<bean id= "Sessionfactory" class= "Org.springframework.orm.hibernate3.LocalSessionFactoryBean" > <property Name= "Configlocation" value= "Classpath:hibernate.cfg.xml"/></bean>


WebLogic using DataSource:

<bean id= "DataSource"  class= "Org.springframework.jndi.JndiObjectFactoryBean"  >     <property name= "Jndiname" >        < value>jdbc/testds</value>    </property></bean>     <bean id= "Sessionfactory"           class= " Org.springframework.orm.hibernate3.LocalSessionFactoryBean ">    <property name= "DataSource"  ref= "DataSource"/>    <property name= "Mappingresources" >         <list>             <value>com/pojo/Refresh.hbm.xml</value>         </list>    </property>    <property  name= "Hibernateproperties" >        <props>             <prop key= "Hibernate.dialect" >org.hibernate.dialect.oracledialect</prop >            <prop key= " Hibernate.connection.release_mode ">auto</prop>             <prop key= "Hibernate.current_session_context_class" >jta</prop>             <prop key= "Hibernate.transaction.manager_ Lookup_class ">                 org.hibernate.transaction.WeblogicTransactionManagerLookup             </prop>        </props>     </property>&lT;/bean> 


Reference Link: http://simon-fish.iteye.com/blog/1136438

Deploying an SSH project to WebLogic server

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.