??xml version="1.0" encoding="utf-8" standalone="yes"?>亚洲乱码国产乱码精品精,93在线视频精品免费观看,国产九九在线http://www.aygfsteel.com/midea0978/category/3623.htmlzh-cnTue, 09 Apr 2013 02:34:38 GMTTue, 09 Apr 2013 02:34:38 GMT60EAR文gl构http://www.aygfsteel.com/midea0978/archive/2013/04/08/397531.html在\?..在\?..Mon, 08 Apr 2013 08:18:00 GMThttp://www.aygfsteel.com/midea0978/archive/2013/04/08/397531.htmlhttp://www.aygfsteel.com/midea0978/comments/397531.htmlhttp://www.aygfsteel.com/midea0978/archive/2013/04/08/397531.html#Feedback0http://www.aygfsteel.com/midea0978/comments/commentRss/397531.htmlhttp://www.aygfsteel.com/midea0978/services/trackbacks/397531.html1、打包文件命名规?/strong>
Ҏ(gu)JavaEE规范Q打包的EAR文g可以不适用部v描述W部|Ԍ因此需要用一些默认的U定规则Q例?br /> •EJBs and client archives are packaged as .jar files.

•Web applications are packaged as .war files.

•Resource adapters are packaged as .rar files.

•Enterprise applications are packaged as .ear files, and can contain other Java EE modules such as EJBs, JDBC, JMS, Web applications, and Resource Adapters.

•Web Services can be packaged either as .war files or as .jar files, depending on whether they are implemented using Java classes or EJBs. Typically, the .war or .jar files are then packaged in an Enterprise Application .ear file.

•Java EE libraries are packaged either as an Enterprise Application (.ear file) or as a standard Java EE module.

•Client applications and optional packages are packaged as .jar files.
2、Java EE默认部v规则
通常EAR应用也可以用开攑ּ目录部vQ此时也应该参考以上的规范配置相应的文件夹Q例?br /> war应用目录名必MؓXX.war
EAR==>xx.ear 
RAR==>XX.rar
EJB==>xx.jar

3、Java EE标准的部|规?/strong>
aQ?应用包中所有扩展名?war 的文件被看作?web 模块。Web 模块的上下文?br />的名字是相对于应用包根的名字Q但要去?war 扩展名?br />bQ?应用包中所有扩展名?rar 的文仉被看作是资源适配器?br />cQ?名字?lib 的目录被看作是库目录Q正如在?8.2.1“捆绑的库”中所q?br />dQ?对于应用包中所有以扩展名是.jar 但不包含?lib 目录内的文g来说Q按下面 的方式来处理Q?br />i. 如果 JAR 文g中包含带?Main‐Class 属性的 META‐INF/MANINFEST.MF 文gQ?或者包?META‐INF/application‐client.xml 文gQ那么这?JAR 文g被看?是应用客L模块?br />ii. 如果 JAR 文g包含 META‐INF/ejb‐jar.xml 文gQ或者包含Q何带?EJB lg 注释W(StatelessQ等{)的类Q那么这?JAR 文g被看作是 EJB 模块?br />iii. 所有其他的 JAR 文g都被忽略Q除非它被上面的 JAR 文g使用 JAR 文g?用机Ӟ如在 mainfest 文g中的 Class‐Path ?font face="Verdana">library-directoryQ引用?br />
在Jboss环境中,可以在application.xml中手工指定library-directoryQ例如:
<library-directory>APP-INF/lib</library-directory>
其他的jboss遵@标准规范

4、Weblogic的部|规?/strong>
对于weblogic使用下面的一些规则处理目录结构:

•For an exploded archived Web application, in the absence of WEB-INF/web.xml descriptor, the name of the directory should have a .war suffix.

•For an exploded archived Enterprise Application without a META-INF/application.xml descriptor, the directory should have an .ear suffix. Within the application, the directory of exploded Web module should have a .war suffix. Similarly, the exploded EJB module should have a .jar suffix and the exploded RAR module should have a .rar suffix.

•If an exploded Enterprise Application contains no META-INF/application.xml descriptor, the order in which modules are deployed is undefined and is dependent on the underlying File.listFiles() method order. To ensure a specific order in which modules are deployed, you must add an application.xml descriptor and list the modules in the desired order.

如果在weblogic下面如果不用上面的规则Q则需要在application.xml 文g中指定对应的uri路径
或者在应用模块中用下面的manifest路径规则

4.1 classloader的\径引?/strong>
在weblogic中EAR里面的所有应用共有一个classloaderQ所以对于ear里面的warQ通常不需要在WEB-INF里面包含libQweblogic提供了一个默认的目录Q?br /> APP-INF\lib:存放jar?br /> APP-INF\classes:存放classes

注意对于其他的应用服务器Q可能没有这L规则

5?/strong>Manifest Class-Path规则
在java EE规范中,可以使用manifest文g指定当前的应用模块对与其他classpath路径的关联引用,该文件位?br /> META-INF/MANIFEST.MF
路径下面Q内容例如下面,多个引用路径使用I格分隔Q?br />
Manifest-Version: 1.0
Class-Path: utility.jar ../xxx/classes ../xxxlib/xxx.jar

META-INF/MANIFEST.MF



Manifest Class-Path


 

参考页面: http://docs.oracle.com/cd/E12839_01/web.1111/e13706/classloading.htm http://docs.oracle.com/cd/E12839_01/web.1111/e13702/deployunits.htm#DEPGD142

在\?.. 2013-04-08 16:18 发表评论
]]>
JAVA AWT处理囄时的错误http://www.aygfsteel.com/midea0978/archive/2012/01/19/368742.html在\?..在\?..Thu, 19 Jan 2012 04:01:00 GMThttp://www.aygfsteel.com/midea0978/archive/2012/01/19/368742.htmlhttp://www.aygfsteel.com/midea0978/comments/368742.htmlhttp://www.aygfsteel.com/midea0978/archive/2012/01/19/368742.html#Feedback0http://www.aygfsteel.com/midea0978/comments/commentRss/368742.htmlhttp://www.aygfsteel.com/midea0978/services/trackbacks/368742.html在linux环境部v应用Ӟ有时候需要用到AWT处理囄的功能,典型的就是图片的~放处理{等Q可能会遇到下面错误Q?br />java.lang.NoClassDefFoundError
  at java.lang.Class.forName0(Native Method)
  at java.lang.Class.forName(Class.java:141)
  at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:62)
  at java.awt.image.BufferedImage.createGraphics(BufferedImage.java:1041)

甚至在默写情况下面可能导致jvm崩溃Q对于该问题的解军_法是

1、配|java启动参数java -Djava.awt.headless=true
在jdk1.4及以上的环境中,允许使用没有键盘、鼠标、x window昄启动的headless虚拟机模式,通过加上上面的属性即?/p>

2、配|合适的DISPLAY属?/p>

例如通过当前用户启动了一个x window的图形界面,可以设|类似export DISPLAY=localhost:10.0q样的环境变量将awt定位C个实际存在的环境处理?/p>

配置成功之后Q可能可以看到这L提示

nl.ikarus.nxt.priv.imageio.icoreader.lib.ICOReader loaded, version: 0.06.064 build: 691

配置好之后就不会报错?/p>

|上q有一U办法,启动Xvfb

使用

ls -l /tmp/.X*lock
可以查看当前启动了那些xwindowQ如果发现X0Q可?.0已经被用了

使用两个命oQ?br />   Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-
   Xvfb :1 -screen 0 800x600x16 & 启动Xwindows的虚拟设?br />   export DISPLAY=localhost:1.0 配置本地环境
   Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-Q-

参考:http://javatechniques.com/blog/linux-x11-libraries-for-headless-mode/



在\?.. 2012-01-19 12:01 发表评论
]]>
APK文g修改及编译打包备?/title><link>http://www.aygfsteel.com/midea0978/archive/2012/01/04/367848.html</link><dc:creator>在\?..</dc:creator><author>在\?..</author><pubDate>Wed, 04 Jan 2012 08:07:00 GMT</pubDate><guid>http://www.aygfsteel.com/midea0978/archive/2012/01/04/367848.html</guid><wfw:comment>http://www.aygfsteel.com/midea0978/comments/367848.html</wfw:comment><comments>http://www.aygfsteel.com/midea0978/archive/2012/01/04/367848.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.aygfsteel.com/midea0978/comments/commentRss/367848.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/midea0978/services/trackbacks/367848.html</trackback:ping><description><![CDATA[1、用apktool反编?br />apktool d [file.apk] [path]<br />2、根据需要修攚w|文件、smali文gQ如果需要反~译成jar文gQ可以用dex2jarQ然后用jd-gui查看代码<br />3、重新编译成apk文g<br />apktool b [path] file.apk<br />4、签?br />使用JDK自带工具keytool创徏keystore<br />c:\>keytool -genkey -alias android.keystore -keyalg RSA -validity 10000 -keystore mystore.keystore <br />其中validity 为有效期天数,q里创徏的keystore文g也可以供eclipse打包apk时用,注意C密码?br />使用JDK自带工具jarsigner{֐apk文gQ需要输入keystore的密?br />c:\>jarsigner -verbose -keystore mystore.jks -signedjar [{֐后的文g.jar] [需要签名的文g.apk] my<br />5、安装到手机上面试<br />adb -d install -r signed-file.apk<br /><br /><img src ="http://www.aygfsteel.com/midea0978/aggbug/367848.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/midea0978/" target="_blank">在\?..</a> 2012-01-04 16:07 <a href="http://www.aygfsteel.com/midea0978/archive/2012/01/04/367848.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>smali文g语法参?/title><link>http://www.aygfsteel.com/midea0978/archive/2012/01/04/367847.html</link><dc:creator>在\?..</dc:creator><author>在\?..</author><pubDate>Wed, 04 Jan 2012 07:59:00 GMT</pubDate><guid>http://www.aygfsteel.com/midea0978/archive/2012/01/04/367847.html</guid><wfw:comment>http://www.aygfsteel.com/midea0978/comments/367847.html</wfw:comment><comments>http://www.aygfsteel.com/midea0978/archive/2012/01/04/367847.html#Feedback</comments><slash:comments>2</slash:comments><wfw:commentRss>http://www.aygfsteel.com/midea0978/comments/commentRss/367847.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/midea0978/services/trackbacks/367847.html</trackback:ping><description><![CDATA[     摘要: 转蝲Qhttp://pallergabor.uw.hu/androidblog/dalvik_opcodes.html   Dalvik opcodes Author: Gabor PallerVx values in the table denote a Dalvik register. Depending on the instruction, 16, 256 or 64k r...  <a href='http://www.aygfsteel.com/midea0978/archive/2012/01/04/367847.html'>阅读全文</a><img src ="http://www.aygfsteel.com/midea0978/aggbug/367847.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/midea0978/" target="_blank">在\?..</a> 2012-01-04 15:59 <a href="http://www.aygfsteel.com/midea0978/archive/2012/01/04/367847.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>改用LiveWriter写日志看?/title><link>http://www.aygfsteel.com/midea0978/archive/2011/07/30/355378.html</link><dc:creator>在\?..</dc:creator><author>在\?..</author><pubDate>Sat, 30 Jul 2011 01:31:00 GMT</pubDate><guid>http://www.aygfsteel.com/midea0978/archive/2011/07/30/355378.html</guid><wfw:comment>http://www.aygfsteel.com/midea0978/comments/355378.html</wfw:comment><comments>http://www.aygfsteel.com/midea0978/archive/2011/07/30/355378.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.aygfsteel.com/midea0978/comments/commentRss/355378.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/midea0978/services/trackbacks/355378.html</trackback:ping><description><![CDATA[<p>试发帖Q直接粘贴图片看看效果如何!</p> <p><a href="http://www.aygfsteel.com/images/blogjava_net/midea0978/Windows-Live-Writer/230dc2096897_8528/image_2.png"><img style="background-image: none; border-right-width: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px; padding-top: 0px" title="image" border="0" alt="image" src="http://www.aygfsteel.com/images/blogjava_net/midea0978/Windows-Live-Writer/230dc2096897_8528/image_thumb.png" width="244" height="68"></a></p> <img src ="http://www.aygfsteel.com/midea0978/aggbug/355378.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/midea0978/" target="_blank">在\?..</a> 2011-07-30 09:31 <a href="http://www.aygfsteel.com/midea0978/archive/2011/07/30/355378.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>单独使用jboss的jndi providerhttp://www.aygfsteel.com/midea0978/archive/2011/06/20/352647.html在\?..在\?..Mon, 20 Jun 2011 03:23:00 GMThttp://www.aygfsteel.com/midea0978/archive/2011/06/20/352647.htmlhttp://www.aygfsteel.com/midea0978/comments/352647.htmlhttp://www.aygfsteel.com/midea0978/archive/2011/06/20/352647.html#Feedback0http://www.aygfsteel.com/midea0978/comments/commentRss/352647.htmlhttp://www.aygfsteel.com/midea0978/services/trackbacks/352647.html通过下面方式可以发布jboss的naming服务
<?xml version="1.0" encoding="UTF-8"?>
<server>
  
