posts - 7, comments - 1, trackbacks - 0, articles - 0

          2006年8月15日

          1. mysql driver -> server\default\lib
          2. jdbc connection datasource server/default/deploy/mysql-xa-ds.xml
          <?xml version="1.0" encoding="UTF-8"?>
          <datasources>
          ?<xa-datasource>
          ??<jndi-name>MySqlXADS</jndi-name>
          ??<xa-datasource-class>com.mysql.jdbc.jdbc2.optional.MysqlXADataSource</xa-datasource-class>
          ??<xa-datasource-property name="Url">jdbc:mysql://127.0.0.1:3306/temp</xa-datasource-property>
          ??<xa-datasource-property name="User">root</xa-datasource-property>
          ??<xa-datasource-property name="Password">....</xa-datasource-property>
          ??<user-name>root</user-name>
          ??<password>.....</password>
          ??<exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.MySQLExceptionSorter</exception-sorter-class-name>
          ??<metadata>
          ???<type-mapping>mySQL</type-mapping>
          ??</metadata>
          ?</xa-datasource>
          </datasources>

          3. server/default/conf/standardjbosscmp-jdbc.xml
          <defaults>
          ????? <datasource>java:/MySqlXADS</datasource>
          ????? <datasource-mapping>mySQL</datasource-mapping>
          ....
          ....??
          </defaults>

          4. server/default/conf/jboss-service.xml
          <mbean code="org.jboss.tm.XidFactory"
          ????? name="jboss:service=XidFactory">
          ?//uncommented the line below...
          ????? <attribute name="Pad">true</attribute>
          ?? </mbean>

          posted @ 2006-09-01 08:55 Jedi 閱讀(1125) | 評論 (0)編輯 收藏

          1. 某個service的參數(shù)有復(fù)雜對象時,如果要用默認(rèn)的beanmapping,記得這個對象要有的默認(rèn)構(gòu)造器(空參數(shù)構(gòu)造器),不然Axis在處理的時候會所有的字段都是同一個值..至于原因我沒搞清楚-,-~~
          2. 不要用List,盡量用數(shù)組!
          ValueBean[]?getValues()?
          ????
          {?
          ????????ArrayList?result?
          =?new?ArrayList();?
          ????????
          return?(ValueBean[])?result.toArray();?
          ????}
          上面的代碼還是會出問題,要用iterator一個一個map過去
          public?class?ValueHelper?
          ????
          {?
          ????????
          public?static?ValueBean[]?toArray(List?values)?
          ????????
          {
          ????????????ValueBean[]?result?
          =?new?ValueBean[values.size()];?
          ????????????Iterator?i?
          =?values.iterator();?
          ????????????
          int?i?=?0;?
          ????????????
          while?(i.hasNext())?
          ????????????
          {?
          ????????????????ValueBean?value?
          =?(ValueBean)?i.next();?
          ????????????????result[i
          ++]?=?value;?
          ????????????}
          ?
          ????????????
          return?result;?
          ????????}
          ?
          ????}
          ?
          ????ValueBean[]?getValues()?
          {?
          ????????ArrayList?result?
          =?new?ArrayList();??
          ????????
          return?ValueHelper.toArray(result);?
          ????}
          3. 要生成符合ws-i的web service最好用document/literal
          <service name="MyWebRes" provider="java:RPC" style="document "use="literal">

          posted @ 2006-08-15 09:22 Jedi 閱讀(284) | 評論 (0)編輯 收藏

          http://www.fiddlertool.com/fiddler/?
          .net framework 1.1 needed

          for firefox need some added configurat

          menu->tools->preference/option->connection settings->bottom->

          C:\Documents and Settings\jedikings\My Documents\Fiddler\Scripts\BrowserPAC.js -> reload

          posted @ 2006-08-15 09:15 Jedi 閱讀(253) | 評論 (0)編輯 收藏

          主站蜘蛛池模板: 黄陵县| 栾川县| 丽江市| 崇礼县| 庆阳市| 贵定县| 吉林省| 沭阳县| 渝中区| 阿拉善右旗| 云南省| 阿拉善盟| 宜宾市| 二手房| 哈尔滨市| 文昌市| 肇庆市| 乌拉特前旗| 当雄县| 色达县| 建始县| 绥芬河市| 新沂市| 台东县| 万盛区| 汪清县| 泰来县| 策勒县| 汝城县| 漳州市| 临沧市| 兖州市| 榆林市| 许昌市| 皮山县| 沁源县| 博罗县| 红原县| 黄龙县| 麦盖提县| 隆尧县|