Wednesday, September 2, 2015

为什么应该在团队内完成整个开发生命周期

经常听到有人说,数据库很重要,所以应该有一个经验丰富的团队来把关。架构很重要,所以应该由一些架构师来统筹。

先不说这些高级团队到底能做到多大改善。但这种组织架构会带来致命的问题——组织的开发速度上限受限于这些高级团队,甚至是效率最低的那个。




如图,首先问题是,这些团队会在整个开发流程中成为瓶颈,我们无法通过横向扩展团队来提升组织的开发速度。这对软件产生价值的组织来说是致命的。

第二个问题是,开发中的沟通成本大量增加,团队间的沟通成本会远远大于团队内的沟通成本。如果功能开发团队依赖于大量其他团队,就会使整个开发成本变高,价值流速度降低。

第三个问题是,核心团队成员需要长时间培养,人员流动往往会造成致命的打击,就好像组织中有一根软肋,如果竞争花钱把某一个核心团队成员全部挖走,该组织可能会立刻消失。

由此可见,为了保持某些看起来很重要的东西(比如数据库,架构)运行良好,就让专业团队去做的想法有很多致命问题。

那怎么样才是好的实践呢?



特性团队 + 微服务

团队自己负责所有事务,从一开始就避免大型数据库和大型架构的设计,每个功能根据自己的需求,完成相应的服务设计、开发、测试、部署和上线。如果需要修改其他服务,也由该团队自己完成。通过自动化测试去保障质量,而不是由某个高级团队。

如果遇到遗留系统怎么办?

因为遗留系统可能没有足够的自动化测试去保障质量,所以首选的一定不是去修改它。把遗留系统API化,给遗留系统补测试,把一部分功能拆出来另外实现,都是我们常用的方法。
当然,我们还是避免不了去修改它,这种时候,修改还是由团队自己来完成,因为没有人能代替你去理解业务,没有人能代替你提供实现方案。只是团队需要自己足够谨慎,通过增加对遗留系统的了解以及找曾经在系统上工作过的人沟通,从而具备修改它的能力。



总之,指望把当前团队解决不了的问题扔给另一个团队去解决是不靠谱的,我们应该提升团队能力,使该团队具备解决问题的能力,而不是把希望寄托在别的团队上。

Thursday, July 16, 2015

Never register a domain on oray.com

Oray has a terrible service.

First, they require me to upload a photo within a personal ID by email and mention that the DNS would be affected if I don't upload the photo.

Second, I tried to transfer my domain out but there is on way to do that by myself. They don't provide the service in their web site. And they still require my to send a mail which include a hard copy of my personal ID and an additional paper form to their office. And they won't pay the fee of the mail.

Third, I made a phone call to their service centre. They told me the only way to transfer my domain out is to fill the additional paper form and send it to them with a hard copy of my ID. They had nothing to do.

Last thing is they never mentioned these above until I tried to transfer my domain out. Which means I was informed 5 years later after my first payment for my domain.

So at last, I try to get my auth-code through ICANN. The address of complaint page is below:

Hope this could help anyone who has the similar trouble with me.

Be away from these terrible registrars.


Wednesday, May 20, 2015

Surprise by the new html5 and css3 technologies

Recently I joined a course about how to do a UI design.

Here's the showcase.
https://heaton.github.io/week3/ (not available for IE and old Browsers)

These pages are all made by pure css 3 and html 5 with a little jQuery code for click events and touch events.



Friday, May 15, 2015

Git Tips

Shorten your Git commands - Alias

git config --global alias.[name] "command"

Examples

git config --global alias.st status
git config --global alias.co checkout
git config --global alias.br branch
git config --global alias.ci commit
git config --global alias.cob "checkout -b"
git config --global alias.back "checkout master"
git config --global alias.cof "checkout --"
git config --global alias.pl "pull --rebase origin master"
git config --global alias.plf "!git stash && git pl && git stash pop" # ! means runing the command as shell command
git config --global alias.lo "log --graph --oneline"
git config --global alias.l "log --pretty=format:'%C(yellow)%h %C(red)%ad %C(green)%d %C(reset)%s [%C(blue)%an]' --date=short --graph"

A better git log tool - tig

TIG

install

brew install tig

Get commit from other branchs - cherry-pick

cherry-pick
git cherry-pick [CommitID]
git cherry-pick --no-commit [CommitID] # 把commit内容放到本地的cache里面
You can test cherry-pick on GitStudy.

Find commit which you force deleted - reflog

Git won’t really delete any commit even you use git reset --hard HEAD^. You can get it back by reflog.