<mbean code="org.jboss.naming.NamingService" 
         name
="DefaultDomain:service=Naming">
    
<attribute name="Port">1099</attribute>
  
</mbean>
</server>


同时也可以独立用,你需?font face="Courier New">jnpserver.jar ?font face="Courier New">log4j.jar 文gQ?
 # Use a ConsoleAppender -- write log data to standard out
log4j.rootLogger
=DEBUG, A1
log4j.appender.A1
=org.apache.log4j.ConsoleAppender
log4j.appender.A1.layout
=org.apache.log4j.PatternLayout
log4j.appender.A1.layout.ConversionPattern
=%-4r [%t] %-5p %c %x - %m%n


配套的log4j配置文gQ用下面命令启动java org.jnp.server.MainQ启动之后,jndi客户端需?font face="Courier New">jnp-client.jar文g来连?br />java.naming.provider.url=jnphost.mycompany.com:1099
java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
java.naming.factory.url.pkgs=org.jboss.naming
q接参数如上





在\?.. 2011-06-20 11:23 发表评论
]]>
intellij idea使用tomcat开发时自动部vjndi数据?/title><link>http://www.aygfsteel.com/midea0978/archive/2011/01/02/342165.html</link><dc:creator>在\?..</dc:creator><author>在\?..</author><pubDate>Sun, 02 Jan 2011 09:36:00 GMT</pubDate><guid>http://www.aygfsteel.com/midea0978/archive/2011/01/02/342165.html</guid><wfw:comment>http://www.aygfsteel.com/midea0978/comments/342165.html</wfw:comment><comments>http://www.aygfsteel.com/midea0978/archive/2011/01/02/342165.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.aygfsteel.com/midea0978/comments/commentRss/342165.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/midea0978/services/trackbacks/342165.html</trackback:ping><description><![CDATA[     摘要: 通常Q如果需要在应用中用tomcat的jndi数据源,需要修改context配置Q例?<?xml version="1.0" encoding="UTF-8"?> <Context path="/app" docBase="E:\appweb">   <Resource name="jnd...  <a href='http://www.aygfsteel.com/midea0978/archive/2011/01/02/342165.html'>阅读全文</a><img src ="http://www.aygfsteel.com/midea0978/aggbug/342165.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/midea0978/" target="_blank">在\?..</a> 2011-01-02 17:36 <a href="http://www.aygfsteel.com/midea0978/archive/2011/01/02/342165.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>JMXq程理tomcat或weblogichttp://www.aygfsteel.com/midea0978/archive/2011/01/02/342164.html在\?..在\?..Sun, 02 Jan 2011 09:14:00 GMThttp://www.aygfsteel.com/midea0978/archive/2011/01/02/342164.htmlhttp://www.aygfsteel.com/midea0978/comments/342164.htmlhttp://www.aygfsteel.com/midea0978/archive/2011/01/02/342164.html#Feedback0http://www.aygfsteel.com/midea0978/comments/commentRss/342164.htmlhttp://www.aygfsteel.com/midea0978/services/trackbacks/342164.html
-Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=8888 -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false



在\?.. 2011-01-02 17:14 发表评论
]]>
修改驱动解决SqlRowSet的Invalid scale size. Cannot be less than zero异常的处理办?/title><link>http://www.aygfsteel.com/midea0978/archive/2009/10/09/297584.html</link><dc:creator>在\?..</dc:creator><author>在\?..</author><pubDate>Fri, 09 Oct 2009 09:18:00 GMT</pubDate><guid>http://www.aygfsteel.com/midea0978/archive/2009/10/09/297584.html</guid><wfw:comment>http://www.aygfsteel.com/midea0978/comments/297584.html</wfw:comment><comments>http://www.aygfsteel.com/midea0978/archive/2009/10/09/297584.html#Feedback</comments><slash:comments>1</slash:comments><wfw:commentRss>http://www.aygfsteel.com/midea0978/comments/commentRss/297584.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/midea0978/services/trackbacks/297584.html</trackback:ping><description><![CDATA[参考:http://blog.csdn.net/horsefaced/archive/2007/08/16/1746888.aspx<br /> <br /> q个异常源自于oracle驱动面对一个数值型的返回字D|Q在得到指定的字D小数点双的数值数量时QGets the designated column's number of digits to right of the decimal point.q个是原文)Q居然会q回-127Q而oracle本n的cacheRowSet实现不允许这U情况出玎ͼ于是׃报标题所说的异常?br /> <br /> 对于一般的做法Q需要修改很多地方,包括ResultSet的decoratec,q有Spring的SqlRowSetResultSetExtractor <br /> <br /> 所谓头痛医_脚痛医脚Q这里提供一U方法直接从oracle jdbc驱动入手Q彻底从源头上修Ҏ(gu)该问题:<br /> 反编译ojdbc14.jar(Oracle 9i驱动Z)<br /> <p>package oracle.jdbc.driver;</p> <p>public class OracleResultSetMetaData</p> <br /> 目标Ҏ(gu)Q?br /> public int getScale(int paramInt)<br />     throws SQLException<br />   {<br />     int i = getValidColumnIndex(paramInt);<br />     return this.statement.getDBDescription()[i].scale;<br />   }<br /> <br /> 使用javassist~写一D代码:<br /> <div style="border-bottom: #cccccc 1px solid; border-left: #cccccc 1px solid; padding-bottom: 4px; background-color: #eeeeee; padding-left: 4px; width: 98%; padding-right: 5px; font-size: 13px; word-break: break-all; border-top: #cccccc 1px solid; border-right: #cccccc 1px solid; padding-top: 4px"><img id="Codehighlighter1_34_792_Open_Image" onclick="this.style.display='none'; Codehighlighter1_34_792_Open_Text.style.display='none'; Codehighlighter1_34_792_Closed_Image.style.display='inline'; Codehighlighter1_34_792_Closed_Text.style.display='inline';" align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_34_792_Closed_Image" onclick="this.style.display='none'; Codehighlighter1_34_792_Closed_Text.style.display='none'; Codehighlighter1_34_792_Open_Image.style.display='inline'; Codehighlighter1_34_792_Open_Text.style.display='inline';" align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/ContractedBlock.gif" alt="" /><span style="color: #000000"> </span><span style="color: #0000ff">public</span><span style="color: #000000">  </span><span style="color: #0000ff">void</span><span style="color: #000000"> crackOracleDriver() </span><span style="border-bottom: #808080 1px solid; border-left: #808080 1px solid; background-color: #ffffff; display: none; border-top: #808080 1px solid; border-right: #808080 1px solid" id="Codehighlighter1_34_792_Closed_Text"><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_34_792_Open_Text"><span style="color: #000000">{<br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" alt="" />        ClassPool pool </span><span style="color: #000000">=</span><span style="color: #000000"> ClassPool.getDefault();<br /> <img id="Codehighlighter1_97_721_Open_Image" onclick="this.style.display='none'; Codehighlighter1_97_721_Open_Text.style.display='none'; Codehighlighter1_97_721_Closed_Image.style.display='inline'; Codehighlighter1_97_721_Closed_Text.style.display='inline';" align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_97_721_Closed_Image" onclick="this.style.display='none'; Codehighlighter1_97_721_Closed_Text.style.display='none'; Codehighlighter1_97_721_Open_Image.style.display='inline'; Codehighlighter1_97_721_Open_Text.style.display='inline';" align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/ContractedSubBlock.gif" alt="" />        </span><span style="color: #0000ff">try</span><span style="color: #000000"> </span><span style="border-bottom: #808080 1px solid; border-left: #808080 1px solid; background-color: #ffffff; display: none; border-top: #808080 1px solid; border-right: #808080 1px solid" id="Codehighlighter1_97_721_Closed_Text"><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_97_721_Open_Text"><span style="color: #000000">{<br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" alt="" />            pool.insertClassPath(</span><span style="color: #000000">"</span><span style="color: #000000">E:\\allproject\\bpmtrans\\lib\\ojdbc14.jar</span><span style="color: #000000">"</span><span style="color: #000000">);<br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" alt="" />            CtClass cc </span><span style="color: #000000">=</span><span style="color: #000000"> pool.get(</span><span style="color: #000000">"</span><span style="color: #000000">oracle.jdbc.driver.OracleResultSetMetaData</span><span style="color: #000000">"</span><span style="color: #000000">);<br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" alt="" />            System.out.println(cc);<br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" alt="" />            CtClass[] param </span><span style="color: #000000">=</span><span style="color: #000000"> </span><span style="color: #0000ff">new</span><span style="color: #000000"> CtClass[</span><span style="color: #000000">1</span><span style="color: #000000">] ;<br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" alt="" />            param[</span><span style="color: #000000">0</span><span style="color: #000000">]</span><span style="color: #000000">=</span><span style="color: #000000">pool.get(</span><span style="color: #000000">"</span><span style="color: #000000">int</span><span style="color: #000000">"</span><span style="color: #000000">);<br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" alt="" />            CtMethod a </span><span style="color: #000000">=</span><span style="color: #000000"> cc.getDeclaredMethod(</span><span style="color: #000000">"</span><span style="color: #000000">getScale</span><span style="color: #000000">"</span><span style="color: #000000">,param);<br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" alt="" />            System.out.println(a);<br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" alt="" />            a.setBody(</span><span style="color: #000000">"</span><span style="color: #000000">{int i = getValidColumnIndex($1);\n</span><span style="color: #000000">"</span><span style="color: #000000"> </span><span style="color: #000000">+</span><span style="color: #000000"><br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" alt="" />                    </span><span style="color: #000000">"</span><span style="color: #000000">    int res=statement.getDBDescription()[i].scale;\n</span><span style="color: #000000">"</span><span style="color: #000000"> </span><span style="color: #000000">+</span><span style="color: #000000"><br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" alt="" />                    </span><span style="color: #000000">"</span><span style="color: #000000">return res<0?0:res; }</span><span style="color: #000000">"</span><span style="color: #000000">);<br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" alt="" />            cc.writeFile(</span><span style="color: #000000">"</span><span style="color: #000000">c:\\</span><span style="color: #000000">"</span><span style="color: #000000">);<br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" alt="" /><br /> <img id="Codehighlighter1_743_786_Open_Image" onclick="this.style.display='none'; Codehighlighter1_743_786_Open_Text.style.display='none'; Codehighlighter1_743_786_Closed_Image.style.display='inline'; Codehighlighter1_743_786_Closed_Text.style.display='inline';" align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedSubBlockStart.gif" alt="" /><img style="display: none" id="Codehighlighter1_743_786_Closed_Image" onclick="this.style.display='none'; Codehighlighter1_743_786_Closed_Text.style.display='none'; Codehighlighter1_743_786_Open_Image.style.display='inline'; Codehighlighter1_743_786_Open_Text.style.display='inline';" align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/ContractedSubBlock.gif" alt="" />        }</span></span><span style="color: #000000"> </span><span style="color: #0000ff">catch</span><span style="color: #000000"> (Exception e) </span><span style="border-bottom: #808080 1px solid; border-left: #808080 1px solid; background-color: #ffffff; display: none; border-top: #808080 1px solid; border-right: #808080 1px solid" id="Codehighlighter1_743_786_Closed_Text"><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_743_786_Open_Text"><span style="color: #000000">{<br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" alt="" />            e.printStackTrace();<br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedSubBlockEnd.gif" alt="" />        }</span></span><span style="color: #000000"><br /> <img align="top" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockEnd.gif" alt="" />    }</span></span></div> <br /> 生成的class|换原来的classQ大功告成!<br /> <br /> q个所谓的_ֺQ一般来_修改了应该没有多大问题的 <img src ="http://www.aygfsteel.com/midea0978/aggbug/297584.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/midea0978/" target="_blank">在\?..</a> 2009-10-09 17:18 <a href="http://www.aygfsteel.com/midea0978/archive/2009/10/09/297584.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>使用openssl生成自签名证书、配|SSLhttp://www.aygfsteel.com/midea0978/archive/2008/07/18/215740.html在\?..在\?..Fri, 18 Jul 2008 04:40:00 GMThttp://www.aygfsteel.com/midea0978/archive/2008/07/18/215740.htmlhttp://www.aygfsteel.com/midea0978/comments/215740.htmlhttp://www.aygfsteel.com/midea0978/archive/2008/07/18/215740.html#Feedback3http://www.aygfsteel.com/midea0978/comments/commentRss/215740.htmlhttp://www.aygfsteel.com/midea0978/services/trackbacks/215740.html首先Q下载openssl安装Qwindows环境?a >http://www.openssl.org/related/binaries.html下蝲?br /> 我这里测试下载的版本是:http://www.slproweb.com/download/Win32OpenSSL-0_9_8h.exe
安装完成之后Q修改bin目录下面的openssl.cfg为openssl.cnfQ在h证书旉要用到这个配|文Ӟ生成证书Qؓ了方便,~写了下面的批处理文Ӟ供参考:

