系统:Debian/lenny java 1.5.0_13 netbeans5.5.1
现象: Netbeans下不能输入中文, 但显示正常
问题:系统编码为zh_CN.UTF-8 Netbeans编码为zh_CN.GBK
解决:调整系统与netbeans编码相一致
附:
指定Netbeans使用的编码
在netbeans-5.5.1/etc/netbeans.conf中加入:
export LC_ALL="zh_CN.GBK"
指定netbeans使用的JAVA的位置
在netbeans-5.5.1/etc/netbeans.conf中加入:
netbeans_jdkhome="/usr/lib/jvm/java-1.5.0-sun"
2007年10月23日星期二
2007年9月19日星期三
ab 压力测试
20490 tomcat55 18 0 303m 90m 5900 S 109 4.5 1:27.28 jsvc
# ab -c 1000 -n 100000 http://127.0.0.1:8080/gzjsgov/index.html
This is ApacheBench, Version 2.0.40-dev <$Revision: 1.146 $> apache-2.0
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Copyright 2006 The Apache Software Foundation, http://www.apache.org/
Benchmarking 127.0.0.1 (be patient)
Completed 10000 requests
Completed 20000 requests
Completed 30000 requests
Completed 40000 requests
Completed 50000 requests
Completed 60000 requests
Completed 70000 requests
Completed 80000 requests
Completed 90000 requests
Finished 100000 requests
Server Software: Apache-Coyote/1.1
Server Hostname: 127.0.0.1
Server Port: 8080
Document Path: /gzjsgov/index.html
Document Length: 7760 bytes
Concurrency Level: 1000
Time taken for tests: 49.334775 seconds
Complete requests: 100000
Failed requests: 12
(Connect: 0, Length: 11, Exceptions: 1)
Write errors: 0
Total transferred: 799601930 bytes
HTML transferred: 777070880 bytes
Requests per second: 2026.97 [#/sec] (mean)
Time per request: 493.348 [ms] (mean)
Time per request: 0.493 [ms] (mean, across all concurrent requests)
Transfer rate: 15827.80 [Kbytes/sec] received
Connection Times (ms)
min mean[+/-sd] median max
Connect: 1 376 1235.8 42 21067
Processing: 12 97 331.6 55 7291
Waiting: 0 84 326.1 47 7257
Total: 30 473 1352.8 109 21153
Percentage of the requests served within a certain time (ms)
50% 109
66% 133
75% 148
80% 160
90% 223
95% 3129
98% 3768
99% 9044
100% 21153 (longest request)
# ab -c 1000 -n 100000 http://127.0.0.1:8080/gzjsgov/index.html
This is ApacheBench, Version 2.0.40-dev <$Revision: 1.146 $> apache-2.0
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Copyright 2006 The Apache Software Foundation, http://www.apache.org/
Benchmarking 127.0.0.1 (be patient)
Completed 10000 requests
Completed 20000 requests
Completed 30000 requests
Completed 40000 requests
Completed 50000 requests
Completed 60000 requests
Completed 70000 requests
Completed 80000 requests
Completed 90000 requests
Finished 100000 requests
Server Software: Apache-Coyote/1.1
Server Hostname: 127.0.0.1
Server Port: 8080
Document Path: /gzjsgov/index.html
Document Length: 7760 bytes
Concurrency Level: 1000
Time taken for tests: 49.334775 seconds
Complete requests: 100000
Failed requests: 12
(Connect: 0, Length: 11, Exceptions: 1)
Write errors: 0
Total transferred: 799601930 bytes
HTML transferred: 777070880 bytes
Requests per second: 2026.97 [#/sec] (mean)
Time per request: 493.348 [ms] (mean)
Time per request: 0.493 [ms] (mean, across all concurrent requests)
Transfer rate: 15827.80 [Kbytes/sec] received
Connection Times (ms)
min mean[+/-sd] median max
Connect: 1 376 1235.8 42 21067
Processing: 12 97 331.6 55 7291
Waiting: 0 84 326.1 47 7257
Total: 30 473 1352.8 109 21153
Percentage of the requests served within a certain time (ms)
50% 109
66% 133
75% 148
80% 160
90% 223
95% 3129
98% 3768
99% 9044
100% 21153 (longest request)
2007年9月5日星期三
HTML里的valign、align
使用 VAlign 属性指定由 HtmlTableCell 类的实例所表示的单元格内容的垂直对齐方式。align是左右对齐方式。
“VALIGN"意思 -- vertical alignment 垂向对齐方法
其值可以是top -- 顶部;或middle -- 中部;或bottom-- 底部;或baseline -- 基线。默认中部--middle。
align是左右对齐方式。
其值:align="middle"内容居中、 align="left" 内容居左、 align="rigth" 内容居右。
HTML Quick List
“VALIGN"意思 -- vertical alignment 垂向对齐方法
其值可以是top -- 顶部;或middle -- 中部;或bottom-- 底部;或baseline -- 基线。默认中部--middle。
align是左右对齐方式。
其值:align="middle"内容居中、 align="left" 内容居左、 align="rigth" 内容居右。
HTML Quick List
2007年8月25日星期六
遭遇ORA-01461
oracle 版本:9.2i
驱动版本:classes12.jar for 10.2.0.3.0
数据类型:clob
当插入中文数据在2000字符左右时就会抛出这个错误
--- The error occurred in cn/gov/gzjs/conf/article.xml.
--- The error occurred while applying a parameter map.
--- Check the insertArticle-InlineParameterMap.
--- Check the statement (update failed).
--- Cause: java.sql.SQLException: ORA-01461: 仅可以为插入 LONG 列的 LONG 值赋值
超过 或 少于 都没有问题
郁闷啊
驱动版本:classes12.jar for 10.2.0.3.0
数据类型:clob
当插入中文数据在2000字符左右时就会抛出这个错误
--- The error occurred in cn/gov/gzjs/conf/article.xml.
--- The error occurred while applying a parameter map.
--- Check the insertArticle-InlineParameterMap.
--- Check the statement (update failed).
--- Cause: java.sql.SQLException: ORA-01461: 仅可以为插入 LONG 列的 LONG 值赋值
超过 或 少于 都没有问题
郁闷啊
2007年8月3日星期五
用Diff和Patch工具维护源码
在Unix系统下,维护源码版本可以使用很多方法,其中最常用的当然是大名鼎鼎的CVS,但实际上,简单的版本维护工作并没有必要使用复杂的CVS等专门的版本维护工具,Unix标配中的diff和patch工具就完全可以完成代码的简单备份和升级工作。
用Diff和Patch工具维护源码
用Diff和Patch工具维护源码
订阅:
博文 (Atom)
