Velocity

The benefit of using Velocity
1. The most important benefit is decrease the maintenance cost.
 It’s no need to looking into the java code to see what is the SQL or HQL we are using, changing one place will resolve the same problem.
 In addition, it will reduce the duplicated code, any place want to using the same SQL or HQL can just located to the VM file(Velocity template).
 The SQL and HQL script are easier to maintenance, if some tuning operation need to take on them, the only thing is to look into the script folder and investigate each SQL or HQL to see whether it has some performance issue.

2. The performance are more stable than before
 Currently, we are manually append the SQL and HQL in JAVA code. The performance are depend on the complexity of the logic. By using Velocity, the template are relatively stable. Given the parameter and check the condition will generate the different result. Later it will be shown in an example.
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值