@echo off
echo 
1.CA 创徏一?nbsp;RSA U用密钥
openssl genrsa 
-out %1.key 1024 

echo.
echo 
2.利用 CA ?nbsp;RSA 密钥创徏一个自{v?nbsp;CA 证书QX.509l构Q?br /> openssl req -new -x509 -days 36500 -key %1.key -out %1.crt -subj /C=CN/ST=GuangDong/L=GuangZhou/O=SinoTech/OU=CA-SinoTech

echo.
echo 
3.CA 创徏一?nbsp;服务?nbsp;RSA U用密钥
openssl genrsa 
-out %2.key 1024 
echo.

echo 
4.创徏服务端签|请?nbsp;CSR
openssl req 
-new -key %2.key -out %2.csr -subj "/C=CN/ST=GuangDong/L=GuangZhou/O=SinoTech/OU=Serv-SinoTech/CN=SinoTech Weblogic Server"

echo.
echo 
5.{v证书
rem 准备一些默认文件、目录,否则q行时会报错
if exist "%cd%\newcerts" goto got1
md newcerts
:got1

if exist "%cd%\index.txt" goto got2
echo tmp 
>_tmp
del _tmp 
>index.txt
:got2

if exist "%cd%\serial" goto got3
echo AD 
>serial
:got3

openssl ca 
-in %2.csr -out %2.crt -cert %1.crt -keyfile %1.key 
echo.
echo 处理完成
pause

q行批处?br /> genca.cmd [CA证书名] [服务端证书名]
例如genca.cmd ca server

通过上面命oQ会生成server.crt,server.key,然后上面参数加到tomcat的配|中可以用SSLq接方式讉K|站应用?br />
<Connector 
           
port="8443" minSpareThreads="5" maxSpareThreads="75"
           enableLookups
="true" disableUploadTimeout="true" 
           acceptCount
="100"  maxThreads="200"
           scheme
="https" secure="true" SSLEnabled="true"
           SSLCertificateFile
="C:\apache-tomcat-6.0.16\conf\server.crt" 
           SSLCertificateKeyFile
="C:\apache-tomcat-6.0.16\conf\server.key"
           clientAuth
="false" sslProtocol="TLS"/>


在\?.. 2008-07-18 12:40 发表评论
]]>
Oracle JDBC驱动与时间不见了的问?/title><link>http://www.aygfsteel.com/midea0978/archive/2008/06/13/207655.html</link><dc:creator>在\?..</dc:creator><author>在\?..</author><pubDate>Fri, 13 Jun 2008 06:19:00 GMT</pubDate><guid>http://www.aygfsteel.com/midea0978/archive/2008/06/13/207655.html</guid><wfw:comment>http://www.aygfsteel.com/midea0978/comments/207655.html</wfw:comment><comments>http://www.aygfsteel.com/midea0978/archive/2008/06/13/207655.html#Feedback</comments><slash:comments>8</slash:comments><wfw:commentRss>http://www.aygfsteel.com/midea0978/comments/commentRss/207655.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/midea0978/services/trackbacks/207655.html</trackback:ping><description><![CDATA[<span style="font-size: 10pt">一般的数据库中QDATE字段仅仅表示日期Q不包括日期信息Q而Oracle数据库中的DATE数据cd是包括日期、时间的Q对于不同的Oracle jdbc驱动版本Q对于该问题的处理都有些区别Q如果你使用9i或?1g<br /> 的驱动程序,可能不会发现什么困惑,不幸的话Q你使用Oracle10g的JDBC驱动Q问题就来了Q?strong style="color: #ff0000">你会发现旉不见?/strong>Q?br /> 看下面的E序<br /> <strong>• 表结构如?/strong><br /> create table t_test(<br /> id int,<br /> date1 date,<br /> date2 timestamp,<br /> primary key(id)<br /> )<br /> <br /> <div style="border-right: #cccccc 1px solid; padding-right: 5px; border-top: #cccccc 1px solid; padding-left: 4px; font-size: 13px; padding-bottom: 4px; border-left: #cccccc 1px solid; width: 98%; word-break: break-all; padding-top: 4px; border-bottom: #cccccc 1px solid; background-color: #eeeeee"><span style="color: #008080"> 1</span><img id="Codehighlighter1_4_552_Open_Image" onclick="this.style.display='none'; Codehighlighter1_4_552_Open_Text.style.display='none'; Codehighlighter1_4_552_Closed_Image.style.display='inline'; Codehighlighter1_4_552_Closed_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockStart.gif" align="top" alt="" /><img id="Codehighlighter1_4_552_Closed_Image" style="display: none" onclick="this.style.display='none'; Codehighlighter1_4_552_Closed_Text.style.display='none'; Codehighlighter1_4_552_Open_Image.style.display='inline'; Codehighlighter1_4_552_Open_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ContractedBlock.gif" align="top" alt="" /><span style="color: #0000ff">try</span><span style="color: #000000"> </span><span id="Codehighlighter1_4_552_Closed_Text" style="border-right: #808080 1px solid; border-top: #808080 1px solid; display: none; border-left: #808080 1px solid; border-bottom: #808080 1px solid; background-color: #ffffff"><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_4_552_Open_Text"><span style="color: #000000">{<br /> </span><span style="color: #008080"> 2</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            Class.forName(</span><span style="color: #000000">"</span><span style="color: #000000">oracle.jdbc.OracleDriver</span><span style="color: #000000">"</span><span style="color: #000000">);<br /> </span><span style="color: #008080"> 3</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            java.sql.Connection connection1 </span><span style="color: #000000">=</span><span style="color: #000000"> DriverManager.getConnection(</span><span style="color: #000000">"</span><span style="color: #000000">jdbc:oracle:thin:@192.168.8.200:1521:cdb</span><span style="color: #000000">"</span><span style="color: #000000">, </span><span style="color: #000000">"</span><span style="color: #000000">sysusr</span><span style="color: #000000">"</span><span style="color: #000000">, </span><span style="color: #000000">"</span><span style="color: #000000">sys</span><span style="color: #000000">"</span><span style="color: #000000">);<br /> </span><span style="color: #008080"> 4</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            System.out.println(connection1);<br /> </span><span style="color: #008080"> 5</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            System.out.println(connection1.getMetaData().getDriverName()</span><span style="color: #000000">+</span><span style="color: #000000">"</span><span style="color: #000000"> </span><span style="color: #000000">"</span><span style="color: #000000">+</span><span style="color: #000000">connection1.getMetaData().getDriverVersion());<br /> </span><span style="color: #008080"> 6</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            ResultSet rs </span><span style="color: #000000">=</span><span style="color: #000000"> connection1.createStatement().executeQuery(</span><span style="color: #000000">"</span><span style="color: #000000">select date1,date2 from t_test</span><span style="color: #000000">"</span><span style="color: #000000">);<br /> </span><span style="color: #008080"> 7</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            rs.next();<br /> </span><span style="color: #008080"> 8</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />             printInfo(rs,</span><span style="color: #000000">1</span><span style="color: #000000">);<br /> </span><span style="color: #008080"> 9</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            printInfo(rs,</span><span style="color: #000000">2</span><span style="color: #000000">);<br /> </span><span style="color: #008080">10</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockEnd.gif" align="top" alt="" />        }</span></span><span style="color: #000000"><br /> </span><span style="color: #008080">11</span><span style="color: #000000"><img id="Codehighlighter1_591_643_Open_Image" onclick="this.style.display='none'; Codehighlighter1_591_643_Open_Text.style.display='none'; Codehighlighter1_591_643_Closed_Image.style.display='inline'; Codehighlighter1_591_643_Closed_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockStart.gif" align="top" alt="" /><img id="Codehighlighter1_591_643_Closed_Image" style="display: none" onclick="this.style.display='none'; Codehighlighter1_591_643_Closed_Text.style.display='none'; Codehighlighter1_591_643_Open_Image.style.display='inline'; Codehighlighter1_591_643_Open_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ContractedBlock.gif" align="top" alt="" />        </span><span style="color: #0000ff">catch</span><span style="color: #000000"> (Exception exception1) </span><span id="Codehighlighter1_591_643_Closed_Text" style="border-right: #808080 1px solid; border-top: #808080 1px solid; display: none; border-left: #808080 1px solid; border-bottom: #808080 1px solid; background-color: #ffffff"><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_591_643_Open_Text"><span style="color: #000000">{<br /> </span><span style="color: #008080">12</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            exception1.printStackTrace();<br /> </span><span style="color: #008080">13</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockEnd.gif" align="top" alt="" />        }</span></span><span style="color: #000000"><br /> </span><span style="color: #008080">14</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> </span><span style="color: #008080">15</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> </span><span style="color: #008080">16</span><span style="color: #000000"><img id="Codehighlighter1_715_926_Open_Image" onclick="this.style.display='none'; Codehighlighter1_715_926_Open_Text.style.display='none'; Codehighlighter1_715_926_Closed_Image.style.display='inline'; Codehighlighter1_715_926_Closed_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockStart.gif" align="top" alt="" /><img id="Codehighlighter1_715_926_Closed_Image" style="display: none" onclick="this.style.display='none'; Codehighlighter1_715_926_Closed_Text.style.display='none'; Codehighlighter1_715_926_Open_Image.style.display='inline'; Codehighlighter1_715_926_Open_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ContractedBlock.gif" align="top" alt="" /></span><span style="color: #0000ff">public</span><span style="color: #000000"> </span><span style="color: #0000ff">static</span><span style="color: #000000"> </span><span style="color: #0000ff">void</span><span style="color: #000000"> printInfo(ResultSet rs,</span><span style="color: #0000ff">int</span><span style="color: #000000"> i) </span><span style="color: #0000ff">throws</span><span style="color: #000000"> SQLException</span><span id="Codehighlighter1_715_926_Closed_Text" style="border-right: #808080 1px solid; border-top: #808080 1px solid; display: none; border-left: #808080 1px solid; border-bottom: #808080 1px solid; background-color: #ffffff"><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_715_926_Open_Text"><span style="color: #000000">{<br /> </span><span style="color: #008080">17</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />        ResultSetMetaData meta</span><span style="color: #000000">=</span><span style="color: #000000">rs.getMetaData();<br /> </span><span style="color: #008080">18</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />        System.out.printf(</span><span style="color: #000000">"</span><span style="color: #000000">Colname=%s,Type=%s,TypeName=%s,val=[%s];\n</span><span style="color: #000000">"</span><span style="color: #000000">,meta.getColumnName(i),meta.getColumnType(i),meta.getColumnTypeName(i),rs.getObject(i).toString());<br /> </span><span style="color: #008080">19</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockEnd.gif" align="top" alt="" />    }</span></span></div> <br /> • 如果使用9i或?1g的驱动连接数据库Q返回结果如下:<br /> <strong>9i数据库JDBC</strong><br /> oracle.jdbc.driver.OracleConnection@16930e2<br /> Oracle JDBC driver 9.2.0.8.0<br /> Colname=DATE1,Type=91,TypeName=DATE,val=[<span style="color: red">2008-06-13 13:48:21.0</span>];<br /> Colname=DATE2,Type=93,TypeName=TIMESTAMP,val=[oracle.sql.TIMESTAMP@18d107f];<br /> <br /> <strong>11g数据库JDBC<br /> </strong>oracle.jdbc.driver.T4CConnection@a61164<br /> Oracle JDBC driver 11.1.0.6.0-Production+<br /> Colname=DATE1,Type=93,TypeName=DATE,val=[<span style="color: red">2008-06-13 13:48:21.0];</span><br /> Colname=DATE2,Type=93,TypeName=TIMESTAMP,val=[oracle.sql.TIMESTAMP@c4aad3];<br /> <br /> 如果使用<strong>10g JDBC</strong>驱动Q结果如下:<br /> oracle.jdbc.driver.T4CConnection@1bac748<br /> Oracle JDBC driver 10.2.0.2.0<br /> Colname=DATE1,Type=91,TypeName=DATE,val=[<span style="color: red">2008-06-13</span>];<br /> Colname=DATE2,Type=93,TypeName=TIMESTAMP,val=[oracle.sql.TIMESTAMP@b8df17];<br /> <br /> l果是让人困惑,<span style="color: red">旉怎么不见了?<br /> <br /> <span style="color: #000000">对于该问题,在Oracle的JDBC FAQ中有提到解决办法Q?br /> <div style="border-right: #cccccc 1px solid; padding-right: 5px; border-top: #cccccc 1px solid; padding-left: 4px; font-size: 13px; padding-bottom: 4px; border-left: #cccccc 1px solid; width: 98%; word-break: break-all; padding-top: 4px; border-bottom: #cccccc 1px solid; background-color: #eeeeee"><img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><span style="color: #000000">Prior to 9.2, the Oracle JDBC drivers mapped the DATE SQL type to java.sql.Timestamp. This made a certain amount of sense because the Oracle DATE SQL type contains both date and time information as does java.sql.Timestamp. The more obvious mapping to java.sql.Date was somewhat problematic as java.sql.Date does not include time information. It was also the case that the RDBMS did not support the TIMESTAMP SQL type, so there was no problem with mapping DATE to Timestamp. <br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />In 9.2 TIMESTAMP support was added to the RDBMS. The difference between DATE and TIMESTAMP is that TIMESTAMP includes nanoseconds and DATE does not. So, beginning in 9.2, DATE is mapped to Date and TIMESTAMP is mapped to Timestamp. Unfortunately if you were relying on DATE values to contain time information, there is a problem. <br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />There are several ways to address this problem: <br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />Alter your tables to use TIMESTAMP instead of DATE. This is probably rarely possible, but it is the best solution when it is. <br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />Alter your application to use defineColumnType to define the columns as TIMESTAMP rather than DATE. There are problems with this because you really don't want to use defineColumnType unless you have to (see What is defineColumnType and when should I use it?). <br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />Alter you application to use getTimestamp rather than getObject. This is a good solution when possible, however many applications contain generic code that relies on getObject, so it isn't always possible. <br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />Set the V8Compatible connection property. This tells the JDBC drivers to use the old mapping rather than the new one. You can set this flag either as a connection property or a system property. You set the connection property by adding it to the java.util.Properties object passed to DriverManager.getConnection or to OracleDataSource.setConnectionProperties. You set the system property by including a -D option in your java command line. <br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  java -Doracle.jdbc.V8Compatible="true" MyApp<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /></span></div> <br /> 参照上面的解释,修改代码如下可以解决10g JDBC驱动的问题:<br /> <div style="border-right: #cccccc 1px solid; padding-right: 5px; border-top: #cccccc 1px solid; padding-left: 4px; font-size: 13px; padding-bottom: 4px; border-left: #cccccc 1px solid; width: 98%; word-break: break-all; padding-top: 4px; border-bottom: #cccccc 1px solid; background-color: #eeeeee"><img id="Codehighlighter1_4_711_Open_Image" onclick="this.style.display='none'; Codehighlighter1_4_711_Open_Text.style.display='none'; Codehighlighter1_4_711_Closed_Image.style.display='inline'; Codehighlighter1_4_711_Closed_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockStart.gif" align="top" alt="" /><img id="Codehighlighter1_4_711_Closed_Image" style="display: none" onclick="this.style.display='none'; Codehighlighter1_4_711_Closed_Text.style.display='none'; Codehighlighter1_4_711_Open_Image.style.display='inline'; Codehighlighter1_4_711_Open_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ContractedBlock.gif" align="top" alt="" /><span style="color: #0000ff">try</span><span style="color: #000000"> </span><span id="Codehighlighter1_4_711_Closed_Text" style="border-right: #808080 1px solid; border-top: #808080 1px solid; display: none; border-left: #808080 1px solid; border-bottom: #808080 1px solid; background-color: #ffffff"><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_4_711_Open_Text"><span style="color: #000000">{<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            Class.forName(</span><span style="color: #000000">"</span><span style="color: #000000">oracle.jdbc.OracleDriver</span><span style="color: #000000">"</span><span style="color: #000000">);<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            Properties prop</span><span style="color: #000000">=</span><span style="color: #0000ff">new</span><span style="color: #000000"> Properties();<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            prop.setProperty(</span><span style="color: #000000">"</span><span style="color: #000000">user</span><span style="color: #000000">"</span><span style="color: #000000">,</span><span style="color: #000000">"</span><span style="color: #000000">sysuser</span><span style="color: #000000">"</span><span style="color: #000000">);<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            prop.setProperty(</span><span style="color: #000000">"</span><span style="color: #000000">password</span><span style="color: #000000">"</span><span style="color: #000000">,</span><span style="color: #000000">"</span><span style="color: #000000">sys</span><span style="color: #000000">"</span><span style="color: #000000">);<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            <strong>prop.setProperty(</strong></span><strong><span style="color: #000000">"</span><span style="color: #000000">oracle.jdbc.V8Compatible</span><span style="color: #000000">"</span><span style="color: #000000">,</span><span style="color: #000000">"</span><span style="color: #000000">true</span><span style="color: #000000">"</span></strong><strong><span style="color: #000000">);<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            java.sql.Connection connection1 </span><span style="color: #000000">=</span><span style="color: #000000"> DriverManager.getConnection(</span><span style="color: #000000">"</span><span style="color: #000000">jdbc:oracle:thin:@192.168.8.200:1521:cdb</span><span style="color: #000000">"</span></strong><span style="color: #000000"><strong>, prop);</strong><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            System.out.println(connection1);<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            System.out.println(connection1.getMetaData().getDriverName()</span><span style="color: #000000">+</span><span style="color: #000000">"</span><span style="color: #000000"> </span><span style="color: #000000">"</span><span style="color: #000000">+</span><span style="color: #000000">connection1.getMetaData().getDriverVersion());<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            ResultSet rs </span><span style="color: #000000">=</span><span style="color: #000000"> connection1.createStatement().executeQuery(</span><span style="color: #000000">"</span><span style="color: #000000">select date1,date2 from t_test</span><span style="color: #000000">"</span><span style="color: #000000">);<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            rs.next();<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            printInfo(rs,</span><span style="color: #000000">1</span><span style="color: #000000">);<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            printInfo(rs,</span><span style="color: #000000">2</span><span style="color: #000000">);<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockEnd.gif" align="top" alt="" />        }</span></span><span style="color: #000000"><br /> <img id="Codehighlighter1_750_802_Open_Image" onclick="this.style.display='none'; Codehighlighter1_750_802_Open_Text.style.display='none'; Codehighlighter1_750_802_Closed_Image.style.display='inline'; Codehighlighter1_750_802_Closed_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockStart.gif" align="top" alt="" /><img id="Codehighlighter1_750_802_Closed_Image" style="display: none" onclick="this.style.display='none'; Codehighlighter1_750_802_Closed_Text.style.display='none'; Codehighlighter1_750_802_Open_Image.style.display='inline'; Codehighlighter1_750_802_Open_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ContractedBlock.gif" align="top" alt="" />        </span><span style="color: #0000ff">catch</span><span style="color: #000000"> (Exception exception1) </span><span id="Codehighlighter1_750_802_Closed_Text" style="border-right: #808080 1px solid; border-top: #808080 1px solid; display: none; border-left: #808080 1px solid; border-bottom: #808080 1px solid; background-color: #ffffff"><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_750_802_Open_Text"><span style="color: #000000">{<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            exception1.printStackTrace();<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockEnd.gif" align="top" alt="" />        }</span></span></div> </span></span></span><span style="font-size: 10pt">或者在pȝ变量中用参?Doracle.jdbc.V8Compatible="true"Q例?br /> java -Doracle.jdbc.V8Compatible="true" MyApp<br /> </span><br /> <span style="font-size: 10pt"><strong>l果如下Q?br /> </strong>oracle.jdbc.driver.T4CConnection@9664a1<br /> Oracle JDBC driver 10.2.0.2.0<br /> Colname=DATE1,Type=93,TypeName=DATE,val=[<span style="color: #ff0000">2008-06-13 13:48:21.0</span>];<br /> Colname=DATE2,Type=93,TypeName=DATE,val=[oracle.sql.TIMESTAMP@1172e08];<br /> </span> <img src ="http://www.aygfsteel.com/midea0978/aggbug/207655.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/midea0978/" target="_blank">在\?..</a> 2008-06-13 14:19 <a href="http://www.aygfsteel.com/midea0978/archive/2008/06/13/207655.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>Oracle整合BEAQWEBLogic的License可以免费下蝲?/title><link>http://www.aygfsteel.com/midea0978/archive/2008/06/05/205987.html</link><dc:creator>在\?..</dc:creator><author>在\?..</author><pubDate>Thu, 05 Jun 2008 02:46:00 GMT</pubDate><guid>http://www.aygfsteel.com/midea0978/archive/2008/06/05/205987.html</guid><wfw:comment>http://www.aygfsteel.com/midea0978/comments/205987.html</wfw:comment><comments>http://www.aygfsteel.com/midea0978/archive/2008/06/05/205987.html#Feedback</comments><slash:comments>7</slash:comments><wfw:commentRss>http://www.aygfsteel.com/midea0978/comments/commentRss/205987.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/midea0978/services/trackbacks/205987.html</trackback:ping><description><![CDATA[<span style="font-size: 10pt">众所周知QOracle的数据库、中间g都可以在|上自由下蝲Q没有Q何license注册码的限制?br /> 现在QOracle?5亿美元收购了BEAQ带来的最直接的好处是Q以前严g密的License文g现在都可以直接下载了。请看下面页面:<br /> </span><a ><span style="font-size: 10pt">http://commerce.bea.com/products/all_products.jsp#WL</span></a><br /> <br /> <a ><span style="font-size: 10pt">WebLogic Family License Keys</span></a><br /> <a ><span style="font-size: 10pt">http://download2.bea.com/pub/license/All%20Products/BEA_WebLogic.zip</span></a><br /> <br /> <a ><span style="font-size: 10pt">AquaLogic Family License Keys</span></a><br /> <a ><span style="font-size: 10pt">http://download2.bea.com/pub/license/All%20Products/BEA_AquaLogic.zip</span></a><br /> <br /> <span style="font-size: 10pt">摘录部分内容如下Q?br /> </span> <div style="border-right: #cccccc 1px solid; padding-right: 5px; border-top: #cccccc 1px solid; padding-left: 4px; font-size: 13px; padding-bottom: 4px; border-left: #cccccc 1px solid; width: 98%; word-break: break-all; padding-top: 4px; border-bottom: #cccccc 1px solid; background-color: #eeeeee"><span style="font-size: 10pt"><img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /></span><span style="color: #000000"><span style="font-size: 10pt">========================================<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />    = Read Me -- BEA WebLogic License Keys =<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />    ========================================<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />Some BEA products require multiple license keys for full functionality, or use a license key which is not intuitively identified as being for that product.<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />Please refer to the legend below to determine which license keys are required for the BEA products you own.<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />BEA WebLogic Server Products (Product, Version, License ID/file)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />================================================================<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />BEA WebLogic Server Advantage Edition    10.0 - 10.0mp1    LIC-WLSA10.txt<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                    9.2 - 9.2mp3    LIC-WLSA92.txt<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                    9.0        LIC-WLSA90.txt<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />BEA WebLogic Server Premium Edition    10.0 - 10.0mp1    LIC-WLSP10.txt<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                    9.2 - 9.2mp3    LIC-WLSP92.txt<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                    9.0        LIC-WLSP90.txt<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />BEA WebLogic Server SDK            10.x        LIC-WLSP10-DEV<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                    9.2        LIC-WLSP92-DEV<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                    9.1        LIC-WLSP91-DEV<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                    9.0        LIC-WLSP90-DEV<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />BEA WebLogic Server Premium for Linux s/390 and z/Series<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                    7.0sp1        LIC-WLS70-CLS-56<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />BEA WebLogic Server Mid-Market Edition    10.0 - 10.0mp1    LIC-WLS10-MME.txt<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                    9.2 - 9.2mp3    LIC-WLS92-MME.txt<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />    <br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />BEA WebLogic Platform Products (Product, Version, License ID/file)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />==================================================================<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                <br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />BEA WebLogic Platform            10.2 ISV    LIC-PLAT102-ISVED<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                    10.2        LIC-AUTONOMY<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                            LIC-PORT102<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                            <br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />LIC-WLI102<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                    9.2mp3 ISV    LIC-PLAT92-ISVED<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                    9.2 - 9.2mp3    LIC-PFRM92.txt<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                    8.1 - 8.1sp6    LIC-PFRM81-128.txt<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />                    7.0 - 7.0sp7    LIC-PFRM70-128.txt</span></span></div> <br /> <div style="border-right: #cccccc 1px solid; padding-right: 5px; border-top: #cccccc 1px solid; padding-left: 4px; font-size: 13px; padding-bottom: 4px; border-left: #cccccc 1px solid; width: 98%; word-break: break-all; padding-top: 4px; border-bottom: #cccccc 1px solid; background-color: #eeeeee"><img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><span style="color: #0000ff"><</span><span style="color: #800000">license<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />            </span><span style="color: #ff0000">component</span><span style="color: #0000ff">="WebLogic"</span><span style="color: #ff0000"><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />            cpus</span><span style="color: #0000ff">="unvalued"</span><span style="color: #ff0000"><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />            expiration</span><span style="color: #0000ff">="never"</span><span style="color: #ff0000"><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />            ip</span><span style="color: #0000ff">="any"</span><span style="color: #ff0000"><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />            licensee</span><span style="color: #0000ff">="Customer"</span><span style="color: #ff0000"><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />            serial</span><span style="color: #0000ff">="454493271161-2642447506228"</span><span style="color: #ff0000"><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />            type</span><span style="color: #0000ff">="RTK"</span><span style="color: #ff0000"><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />            units</span><span style="color: #0000ff">="unlimited"</span><span style="color: #ff0000"><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />            signature</span><span style="color: #0000ff">="MCwCFHRYQyBkRqhyayiKQBDxfTq/bWfYAhQj+RMMeDMVxjiYhBaXuHobbHe/JA=="</span><span style="color: #ff0000"><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        </span><span style="color: #0000ff">/></span></div> <br /> <span style="font-size: 10pt">呵呵Q都什么年代了Q?zhn)q在Google、baidu中搜?#8220;weblogic 破解”q样的关键字吗,用不着了。但是这q不意味着(zhn)可以免费用这些品,熟?zhn)Oracle的h都知道,如果(zhn)想在企业应用中部|这些品,(zhn)还是得付moneyQ?br /> </span> <img src ="http://www.aygfsteel.com/midea0978/aggbug/205987.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/midea0978/" target="_blank">在\?..</a> 2008-06-05 10:46 <a href="http://www.aygfsteel.com/midea0978/archive/2008/06/05/205987.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>JDBC驱动补丁与连接Oracle的一些错?/title><link>http://www.aygfsteel.com/midea0978/archive/2008/06/03/205529.html</link><dc:creator>在\?..</dc:creator><author>在\?..</author><pubDate>Tue, 03 Jun 2008 04:46:00 GMT</pubDate><guid>http://www.aygfsteel.com/midea0978/archive/2008/06/03/205529.html</guid><wfw:comment>http://www.aygfsteel.com/midea0978/comments/205529.html</wfw:comment><comments>http://www.aygfsteel.com/midea0978/archive/2008/06/03/205529.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.aygfsteel.com/midea0978/comments/commentRss/205529.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/midea0978/services/trackbacks/205529.html</trackback:ping><description><![CDATA[开发环境一直用jdbc14.jar "Oracle JDBC Driver version - 9.0.2.0.0"版本q接Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 服务器,H然今天不能q接了,报错误如下:<br /> <div style="border-right: #cccccc 1px solid; padding-right: 5px; border-top: #cccccc 1px solid; padding-left: 4px; font-size: 13px; padding-bottom: 4px; border-left: #cccccc 1px solid; width: 98%; word-break: break-all; padding-top: 4px; border-bottom: #cccccc 1px solid; background-color: #eeeeee"><img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><span style="color: #000000">java.sql.SQLException: 不能?nbsp;UTF8 ?nbsp;UCS2 之间转换: failUTF8Conv<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:</span><span style="color: #000000">134</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:</span><span style="color: #000000">179</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.dbaccess.DBError.check_error(DBError.java:</span><span style="color: #000000">1130</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.dbaccess.DBConversion.failUTF8Conv(DBConversion.java:</span><span style="color: #000000">2261</span><span style="color: #000000"><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.dbaccess.DBConversion.utf8BytesToJavaChars(DBConversion.j<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />ava:</span><span style="color: #000000">2061</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.dbaccess.DBConversion.utf8BytesToString(DBConversion.java<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />:</span><span style="color: #000000">1976</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.dbaccess.DBConversion.CharBytesToString(DBConversion.java<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />:</span><span style="color: #000000">543</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.ttc7.TTIoer.processWarning(TTIoer.java:</span><span style="color: #000000">334</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.ttc7.O3log.receive2nd(O3log.java:</span><span style="color: #000000">523</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.ttc7.TTC7Protocol.logon(TTC7Protocol.java:</span><span style="color: #000000">278</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.driver.OracleConnection.</span><span style="color: #000000"><</span><span style="color: #000000">init</span><span style="color: #000000">></span><span style="color: #000000">(OracleConnection.java:</span><span style="color: #000000">346</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.ja<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />va:</span><span style="color: #000000">468</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:</span><span style="color: #000000">314</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at java.sql.DriverManager.getConnection(Unknown Source)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at java.sql.DriverManager.getConnection(Unknown Source)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at JDBC.main(JDBC.java:</span><span style="color: #000000">9</span><span style="color: #000000">)</span></div> 然后更换为Oracle  11g的驱动,可以正常q接了,但是会显CZ面异?br /> <div style="border-right: #cccccc 1px solid; padding-right: 5px; border-top: #cccccc 1px solid; padding-left: 4px; font-size: 13px; padding-bottom: 4px; border-left: #cccccc 1px solid; width: 98%; word-break: break-all; padding-top: 4px; border-bottom: #cccccc 1px solid; background-color: #eeeeee"><img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><span style="color: #000000">javax.management.MalformedObjectNameException: Invalid character </span><span style="color: #000000">'<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />'</span><span style="color: #000000"> in value part of property</span><span style="color: #000000"><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /></span><span style="color: #000000">at javax.management.ObjectName.construct(ObjectName.java:</span><span style="color: #000000">529</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />at javax.management.ObjectName.</span><span style="color: #000000"><</span><span style="color: #000000">init</span><span style="color: #000000">></span><span style="color: #000000">(ObjectName.java:</span><span style="color: #000000">1304</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />at oracle.jdbc.driver.OracleDriver.registerMBeans(OracleDriver.java:</span><span style="color: #000000">303</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />at oracle.jdbc.driver.OracleDriver$</span><span style="color: #000000">1</span><span style="color: #000000">.run(OracleDriver.java:</span><span style="color: #000000">213</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />at java.security.AccessController.doPrivileged(Native Method)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />at oracle.jdbc.driver.OracleDriver.</span><span style="color: #000000"><</span><span style="color: #000000">clinit</span><span style="color: #000000">></span><span style="color: #000000">(OracleDriver.java:</span><span style="color: #000000">209</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />at java.lang.Class.forName0(Native Method)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />at java.lang.Class.forName(Class.java:</span><span style="color: #000000">164</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /></span></div> 采用9i驱动q碰C面错?br /> <div style="border-right: #cccccc 1px solid; padding-right: 5px; border-top: #cccccc 1px solid; padding-left: 4px; font-size: 13px; padding-bottom: 4px; border-left: #cccccc 1px solid; width: 98%; word-break: break-all; padding-top: 4px; border-bottom: #cccccc 1px solid; background-color: #eeeeee"><img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><span style="color: #000000">java.sql.SQLException: q反协议<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:</span><span style="color: #000000">134</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:</span><span style="color: #000000">179</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.dbaccess.DBError.check_error(DBError.java:</span><span style="color: #000000">1160</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.ttc7.O3log.receive2nd(O3log.java:</span><span style="color: #000000">548</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.ttc7.TTC7Protocol.logon(TTC7Protocol.java:</span><span style="color: #000000">279</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.driver.OracleConnection.</span><span style="color: #000000"><</span><span style="color: #000000">init</span><span style="color: #000000">></span><span style="color: #000000">(OracleConnection.java:</span><span style="color: #000000">371</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.driver.OracleDriver.getConnectionInstance(OracleDriver.ja<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />va:</span><span style="color: #000000">551</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:</span><span style="color: #000000">351</span><span style="color: #000000">)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at java.sql.DriverManager.getConnection(Unknown Source)<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />        at java.sql.DriverManager.getConnection(Unknown Source)</span></div> <ul> <li>最l查询资料,发现q是jdbc驱动问题Q原因因该是与bug有关Q因此从Cotn.oracle.com下蝲驱动升解决问题?br /> ojdbc6.jar的驱动版本可以运行java -jar ojdbc6.jar查看Q如果是Oracle 11.1.0.6.0-Production+ JDBC 4.0 compiled with JDK6Q带+号就是补丁版本,否则是没有打补丁的,仍然可能出错?/li> <li>我遇到的请况Q采?0.2.0.4的jdbc驱动没有问题了</li> <li>oracle jdbc驱动下蝲地址如下Q?/li> </ul> <p> <table class="bodycopy" cellspacing="5" cellpadding="0" width="100%" border="0"> <tbody> <tr> <td valign="top" align="center" colspan="4" height="110"> <div align="left"><a >Oracle JDBC Portal </a></div> </td> </tr> <tr> <td valign="top" width="2%"><img height="16" src="http://www.oracle.com/technology/images/bullets_and_symbols/bullet.gif" width="16" align="top" alt="" /></td> <td><a class="bodylink" >Oracle Database 11<em>g</em> Release 1 (11.1.0.6) drivers</a></td> </tr> <tr> <td valign="top" width="2%"><img height="16" src="http://www.oracle.com/technology/images/bullets_and_symbols/bullet.gif" width="16" align="top" alt="" /></td> <td><a class="bodylink" >Oracle Database 10<em>g</em> Release 2 (10.2.0.4), (10.2.0.3), (10.2.0.2), (10.2.0.1.0) drivers</a></td> </tr> <tr> <td valign="top" width="2%"><img height="16" src="http://www.oracle.com/technology/images/bullets_and_symbols/bullet.gif" width="16" align="top" alt="" /></td> <td><a class="bodylink" >Oracle Database 10<em>g</em> (10.1.0.5), (10.1.0.4), (10.1.0.2.0) drivers</a></td> </tr> <tr> <td valign="top" width="2%"><img height="16" src="http://www.oracle.com/technology/images/bullets_and_symbols/bullet.gif" width="16" align="top" alt="" /></td> <td><a class="bodylink" >Oracle9<em>i</em> Release 2 (9.2.0.8), (9.2.0.5), (9.2.0.4), (9.2.0.3), & (9.2.0.1) drivers</a></td> </tr> <tr> <td valign="top" width="2%"><img height="16" src="http://www.oracle.com/technology/images/bullets_and_symbols/bullet.gif" width="16" align="top" alt="" /></td> <td><a class="bodylink" >Oracle9<em>i</em> Release 1 (9.0.1.4) & (9.0.1) drivers</a></td> </tr> <tr> <td valign="top" width="2%"><img height="16" src="http://www.oracle.com/technology/images/bullets_and_symbols/bullet.gif" width="16" align="top" alt="" /></td> <td><a class="bodylink" >Oracle8<em>i</em> Release 2 (8.1.7)</a></td> </tr> </tbody> </table> </p> <ul> <li></li> </ul> <img src ="http://www.aygfsteel.com/midea0978/aggbug/205529.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/midea0978/" target="_blank">在\?..</a> 2008-06-03 12:46 <a href="http://www.aygfsteel.com/midea0978/archive/2008/06/03/205529.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>Intellij idea v7.0 注册?/title><link>http://www.aygfsteel.com/midea0978/archive/2007/10/22/155024.html</link><dc:creator>在\?..</dc:creator><author>在\?..</author><pubDate>Mon, 22 Oct 2007 08:35:00 GMT</pubDate><guid>http://www.aygfsteel.com/midea0978/archive/2007/10/22/155024.html</guid><wfw:comment>http://www.aygfsteel.com/midea0978/comments/155024.html</wfw:comment><comments>http://www.aygfsteel.com/midea0978/archive/2007/10/22/155024.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.aygfsteel.com/midea0978/comments/commentRss/155024.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/midea0978/services/trackbacks/155024.html</trackback:ping><description><![CDATA[<span style="font-size: 10pt">      UCؓ是最好的JAVA IDE开发^?包括QJ2EE支持、Ant、JUnit、集成CVS。包含一个智能编辑器Q代码辅助和增强的自动代码工兗可提高JAVA开发h员的效率?/span><a name="entrymore"></a><br /> <p><span style="font-size: 10pt">   JetBrains已经发布了IntelliJ IDEA 7.0QIntelliJ IDEA 7里程?包括许多新的Ҏ(gu)和提高Q尤其是在对Java EE的支持上Q包括Spring和HibernateQ?strong class="kgb" style="border-top-width: 0px; padding-right: 0px; padding-left: 0px; font-weight: normal; border-left-width: 0px; border-bottom-width: 0px; padding-bottom: 0px; margin: 0px; cursor: hand; color: #0000ff; padding-top: 0px; border-right-width: 0px; text-decoration: underline">代码</strong>分析Q扩展版本控制支持,Rational ClearCase集成Q增Z调试Q代码查询,可用性和<strong class="kgb" style="font-weight: normal; cursor: hand; color: #0000ff; text-decoration: underline">性能</strong>?<br /> </span></p> <p><span style="font-size: 10pt">   正用IntelliJ IDEA 6.0的用户可以免费用IntelliJ IDEA 7.0?007q?2?1P评估用户可以?strong class="kgb" style="border-top-width: 0px; padding-right: 0px; padding-left: 0px; font-weight: normal; border-left-width: 0px; border-bottom-width: 0px; padding-bottom: 0px; margin: 0px; cursor: hand; color: #0000ff; padding-top: 0px; border-right-width: 0px; text-decoration: underline">官方|站</strong><strong class="kgb" style="font-weight: normal; cursor: hand; color: #0000ff; text-decoration: underline">下蝲</strong>q有30天的免费试用期?</span></p> <p><span style="font-size: 10pt">   IntelliJ IDEA 7.0的新Ҏ(gu)包括: </span></p> <p><span style="font-size: 10pt">   1.性能提高 <br />    IDE的启动速度得到改善 <br />    ~辑JSP的速度加快 <br />    更快的XML的格式化</span></p> <p><span style="font-size: 10pt">   2.对Hibernate的支?br />    代码助手</span></p> <p><span style="font-size: 10pt">   3.对Spring的支?br />    代码助手<br />    观察依赖的可视化图表<br />    专门的文件设|编辑器</span></p> <p><span style="font-size: 10pt">   4.与Eclipse的协作能?<br />    导入Q从现有的Eclipse<strong class="kgb" style="border-top-width: 0px; padding-right: 0px; padding-left: 0px; font-weight: normal; border-left-width: 0px; border-bottom-width: 0px; padding-bottom: 0px; margin: 0px; cursor: hand; color: #0000ff; padding-top: 0px; border-right-width: 0px; text-decoration: underline">工程</strong>中创建IntelliJ IDEA .iml?ipr文g Q?<br />    导出Q从现有的IntelliJ IDEA .iml文g中创建Eclipse工程文gQ?<br />    同步</span></p> <p><span style="font-size: 10pt">   5.版本控制<br />    支持Rational ClearCase </span></p> <p><span style="font-size: 10pt">   6.JavaScript <br />    支持JSON文gcd <br />    JSDoc和DoJo样式cd注释提供了更准确的完成和参数cd信息 <br />    JSDoc和DoJo样式注释的丰富文?<br />    JavaScript命名I间完成/验证<br /> <br /> 一份注册码如下QEnjoy!<br /> =============================================================<br /> </p> <p>user name:在\?..<br /> License:12008-M3132-RY84C-0GSMK-V7TNK-33XV0<br /> customer id:12008<br /> product id:IDEA<br /> license type:COMMERCIAL<br /> major version:7<br /> minor version:0<br /> generationDate:Mon Oct 22 16:31:47 CST 2007<br /> expirationDate:Sun Jan 20 16:31:47 CST 2008</p> <p></span> </p> <img src ="http://www.aygfsteel.com/midea0978/aggbug/155024.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/midea0978/" target="_blank">在\?..</a> 2007-10-22 16:35 <a href="http://www.aygfsteel.com/midea0978/archive/2007/10/22/155024.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>Zlib压羃法在java与delphi之间的交互实?/title><link>http://www.aygfsteel.com/midea0978/archive/2007/10/10/151645.html</link><dc:creator>在\?..</dc:creator><author>在\?..</author><pubDate>Wed, 10 Oct 2007 02:35:00 GMT</pubDate><guid>http://www.aygfsteel.com/midea0978/archive/2007/10/10/151645.html</guid><wfw:comment>http://www.aygfsteel.com/midea0978/comments/151645.html</wfw:comment><comments>http://www.aygfsteel.com/midea0978/archive/2007/10/10/151645.html#Feedback</comments><slash:comments>3</slash:comments><wfw:commentRss>http://www.aygfsteel.com/midea0978/comments/commentRss/151645.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/midea0978/services/trackbacks/151645.html</trackback:ping><description><![CDATA[<span style="font-size: 10pt">一个典型应用中Q用delphi作ؓ客户端,J2EE服务端,两者之间用XML作ؓ数据交换Qؓ了提高效率,对XML数据q行压羃Qؓ此需要找CU压~?解压法能够两个q_之间交互处理Q用ZLIB法是一个不错的解决Ҏ(gu)?br /> 1、JAVA实现<br /> 在JDK中,在java.util.zip包中已经内置了ZLIB的实玎ͼCZ代码如下Q?br /> <div style="border-right: #cccccc 1px solid; padding-right: 5px; border-top: #cccccc 1px solid; padding-left: 4px; font-size: 13px; padding-bottom: 4px; border-left: #cccccc 1px solid; width: 98%; word-break: break-all; padding-top: 4px; border-bottom: #cccccc 1px solid; background-color: #eeeeee"><span style="color: #008080"> 1</span><img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><span style="color: #008000">//</span><span style="color: #008000">解压</span><span style="color: #008000"><br /> </span><span style="color: #008080"> 2</span><span style="color: #008000"><img id="Codehighlighter1_54_448_Open_Image" onclick="this.style.display='none'; Codehighlighter1_54_448_Open_Text.style.display='none'; Codehighlighter1_54_448_Closed_Image.style.display='inline'; Codehighlighter1_54_448_Closed_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockStart.gif" align="top" alt="" /><img id="Codehighlighter1_54_448_Closed_Image" style="display: none" onclick="this.style.display='none'; Codehighlighter1_54_448_Closed_Text.style.display='none'; Codehighlighter1_54_448_Open_Image.style.display='inline'; Codehighlighter1_54_448_Open_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ContractedBlock.gif" align="top" alt="" /></span><span style="color: #000000">    </span><span style="color: #0000ff">public</span><span style="color: #000000"> String decompressData(String encdata) </span><span id="Codehighlighter1_54_448_Closed_Text" style="border-right: #808080 1px solid; border-top: #808080 1px solid; display: none; border-left: #808080 1px solid; border-bottom: #808080 1px solid; background-color: #ffffff"><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_54_448_Open_Text"><span style="color: #000000">{<br /> </span><span style="color: #008080"> 3</span><span style="color: #000000"><img id="Codehighlighter1_68_343_Open_Image" onclick="this.style.display='none'; Codehighlighter1_68_343_Open_Text.style.display='none'; Codehighlighter1_68_343_Closed_Image.style.display='inline'; Codehighlighter1_68_343_Closed_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedSubBlockStart.gif" align="top" alt="" /><img id="Codehighlighter1_68_343_Closed_Image" style="display: none" onclick="this.style.display='none'; Codehighlighter1_68_343_Closed_Text.style.display='none'; Codehighlighter1_68_343_Open_Image.style.display='inline'; Codehighlighter1_68_343_Open_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ContractedSubBlock.gif" align="top" alt="" />        </span><span style="color: #0000ff">try</span><span style="color: #000000"> </span><span id="Codehighlighter1_68_343_Closed_Text" style="border-right: #808080 1px solid; border-top: #808080 1px solid; display: none; border-left: #808080 1px solid; border-bottom: #808080 1px solid; background-color: #ffffff"><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_68_343_Open_Text"><span style="color: #000000">{<br /> </span><span style="color: #008080"> 4</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            ByteArrayOutputStream bos </span><span style="color: #000000">=</span><span style="color: #000000"> </span><span style="color: #0000ff">new</span><span style="color: #000000"> ByteArrayOutputStream();<br /> </span><span style="color: #008080"> 5</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            InflaterOutputStream zos </span><span style="color: #000000">=</span><span style="color: #000000"> </span><span style="color: #0000ff">new</span><span style="color: #000000"> InflaterOutputStream(bos);<br /> </span><span style="color: #008080"> 6</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            zos.write(convertFromBase64(encdata));<br /> </span><span style="color: #008080"> 7</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            zos.close();<br /> </span><span style="color: #008080"> 8</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            </span><span style="color: #0000ff">return</span><span style="color: #000000"> </span><span style="color: #0000ff">new</span><span style="color: #000000"> String(bos.toByteArray());<br /> </span><span style="color: #008080"> 9</span><span style="color: #000000"><img id="Codehighlighter1_366_442_Open_Image" onclick="this.style.display='none'; Codehighlighter1_366_442_Open_Text.style.display='none'; Codehighlighter1_366_442_Closed_Image.style.display='inline'; Codehighlighter1_366_442_Closed_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedSubBlockStart.gif" align="top" alt="" /><img id="Codehighlighter1_366_442_Closed_Image" style="display: none" onclick="this.style.display='none'; Codehighlighter1_366_442_Closed_Text.style.display='none'; Codehighlighter1_366_442_Open_Image.style.display='inline'; Codehighlighter1_366_442_Open_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ContractedSubBlock.gif" align="top" alt="" />        }</span></span><span style="color: #000000"> </span><span style="color: #0000ff">catch</span><span style="color: #000000"> (Exception ex) </span><span id="Codehighlighter1_366_442_Closed_Text" style="border-right: #808080 1px solid; border-top: #808080 1px solid; display: none; border-left: #808080 1px solid; border-bottom: #808080 1px solid; background-color: #ffffff"><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_366_442_Open_Text"><span style="color: #000000">{<br /> </span><span style="color: #008080">10</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            ex.printStackTrace();<br /> </span><span style="color: #008080">11</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            </span><span style="color: #0000ff">return</span><span style="color: #000000"> </span><span style="color: #000000">"</span><span style="color: #000000">UNZIP_ERR</span><span style="color: #000000">"</span><span style="color: #000000">;<br /> </span><span style="color: #008080">12</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedSubBlockEnd.gif" align="top" alt="" />        }</span></span><span style="color: #000000"><br /> </span><span style="color: #008080">13</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockEnd.gif" align="top" alt="" />    }</span></span><span style="color: #000000"><br /> </span><span style="color: #008080">14</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> </span><span style="color: #008080">15</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />    </span><span style="color: #008000">//</span><span style="color: #008000">压羃</span><span style="color: #008000"><br /> </span><span style="color: #008080">16</span><span style="color: #008000"><img id="Codehighlighter1_504_902_Open_Image" onclick="this.style.display='none'; Codehighlighter1_504_902_Open_Text.style.display='none'; Codehighlighter1_504_902_Closed_Image.style.display='inline'; Codehighlighter1_504_902_Closed_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockStart.gif" align="top" alt="" /><img id="Codehighlighter1_504_902_Closed_Image" style="display: none" onclick="this.style.display='none'; Codehighlighter1_504_902_Closed_Text.style.display='none'; Codehighlighter1_504_902_Open_Image.style.display='inline'; Codehighlighter1_504_902_Open_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ContractedBlock.gif" align="top" alt="" /></span><span style="color: #000000">    </span><span style="color: #0000ff">public</span><span style="color: #000000"> String compressData(String data) </span><span id="Codehighlighter1_504_902_Closed_Text" style="border-right: #808080 1px solid; border-top: #808080 1px solid; display: none; border-left: #808080 1px solid; border-bottom: #808080 1px solid; background-color: #ffffff"><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_504_902_Open_Text"><span style="color: #000000">{<br /> </span><span style="color: #008080">17</span><span style="color: #000000"><img id="Codehighlighter1_518_799_Open_Image" onclick="this.style.display='none'; Codehighlighter1_518_799_Open_Text.style.display='none'; Codehighlighter1_518_799_Closed_Image.style.display='inline'; Codehighlighter1_518_799_Closed_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedSubBlockStart.gif" align="top" alt="" /><img id="Codehighlighter1_518_799_Closed_Image" style="display: none" onclick="this.style.display='none'; Codehighlighter1_518_799_Closed_Text.style.display='none'; Codehighlighter1_518_799_Open_Image.style.display='inline'; Codehighlighter1_518_799_Open_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ContractedSubBlock.gif" align="top" alt="" />        </span><span style="color: #0000ff">try</span><span style="color: #000000"> </span><span id="Codehighlighter1_518_799_Closed_Text" style="border-right: #808080 1px solid; border-top: #808080 1px solid; display: none; border-left: #808080 1px solid; border-bottom: #808080 1px solid; background-color: #ffffff"><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_518_799_Open_Text"><span style="color: #000000">{<br /> </span><span style="color: #008080">18</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            ByteArrayOutputStream bos </span><span style="color: #000000">=</span><span style="color: #000000"> </span><span style="color: #0000ff">new</span><span style="color: #000000"> ByteArrayOutputStream();<br /> </span><span style="color: #008080">19</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            DeflaterOutputStream zos </span><span style="color: #000000">=</span><span style="color: #000000"> </span><span style="color: #0000ff">new</span><span style="color: #000000"> DeflaterOutputStream(bos);<br /> </span><span style="color: #008080">20</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            zos.write(data.getBytes());<br /> </span><span style="color: #008080">21</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            zos.close();<br /> </span><span style="color: #008080">22</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            </span><span style="color: #0000ff">return</span><span style="color: #000000"> </span><span style="color: #0000ff">new</span><span style="color: #000000"> String(convertToBase64(bos.toByteArray()));<br /> </span><span style="color: #008080">23</span><span style="color: #000000"><img id="Codehighlighter1_822_896_Open_Image" onclick="this.style.display='none'; Codehighlighter1_822_896_Open_Text.style.display='none'; Codehighlighter1_822_896_Closed_Image.style.display='inline'; Codehighlighter1_822_896_Closed_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedSubBlockStart.gif" align="top" alt="" /><img id="Codehighlighter1_822_896_Closed_Image" style="display: none" onclick="this.style.display='none'; Codehighlighter1_822_896_Closed_Text.style.display='none'; Codehighlighter1_822_896_Open_Image.style.display='inline'; Codehighlighter1_822_896_Open_Text.style.display='inline';" src="http://www.aygfsteel.com/images/OutliningIndicators/ContractedSubBlock.gif" align="top" alt="" />        }</span></span><span style="color: #000000"> </span><span style="color: #0000ff">catch</span><span style="color: #000000"> (Exception ex) </span><span id="Codehighlighter1_822_896_Closed_Text" style="border-right: #808080 1px solid; border-top: #808080 1px solid; display: none; border-left: #808080 1px solid; border-bottom: #808080 1px solid; background-color: #ffffff"><img src="http://www.aygfsteel.com/Images/dot.gif" alt="" /></span><span id="Codehighlighter1_822_896_Open_Text"><span style="color: #000000">{<br /> </span><span style="color: #008080">24</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            ex.printStackTrace();<br /> </span><span style="color: #008080">25</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/InBlock.gif" align="top" alt="" />            </span><span style="color: #0000ff">return</span><span style="color: #000000"> </span><span style="color: #000000">"</span><span style="color: #000000">ZIP_ERR</span><span style="color: #000000">"</span><span style="color: #000000">;<br /> </span><span style="color: #008080">26</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedSubBlockEnd.gif" align="top" alt="" />        }</span></span><span style="color: #000000"><br /> </span><span style="color: #008080">27</span><span style="color: #000000"><img src="http://www.aygfsteel.com/images/OutliningIndicators/ExpandedBlockEnd.gif" align="top" alt="" />    }</span></span></div> <br /> 2、DELPHI中的实现<br /> 在DELPHI中,有第3方的控g可以利用来实现压~?解压Q这里我们选择VCLZIP V3.04Q可以从q里下蝲<a >http://www.vclzip.net</a><br /> Z提高通用性,我们可以~写一个标准的DLLQ就可以在Win32q_随意调用了,关键代码如下Q?br /> <div style="border-right: #cccccc 1px solid; padding-right: 5px; border-top: #cccccc 1px solid; padding-left: 4px; font-size: 13px; padding-bottom: 4px; border-left: #cccccc 1px solid; width: 98%; word-break: break-all; padding-top: 4px; border-bottom: #cccccc 1px solid; background-color: #eeeeee"><img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><span style="color: #0000ff">function</span><span style="color: #000000"> Cmip_CompressStr(txt: PChar): pchar; stdcall;<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />var<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  zip: TVclZip;<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  compr: </span><span style="color: #0000ff">string</span><span style="color: #000000">;<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  data: PChar;<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />begin<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  zip :</span><span style="color: #000000">=</span><span style="color: #000000"> TVclZip.Create(nil);<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  compr :</span><span style="color: #000000">=</span><span style="color: #000000"> zip.ZLibCompressString(txt);<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  data :</span><span style="color: #000000">=</span><span style="color: #000000"> pchar(Base64EncodeStr(compr));<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  Result :</span><span style="color: #000000">=</span><span style="color: #000000"> StrNew(data);<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  zip.Free<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /></span><span style="color: #0000ff">end</span><span style="color: #000000">;<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /><br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /></span><span style="color: #0000ff">function</span><span style="color: #000000"> Cmip_DeCompressStr(txt: PChar): pchar; stdcall;<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />var<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  zip: TVCLUnZip;<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  compr: </span><span style="color: #0000ff">string</span><span style="color: #000000">;<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  data: PChar;<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />begin<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  zip :</span><span style="color: #000000">=</span><span style="color: #000000"> TVCLUnZip.Create(nil);<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  compr :</span><span style="color: #000000">=</span><span style="color: #000000"> zip.ZLibDecompressString(Base64DecodeStr(txt));<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  data :</span><span style="color: #000000">=</span><span style="color: #000000"> StrNew(pchar(compr));<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  Result :</span><span style="color: #000000">=</span><span style="color: #000000"> data;<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" />  zip.Free<br /> <img src="http://www.aygfsteel.com/images/OutliningIndicators/None.gif" align="top" alt="" /></span><span style="color: #0000ff">end</span><span style="color: #000000">;</span></div> <br /> <br /> 在我们当前的目中,采用的方案是Powerbuilder +DLL与J2EEq_q行xml数据交换的方式?/span> <img src ="http://www.aygfsteel.com/midea0978/aggbug/151645.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/midea0978/" target="_blank">在\?..</a> 2007-10-10 10:35 <a href="http://www.aygfsteel.com/midea0978/archive/2007/10/10/151645.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>Resin Pro 3.1.2 Plugin for IntelliJ IDEA http://www.aygfsteel.com/midea0978/archive/2007/09/18/146102.html在\?..在\?..Tue, 18 Sep 2007 03:04:00 GMThttp://www.aygfsteel.com/midea0978/archive/2007/09/18/146102.htmlhttp://www.aygfsteel.com/midea0978/comments/146102.htmlhttp://www.aygfsteel.com/midea0978/archive/2007/09/18/146102.html#Feedback2http://www.aygfsteel.com/midea0978/comments/commentRss/146102.htmlhttp://www.aygfsteel.com/midea0978/services/trackbacks/146102.html在这里可以下载Resin  Plugin for  IntelliJ IDEA  Q但是对?.1X好像q不支持?/span>http://plugins.intellij.net/plugin/?id=215
作者更新太慢,不好意思自己动手反~译修改了几个地方,现在可以支持Resin Pro 3.1.2Q如果需要地可以从这?br /> * 下蝲Q?/span>Resin_2640_31.zip
* 安装Q?br /> 修改文g名ؓResin_2640_31.jarQ复制到C:\Documents and Settings\[username]\.IntelliJIdea60\config\plugins下面
* 修改记录
1、将3.1.2的resin.conf文g命名为resin31.conf加到org\intellij\j2ee\web\resin\resin下面
2、将ResinVersion.java修改为如下方法判断是?.1版本

