<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    posts - 193,  comments - 520,  trackbacks - 0

    1. 從 http://www.jboss.com/products/jbpm/downloads 下載 jbpm-3.0.zip

    2. 解壓縮 jbpm-3.0.zip 到 'temp' 目錄

    3. 使用 eclipse, 將 'temp\jbpm-3.0' 作為 an existing project into workspace 導入

    配置連接 MySQL

    1. 在 'jbpm-3.0\lib' 目錄下 創建 'mysql' 目錄

    2. 將 mysql數據庫驅動 (mysql-connector-java-3.1.7-bin.jar) 拷貝到 'mysql' 目錄

    3. 在 mysql 中創建一個數據庫,數據庫名字

    4. 在 'jbpm-3.0\src\resources'目錄下創建 'mysql' 目錄

    5. 把兩個配置文件 (create.db.hibernate.properties, identity.db.xml) 從 'hsqldb' 目錄下 拷貝到 'mysql' 目錄

    6. 按下面所示編輯 'create.db.hibernate.properties' 文件: hibernate.dialect=org.hibernate.dialect.MySQLDialect

    hibernate.connection.driver_class=com.mysql.jdbc.Driver

    hibernate.connection.url=jdbc:mysql://localhost:3306/

    hibernate.connection.username= hibernate.connection.password=

    hibernate.show_sql=true hibernate.query.substitutions=true 1, false 0

    hibernate.c3p0.min_size=1 hibernate.c3p0.max_size=3

    7. 另一個文件 'identity.db.xml'不做改動

    8. 在 'jbpm-3.0' 根目錄, 編輯ANT的腳本 'build.deploy.xml' 找到 target name="create.db", 刪除 db.start, db.stop 在這個目標塊中將所有的'hsqldb' 替換為 'mysql'

    9. 運行ANT ant create.db -buildfile build.deploy.xml 運行完畢后就會發現mysql中多出很多表,這是jbpm保持狀態用的

    創建 jbpm.war 使其在tomcat中運行

    默認的打war包時,掉了一些庫文件

    1. 在 eclipse中, 編輯ant腳本 'build.deploy.xml' 在目標塊 target name="build.webapp" 中在

    <copy todir="build/jbpm.war.dir/WEB-INF/lib"> 下將

    <fileset dir="build" includes="jbpm-webapp-${jbpm.version}.jar" /> 替換為

    <fileset dir="build" includes="jbpm*.jar" />

     另外加入新的兩行

    <fileset dir="lib/hibernate" includes="*.jar" />
    <fileset dir="lib/bsh" includes="*.jar" />

    2.因為 Hibernate 不能將它的SessionFactory與tomcat的jndi 綁定 , 我們直接在源碼中修改

    3. 打開源文件 JbpmSessionFactory.java, 在 getInstance() 方法里, 刪除下面代碼

    InitialContext initialContext = new InitialContext(); Object o = initialContext.lookup(jndiName);

    將下面這行

    instance = (JbpmSessionFactory) PortableRemoteObject.narrow
    (o, JbpmSessionFactory.class);

    替換為 instance = (JbpmSessionFactory) PortableRemoteObject.narrow
    (new JbpmSessionFactory(createConfiguration()), JbpmSessionFactory.class);

    4.在 createConfiguration(String configResource) 方法里, 注釋掉這段代碼

    String hibernatePropertiesResource = JbpmConfiguration.getString("jbpm.hibernate.properties");

    if (hibernatePropertiesResource!=null) { Properties hibernateProperties =
    new Properties();

    try { hibernateProperties.load( ClassLoaderUtil.getStream(hibernatePropertiesResource) ); }

    catch (IOException e) {
          e.printStackTrace();
          throw new RuntimeException
       ("couldn't load the hibernate properties from resource      '"hibernatePropertiesResource"'", e);
    }
    log.debug("overriding hibernate properties with "+ hibernateProperties); configuration.setProperties(hibernateProperties);
    }
    同時加入下面的代碼

    configuration.setProperty("hibernate.dialect", "org.hibernate.dialect.MySQLDialect");

    configuration.setProperty("hibernate.connection.driver_class", "com.mysql.jdbc.Driver");

    configuration.setProperty("hibernate.connection.url", "jdbc:mysql://localhost:3306/";);

    configuration.setProperty("hibernate.connection.username", "");

    configuration.setProperty("hibernate.connection.password", "");

    configuration.setProperty("hibernate.connection.pool_size", "15");

    5. 運行腳本命令 ant build ant build.webapp -buildfile build.deploy.xml

    6. 將jbpm.war 從 'jbpm-3.0\build' 下拷貝到 'tomcat.home\webapps'

    7. 啟動 tomcat

    8. 打開瀏覽器 'http://localhost:8080/jbpm'



    http://www.tkk7.com/ronghao 榮浩原創,轉載請注明出處:)
    posted on 2005-11-10 17:31 ronghao 閱讀(3415) 評論(5)  編輯  收藏 所屬分類: 工作日志

    FeedBack:
    # re: 在Tomcat中配置運行jbpm自帶的websale
    2005-11-16 14:51 | 孫茂成
    我的公司msn:smc@rjgrid.com.cn
    私人msn:thunderbird.smc@homtamil.com
    我的信箱:thunderbird.smc@gmail.com

    很高興看到你的博客,我正在讀jbpm源碼手上也有個比較大的項目,希望能和你交流
      回復  更多評論
      
    # re: 在Tomcat中配置運行jbpm自帶的websale
    2005-11-16 18:04 | ronghao
    我也是剛剛對jbpm看了看源碼,還沒在實際項目中運用過,多交流吧  回復  更多評論
      
    # re: 在Tomcat中配置運行jbpm自帶的websale
    2005-11-18 17:37 | 路人甲
    首先十分大哥的這篇文章,小弟是剛剛接觸工作流,很多地方都不懂,看完這篇文章后實在受益非淺.
    另我在實際操作中有幾處與上文有出入
    hibernate.connection.url=jdbc:mysql://localhost:3306/jbpmtest
    這里不指定database的話好像會找不到數據庫吧?
    configuration.setProperty("hibernate.connection.url", "jdbc:mysql://localhost:3306/jbpmtest");
    configuration.setProperty("hibernate.connection.username", "root");
    <fileset dir="lib/mysql" includes="*.jar" />
    數據庫驅動



      回復  更多評論
      
    # re: 在Tomcat中配置運行jbpm自帶的websale
    2006-04-06 17:53 | dawn
    我按照上邊的方法打好war后發布時jsp頁面顯示,requested resource is not available。
    而且當把jbpm.war copy到webapps目錄下后,啟動tomcat時會報好長的錯:嚴重parse Error …… Document is in invalid: no grammer found. org.xml.sax.SAXParseException。

    請問這是怎么回事呢?  回復  更多評論
      
    # re: 在Tomcat中配置運行jbpm自帶的websale
    2006-08-17 09:17 | hou
    我按要求把jbpm放在tomcat下運行時產生錯誤,嚴重Error ListenerStart,
    在build.properties配置好Jboss之后,運行jbpm-server下的start.bat不出錯,就是有的時候數據庫的表沒了,怎么回事?
    msn:houzz_101@hotmail.com  回復  更多評論
      
    <2005年11月>
    303112345
    6789101112
    13141516171819
    20212223242526
    27282930123
    45678910

    關注工作流和企業業務流程改進。現就職于ThoughtWorks。新浪微博:http://weibo.com/ronghao100

    常用鏈接

    留言簿(38)

    隨筆分類

    隨筆檔案

    文章分類

    文章檔案

    常去的網站

    搜索

    •  

    最新評論

    閱讀排行榜

    評論排行榜

    主站蜘蛛池模板: 免费a级毛片18以上观看精品| **aaaaa毛片免费同男同女| 青青青青青青久久久免费观看| 亚洲2022国产成人精品无码区| a毛片在线还看免费网站| 亚洲精品无码午夜福利中文字幕| 中文字幕乱码系列免费| 亚洲精品无码国产| 久久免费福利视频| 亚洲av日韩av无码av| 在线a级毛片免费视频| 亚洲风情亚Aⅴ在线发布| 亚洲av高清在线观看一区二区 | 国产综合精品久久亚洲| 久久精品无码专区免费| 亚洲AV无码乱码在线观看富二代| 最近中文字幕mv免费高清视频8| 亚洲熟妇色自偷自拍另类| 最近2019中文字幕mv免费看 | 久久免费福利视频| 亚洲一区二区三区精品视频| 最近免费中文字幕大全视频 | 亚洲妇女水蜜桃av网网站| 毛片免费在线播放| 暖暖免费中文在线日本| 久久亚洲国产欧洲精品一| 久草免费在线观看视频| 亚洲AV日韩综合一区| 国产亚洲av片在线观看18女人| 精品无码国产污污污免费网站| 亚洲日韩精品无码专区加勒比☆| 久久精品国产精品亚洲下载| 99久久综合精品免费| 亚洲AV无码片一区二区三区| 国产亚洲精AA在线观看SEE| 色婷婷7777免费视频在线观看| 日本黄页网址在线看免费不卡 | 亚洲精品你懂的在线观看| 国产成在线观看免费视频| 九九久久精品国产免费看小说| 亚洲综合一区二区国产精品|