Monday, February 6, 2012 7:31

Posts Tagged ‘Architecture’

DRY Your Code

DRY Your Code

Sunday, November 1, 2009 8:00

Don't Repeat Yourself (DRY, also known as Single Point of Truth) is a process philosophy aimed at reducing duplication, particularly in computing. The philosophy emphasizes that information should not be duplicated, ...

This was posted under category: Architecture  |  Read Full Story  |  0 Comments

DAO层单元测试

Friday, February 27, 2009 16:41

对于一些框架软件,例如springframework来说,要测试的是API实现的逻辑,这种情况下大量mock隔离其他对象的影响是必要的。但是对于我们应用程序,特别是数据处理型应用,你不测试数据库访问,根本就等于没有做测试。换句话说测试DAO就是在测试你的Hibernate映射关系有没有配对,你的HQL查询有没有写对,这一Mock,要测试的真正目标根本就没有达到。   这种DAO测试诚然就是集成单元测试,其实就是对于Web Action测试,我也曾经一度认为应该mock service来测试,但是现在我已经不这样做了,而是真正初始化webwork的容器注入真正的service对象来测试了。因为...

This was posted under category: Architecture  |  Read Full Story  |  1 Comment

Elegant Software

Friday, February 27, 2009 16:31

When I write code, elegance is something I aspire to, and in some senses goes hand-in-hand with beautiful code, but that doesn't really make it any clearer. Certainly, I think there is a strong element of "elegance is ...

This was posted under category: Architecture  |  Read Full Story  |  0 Comments

Single Sign On

Friday, February 6, 2009 17:24

Single sign on is a session/user authentication process that allows a user to provide his or her credentials once in order to access multiple applications. The single sign on authenticates the user to access all the applications he or she has been authorized to access. It eliminates future authenticaton requests ...

This was posted under category: Architecture  |  Read Full Story  |  1 Comment
Code Quality Checklist

Code Quality Checklist

Thursday, January 1, 2009 8:00

1. Every fixed defect on a deployed product has tests added to prevent regression. The worst thing you can do in this business is to have the same problem twice. Prevent it - our clients and users will usually ...

This was posted under category: Architecture  |  Read Full Story  |  0 Comments