public static final ResinVersion VERSION_3_X = new ResinVersion("Resin 3.x"{

        
public boolean
 isOfVersion(File file)
        
{
            
return (new File(new File(file, "lib"), "jsdk-15.jar"
)).exists();
        }


        
public String getStartupClass()
        
{
            
return "com.caucho.server.resin.Resin"
;
        }


    }
3、修改Resin3XConfigurationStrategy.java文g中部分判断h(hun)ttp port、host的代?br /> 原来的XML节点为root->server->host->http->port   and  root->server->host->web-app
3.1下面的XML节点为root->cluster->server-default->http->port and    root->cluster->host->web-app
改过的代码ؓ
Element httpElement = document.getRootElement().getChild("cluster", ns).getChild("server-default", ns).getChild("http", ns);

Element host = getHost(document.getRootElement().getChild("cluster", ns), ns, webApp);

List hosts = document.getRootElement().getChild("cluster", ns).getChildren("host", ns);

public InputStream getDefaultResinConfContent()
    {
        return getClass().getResourceAsStream("/org/intellij/j2ee/web/resin/resin/resin31.conf");
    }

原来的作者没有开源,所以不好做q一步的修改完善Q对?.0的版本应该就不支持了?br />


在\?.. 2007-09-18 11:04 发表评论
]]>
集成struts+spring的新思\http://www.aygfsteel.com/midea0978/archive/2007/01/11/93219.html在\?..在\?..Thu, 11 Jan 2007 09:27:00 GMThttp://www.aygfsteel.com/midea0978/archive/2007/01/11/93219.htmlhttp://www.aygfsteel.com/midea0978/comments/93219.htmlhttp://www.aygfsteel.com/midea0978/archive/2007/01/11/93219.html#Feedback7http://www.aygfsteel.com/midea0978/comments/commentRss/93219.htmlhttp://www.aygfsteel.com/midea0978/services/trackbacks/93219.html |上有好多种struts+spring的集成思\Q例?/font> http://dev.csdn.net/author/hql638/35679289a9a94e4f97e999508df064db.html
q篇文章׃l得很详l,介绍了下面三U方法:

