jboss 7部署cas3.4.11

国内私募机构九鼎控股打造APP,来就送 20元现金领取地址: http://jdb.jiudingcapital.com/phone.html
内部邀请码: C8E245J (不写邀请码,没有现金送)
国内私募机构九鼎控股打造,九鼎投资是在全国股份转让系统挂牌的公众公司,股票代码为430719,为“中国PE第一股”,市值超1000亿元。 

 

------------------------------------------------------------------------------------------------------------------------------------------------------------------

 

 

jboss 7 部署 cas
cas 版本为 3.4.11
另外新的cas,做 jboss 集群时不用在 web.xml 配置 session 复制,即不需要在 web.xml 中增加:

< distributable  />

主要参考:http://www.liferay.com/community/wiki/-/wiki/Main/JBoss+AS7+tips#section-JBoss+AS7+tips-Installing+cas-web

Even default cas.war, built from the source, can not be deployed to the Jboss AS7 without further modifications. Here are the steps how to deploy our cas-web plugin:

  • deploy cas-web. Deployment will fail (Connection cannot be null when 'hibernate.dialect' not set). Stop JBoss server.
  • go to cas web exploded folder: /bundles/jboss-7.0.2/standalone/deployments/cas-web.war
  • Locate: cas-web.war/WEB-INF/lib/cas-server-core-3.3.5.jar. Modify it: remove /META-INF/persistence.xml from it
  • Create WEB-INF/classes/META-INF/persistence.xml with content displayed bellow.
  • Delete cas-web.war/WEB-INF/lib/dom4j-1.6.1.jar
  • Start jboss as7. Wait until everything is up. Trigger deployment of cas-web by creating file:cas-web.war.dodeploy in JBoss standalone deployment folder.

The content of persistence.xml file is:

<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_2_0.xsd"
        version="2.0">

    <persistence-unit name="CasPersistence" transaction-type="RESOURCE_LOCAL">
          <properties>
            <property name="hibernate.dialect" value="org.hibernate.dialect.HSQLDialect"/>
          </properties>
    </persistence-unit>
</persistence>

Note: newer versions of cas.war already has the persistence.xml extracted from the core jar. Moreover, newever persistence.xml contains some additional definitions, be sure not to delete them when adding 'hibernate.dialect' property.

其中persistence.xml文件可以不删除,添加:

<properties>
            <property name="hibernate.dialect" value="org.hibernate.dialect.HSQLDialect"/>
          </properties>

就可以运行。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值