Wednesday, October 21, 2009
老婆说有点像我
从前,有位年轻的猎手,他枪法极准但总捕猎不到大雁,苦恼的他找一位长者求教。
长者把他领到一片大雁栖息的芦苇地,指着站得最高的一只大雁说:"那只大雁是放哨的,我们管它叫雁奴。它只要一发现异常情况就会向雁群报警,所以接近雁群往往是很困难的。但我有办法,你现在故意惊动雁奴再潜伏不动。"年轻人照做了。雁奴发现年轻人后立即向同伴发出警告,正在栖息的雁群闻讯后纷纷出逃,但没发现什么,便又飞回原地。长者让年轻人如法炮制了好几回。终于,几乎所有的大雁都以为雁奴谎报军情,纷纷把不满发泄在雁奴身上,可怜的雁奴被啄得伤痕累累。"现在,你可以逼近雁群了。"长者提醒道。于是,年轻人大摇大摆地走进了芦苇地,雁奴虽瞧在眼里但也懒得再管,年轻人举枪......
悲剧往往就是这样发生的:忠诚的人被误解,被误解的人不能坚持到底。
Thursday, October 15, 2009
Ubuntu9.04上看电影加载中文字幕乱码问题
import sys,io
if len(sys.argv) != 2:
print "Please input file path!"
else:
f1 = io.open(sys.argv[1], "r", encoding="cp936")
f2 = io.open(sys.argv[1] + ".new", "w", encoding="utf-8")
for line in f1:
f2.write(line)
f1.close()
f2.close()
Wednesday, October 14, 2009
Linux代理服务配置
2. 配置/etc/squid/squid.conf文件
acl all src 0.0.0.0/0.0.0.0
http_access allow all
由于我是内网使用,所以权限配置就全开放了。
3. 启动squid服务,默认的端口是3128
service squid restart
Sunday, October 4, 2009
《三杯茶》
老婆:看了。
我:怎么样?
老婆:挺好的,讲人性的。
我:啊,你看懂了,我看了一点咋没看懂。
老婆:那当然了,你没有人性么。
Saturday, September 12, 2009
搭建公司Hudson持续集成环境
Sunday, August 16, 2009
perf4j vs. simon
Spring AOP - Caused by: java.lang.IllegalArgumentException: Superclass has no null constructors but no arguments were given
Friday, August 7, 2009
Struts2中Action的@BeforeResult方法被执行两次问题
public void beforeResult(ActionInvocation invocation, String resultCode) { Object action = invocation.getAction(); List if (methods != null && methods.size() > 0) { Collections.sort(methods, new Comparator public int compare(Method method1, Method method2) { return method2.getAnnotation(BeforeResult.class).priority() - method1.getAnnotation(BeforeResult.class).priority(); } }); for (Method m : methods) { try { m.invoke(action, (Object[]) null); } catch (Exception e) { throw new XWorkException(e); } } } } |
Monday, July 27, 2009
perf4j中使用Piped I/O Stream
http://code.google.com/p/garbagecan/source/browse/trunk/java/perf4jstudy/src/main/java/com/googlecode/garbagecan/perf4jstudy/LogParserUtil.java
另外在做这些调研的时候还试着使用了一下PipedInputStream和PipedOutputStream两个流
http://code.google.com/p/garbagecan/source/browse/trunk/java/perf4jstudy/src/main/java/com/googlecode/garbagecan/perf4jstudy/PipedIO.java
Monday, June 15, 2009
难用的ICM Performance JMX
Saturday, May 23, 2009
Bug Fix Plan
Just now, Excalibur_GUI and Unit_Test_Excalibur_GUI area has total 70 p1 + p2 bugs.
Note: This 70 bugs not includes the bugs that will be fixed once sprint2 project finish - 17 bugs
Sprint2 Bug fix plan:
Week | Dev Resource | Plan Dev Fixed | Plan QA Logged | Bug Number (approximation) |
Apr. 24 - Apr. 24 | - | - | - | 70 |
Apr. 27 - Apr. 30 (4 days) | 1.5 | 2 * 1.5 * 4 = 12 | 3 * 4 = 12 | 70 |
May. 4 - May. 8 | 3 | 2 * 3 * 5 = 30 | 15 * 5 = 75 | 115 |
May. 11 - May. 15 | 10.5 | 2 * 10.5 * 5= 105 | 15 * 5 = 75 | 85 |
May. 18 - May. 22 | 10.5 | 2 * 10.5 * 5= 105 | 10 * 5 = 50 | 40 |
May. 25 - May. 29 (4 days) | 10.5 | 1 * 10.5 * 4 = 44 | 10 * 4 = 40 | ??? |
Dev Resource:
Resource | Apr. 27 - Apr. 30 | May. 4 - May. 8 | May. 11 - May. 15 |
Chunlin |
|
| 100% |
Gang |
|
| 100% |
Jiangwei | 100% | 100% | 100% |
Lin |
|
| 100% |
Liyuan | 50% | 100% | 100% |
Chao |
|
| 100% |
Fanbin |
|
| 50% |
Hong |
|
| 100% |
Peng |
| 50% | 100% |
Xiaodong |
|
| 100% |
Yong |
| 50% | 100% |
SubTotal # | 1.5 | 3 | 10.5 |
Note: The resource does not include Wanqing.