使用 Spring ?ActionSupport cL?Structs
使用 Spring ?DelegatingRequestProcessor 覆盖 Struts ?RequestProcessor
?Struts Action 理委托l?Spring 框架
其实在用spring+strutsӞ我们往往是想用Ioc的特性,减少业务逻辑lg之间的依赖关p,通过高度灉|的XML配置提高业务的灵zL和扩展性。步骤如下:
首先依旧加入spring的context plugin到struts-config.xml?/font>

< struts-config >
  
< plug-in
         
className ="org.springframework.web.struts.ContextLoaderPlugIn" >
     
< set-property  property ="contextConfigLocation"
         value
="/WEB-INF/applicationContext.xml"   />
  
</ plug-in >
</ struts-config >


然后包装一下struts的DispatchActionQ提供一个方法可以直接获取Spring的WebApplicationContext对象?/font>

package  com.cngd.dataview.action; 

import  org.apache.struts.actions.DispatchAction;
import  org.springframework.web.context.WebApplicationContext;
import  org.springframework.web.struts.DelegatingActionUtils; 

/**   */ /**
 * Date: 2007-1-11 16:57:48
 *
 * 
@author  midea0978
 * 
@version  1.0
 
*/

public   class  CommDispatchAction  extends  DispatchAction  {
    
protected  WebApplicationContext getAppContext()  {
        WebApplicationContext context 
=  DelegatingActionUtils.findRequiredWebApplicationContext( this .getServlet(),  null );
        
return  context;
    }

}
 


然后自己的action可以直接从CommDispatchActionl承通过this.getAppContext();获取WebApplicationContext,q样对原有的
strutsE序架构体系几乎没有太大的变化,同时可以引入spring的IocҎ(gu)到现有pȝ中,q个与ActionSupport 中的
getWebApplicationContext()Ҏ(gu)cM了,但是可以不必拘惔于在两者之间{来{ȝ?br />

package  com.cngd.dataview.action; 

import  com.spring.bo.WeatherService;
import  org.apache.log4j.Logger;
import  org.apache.struts.action.ActionForm;
import  org.apache.struts.action.ActionForward;
import  org.apache.struts.action.ActionMapping;
import  org.springframework.jdbc.core.JdbcTemplate;
import  org.springframework.jdbc.datasource.DriverManagerDataSource;
import  org.springframework.web.context.WebApplicationContext; 

import  javax.servlet.http.HttpServletRequest;
import  javax.servlet.http.HttpServletResponse; 

/**   */ /**
 * Date: 2007-1-11 16:19:15
 *
 * 
@author  midea0978
 * 
@version  1.0
 
*/

public   class  DataViewAction  extends  CommDispatchAction  {
    
static  Logger logger  =  Logger.getLogger(DataViewAction. class .getName()); 

    
/**   */ /**
     * 
@param  actionMapping
     * 
@param  actionForm
     * 
@param  request
     * 
@param  response
     * 
@return
     * 
@throws  Exception
     
*/

    
public  ActionForward genReport(ActionMapping actionMapping, ActionForm actionForm, HttpServletRequest request, HttpServletResponse response)
            
throws  Exception  {
        String yymm 
=  request.getParameter( " yymm " );
        String opname 
=  request.getParameter( " opname " );
        logger.info(
" 参数Q?/span> "   +  yymm  +   " , "   +  opname);
        WebApplicationContext ctx 
=   this .getAppContext();
        WeatherService srv 
=  (WeatherService) ctx.getBean( " weatherServiceBean " );
        srv.showWeather();
        DriverManagerDataSource ds 
=  (DriverManagerDataSource) ctx.getBean( " datasource " );
        JdbcTemplate jt 
=   new  JdbcTemplate(ds);
        String sql 
=   " select count(*) from tab " ;
        
int  rows  =  jt.queryForInt(sql);
        System.out.println(rows);
        
return  actionMapping.findForward( " viewresult " );
    }
 


}
 



在\?.. 2007-01-11 17:27 发表评论
]]>
WebLogic配置文gConfig.xml中的{3DES}加密字符串的解密思\http://www.aygfsteel.com/midea0978/archive/2006/09/07/68223.html在\?..在\?..Thu, 07 Sep 2006 04:35:00 GMThttp://www.aygfsteel.com/midea0978/archive/2006/09/07/68223.htmlhttp://www.aygfsteel.com/midea0978/comments/68223.htmlhttp://www.aygfsteel.com/midea0978/archive/2006/09/07/68223.html#Feedback1http://www.aygfsteel.com/midea0978/comments/commentRss/68223.htmlhttp://www.aygfsteel.com/midea0978/services/trackbacks/68223.html通常在weblogic的config.xml文g中,对于关键字符丌Ӏ密码会自动加密Q例如LDAP密码、数据库JDBCq接池连接密码等。通常加密之后前面会加上{3DES}的标识?br />3DES是DES法的增强,相关资料如下Q?br />1、DESQData Encryption StandardQ是一U经典的对称法。其数据分组长度?4位,使用的密钥ؓ64位,有效密钥长度?6位(?位用于奇偶校验)。它由IBM公司?0q代开发,l过政府的加密标准筛选后Q于1976q?1月被国政府采用Q随后被国国家标准局和美国国家标准协?American National Standard InstituteQ?ANSI) 承认?br />
该技术算法公开Q在各行业有着q泛的应用。DES法从公布到现在已有20多年的历Ԍ׃计算力的飞速发展,DES?6位密钥长度显得有些太短了Q已l有可能通过ID?br />
Ҏ(gu)来对其进行攻凅R但是除此以外,直到现在q没有发现穷举以外的能有效破译DES的方法?br />2、DES法现在已经不能提供_的安全性,因ؓ其有效密钥只?6位。因此,后来又提Z三重DESQ或U?DESQ,该方法的强度大约?12比特的密钥强度相当?
q种Ҏ(gu)用两个密钥对明文q行三次q算。设两个密钥是K1和K2Q其法的步骤如?所C:
1. 用密钥K1q行DES加密?
2. 用K2Ҏ(gu)?的结果进行DES解密?
3. 用步?的结果用密钥K1q行DES加密?

首先需要找到加密的密钥Q根据BEA文可以发现是文件SerializedSystemIni.datQ查找一下安装目录就可以扑ֈ整个问见Q通常pȝ理员应该将该文件设|ؓ不能直接讉KQ以提高安全性?br />加密、解密的大致演示法代码如下Q在WebLogic 9.2下面调试通过Q运行编译前应该先运行setExamplesEnv.cmdQ参考)的环境变量,以保证相关类库已l被引用了。对于低版本的WebLogic,例如WebLogic 7.0/8.1可能不能直接在命令行执行Q因为SerializedSystemIni必须在控制台Console环境下面才能调用Q有兴趣的朋友可以自行测试看看?
 1import weblogic.security.internal.*;
 2import weblogic.security.internal.encryption.EncryptionService;
 3import weblogic.utils.encoders.BASE64Decoder;
 4import weblogic.utils.encoders.BASE64Encoder;
 5public class CrackData 
 6{
 7    public static void main(String[] args) 
 8    {
 9        byte[] salt,keys;
10        salt=SerializedSystemIni.getSalt();
11        keys=SerializedSystemIni.getEncryptedSecretKey();
12        String data="";
13        for(int i=0;i<salt.length;i++){
14            data+=salt[i]+",";
15        }

16        System.out.println("salt:"+data);
17        data="";
18        for(int i=0;i<keys.length;i++){
19            data+=keys[i]+",";
20        }

21        System.out.println("Key:"+data);
22        //EncryptionService svr=SerializedSystemIni.getExistingEncryptionService();
23        EncryptionService svr=SerializedSystemIni.getEncryptionService();
24        System.out.println(svr);
25        System.out.println(svr.getAlgorithm());
26        if(args.length>1){
27            if(args[0].equals("encrypt")){
28                byte[] edata=svr.encryptString(args[1]);
29                String s = (new BASE64Encoder()).encodeBuffer(edata);
30                System.out.println("Encode:"+s);
31            }

32            if(args[0].equals("decrypt")){
33                try{
34                byte[] edata = (new BASE64Decoder()).decodeBuffer(args[1]);
35                String txt=svr.decryptString(edata);
36                System.out.println("Decode:"+txt);
37                }
catch(Exception ex){
38                    ex.printStackTrace();
39                }

40            }

41        }

42        
43    }

44}

45

试q行l果如下Q?br />
root@srdsh # /rdsh/bea92/jdk150_04/bin/java CrackData decrypt nMttUc5jNe9RNJXslXjbJQ==
-86,123,19,107,
-42,-28,-75,-100,31,0,25,-93,75,115,40,-3,-15,42,-53,41,-25,-13,-6,8,36,85,-81,2
8,66,-110,31,38,-29,-79,-44,-48,
weblogic.security.internal.encryption.JSafeEncryptionServiceImpl@199f91c
3DES
Decode:weblogic
root@srdsh # 
/rdsh/bea92/jdk150_04/bin/java CrackData decrypt erzD515N5z2zSnOk7uG1cYQthCbYA5OU6Bw+Zt5BsjPruTQaOZASh+ZZW4kuBGvfbZ2BXWSACbgOZ2MY4bHtpOPps/6WfZJg
-86,123,19,107,
-42,-28,-75,-100,31,0,25,-93,75,115,40,-3,-15,42,-53,41,-25,-13,-6,8,36,85,-81,2
8,66,-110,31,38,-29,-79,-44,-48,
weblogic.security.internal.encryption.JSafeEncryptionServiceImpl@199f91c
3DES
Decode:
0xa778f572127d2282247ec653147c35d4e4040aca016c6d1e06ab325af5798fca
root@srdsh #


在\?.. 2006-09-07 12:35 发表评论
]]>
XDB与tomcat 8080端口冲突的解军_?/title><link>http://www.aygfsteel.com/midea0978/archive/2005/12/22/25061.html</link><dc:creator>在\?..</dc:creator><author>在\?..</author><pubDate>Thu, 22 Dec 2005 05:37:00 GMT</pubDate><guid>http://www.aygfsteel.com/midea0978/archive/2005/12/22/25061.html</guid><wfw:comment>http://www.aygfsteel.com/midea0978/comments/25061.html</wfw:comment><comments>http://www.aygfsteel.com/midea0978/archive/2005/12/22/25061.html#Feedback</comments><slash:comments>1</slash:comments><wfw:commentRss>http://www.aygfsteel.com/midea0978/comments/commentRss/25061.html</wfw:commentRss><trackback:ping>http://www.aygfsteel.com/midea0978/services/trackbacks/25061.html</trackback:ping><description><![CDATA[<P><FONT size=2>在安装了Oracle 9i之后XDB的http默认占用?080Qftp会占?100端口Q其实XDB是XML Database提供的一U服务,在oracle中有一个package可以用来l护理该服务的配置信息。这个包是<STRONG>dbms_xdb.<BR></STRONG>解决Ҏ(gu)有下面几U:<BR>1、sqlplus "/ as sysdba"q入数据?BR>SQL> -- Change the HTTP/WEBDAV port from 8080 to 8081<BR>  SQL> <B>call dbms_xdb.cfg_update(updateXML(</B><BR>    2      <B>  dbms_xdb.cfg_get()</B><BR>    3      <B>, '/xdbconfig/sysconfig/protocolconfig/httpconfig/http-port/text()'</B><BR>    4      <B>, 8081))</B><BR>    5  <B>/</B><BR><BR>  Call completed. <BR><BR><BR>  SQL> -- Change the FTP port from 2100 to 2111<BR>  SQL> <B>call dbms_xdb.cfg_update(updateXML(</B><BR>    2       <B>  dbms_xdb.cfg_get()</B><BR>    3       <B>, '/xdbconfig/sysconfig/protocolconfig/ftpconfig/ftp-port/text()'</B><BR>    4       <B>, 2111))</B><BR>    5  <B>/</B><BR><BR>  Call completed. <BR><BR><BR>  SQL> <B>COMMIT;</B><BR><BR>  Commit complete. <BR><BR><BR>  SQL> <B>EXEC dbms_xdb.cfg_refresh;</B><BR><BR>  PL/SQL procedure successfully completed.<BR><BR><BR>  SQL> -- Verify the change<BR>  SQL> <B>set long 100000</B><BR>  SQL> <B>set pagesize 9000</B><BR>  SQL> <B>SELECT dbms_xdb.cfg_get FROM dual;</B><BR>2、移除XDB服务Q将实例信息L<BR>dispatchers='(PROTOCOL=TCP) (SERVICE=<ORACLE_SID>XDB)'<BR><BR>3、用Oracle Enterprise Manager 中的?STRONG>XML Database</STRONG> 配置信息中修Ҏ(gu)端口可以了</FONT></P><img src ="http://www.aygfsteel.com/midea0978/aggbug/25061.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.aygfsteel.com/midea0978/" target="_blank">在\?..</a> 2005-12-22 13:37 <a href="http://www.aygfsteel.com/midea0978/archive/2005/12/22/25061.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>JIRA 3.3.2注册与DSA{֐法研究 http://www.aygfsteel.com/midea0978/archive/2005/10/24/16566.html在\?..在\?..Mon, 24 Oct 2005 06:04:00 GMThttp://www.aygfsteel.com/midea0978/archive/2005/10/24/16566.htmlhttp://www.aygfsteel.com/midea0978/comments/16566.htmlhttp://www.aygfsteel.com/midea0978/archive/2005/10/24/16566.html#Feedback0http://www.aygfsteel.com/midea0978/comments/commentRss/16566.htmlhttp://www.aygfsteel.com/midea0978/services/trackbacks/16566.htmlJIRA是一个不错的问题跟踪pȝQ在软g开发项目中不可或缺Q详l资料可以访?A >http://www.atlassian.com/software/jira/

本文探讨了JIRA 3.3.2的注册机ӞZ利用JAVA的数字签名机制实C单的demo,具体内容见:
http://www.aygfsteel.com/midea0978/articles/16563.html



在\?.. 2005-10-24 14:04 发表评论
]]>
IBM WebSphere 6.0的BUGhttp://www.aygfsteel.com/midea0978/archive/2005/09/28/14324.html在\?..在\?..Wed, 28 Sep 2005 11:28:00 GMThttp://www.aygfsteel.com/midea0978/archive/2005/09/28/14324.htmlhttp://www.aygfsteel.com/midea0978/comments/14324.htmlhttp://www.aygfsteel.com/midea0978/archive/2005/09/28/14324.html#Feedback0http://www.aygfsteel.com/midea0978/comments/commentRss/14324.htmlhttp://www.aygfsteel.com/midea0978/services/trackbacks/14324.html
String fieldname="fieldname",value="value";
out.println("<"+fieldname+">"+value+"]]>"+fieldname+">\n");
q时候你会发现应该显C出来的CDATA标签不见了?BR>在另外一U写法下Q也会有错误Q?BR>
String fieldvalue="hello";

<td>[CDATA[<%=fieldvalue%>]]>td>

在这U情况下Q?%=fieldvalue%>是不会被执行的,在运行后的jsp里面仍然存在?BR>很可惜,q个问题已经得到了IBM开发实验室的确认,但是补丁到现在还没于出来,最新的版本?.0.2?/SPAN>

在\?.. 2005-09-28 19:28 发表评论
]]>
վ֩ģ壺 ʯ| | пǰ| | | ɽ| Ǧɽ| Ʊ| | | İ| | ͼľ| ߶| ʯ| | ʳ| °Ͷ| | | | Զ| | | | | | | | | ¡| | ƽȪ| ƽ| | | ͨ| ľ| ʡ| | |