Monday, April 27, 2015

What I learned from Agile Engineering training

Last week I took the 3-day "Agile Engineering Training" in TELUS, thanks a lot to our trainers from LeanIntuIt - Shawn Button and Declan Whelan.  I learned a lot from them.  The course covers TDD, Simple Design, SOLID principles, refactoring and dealing with legacy code.  The fun part is there are a lots of coding Kata, like Bowling Game, Gilded Rose, etc.  I am so glad to have an opportunity to learn those stuff, even actually I learned them since 10 years ago, this time I feel  this training is a kind of a review of what I learned since I decided to be a software craftsman.

Here is the mind map summarized of what I learned.


Add some thoughts:
  1. TDD/SOLID principles/Refactoring skills become more critical and in an Agile/Scrum team,  you have to be great, to be better so that you can deliver faster,  your code will be easier to change, easier to maintain;
  2. Simple Design -  it is summarized by only 2 points: fixing names and removing duplication. Combining with TDD's Red/Green/Refactoring cycle,  it means just repeating this 2 things with test cases, your complex code logic design phase will turn into many tiny steps which just renaming and removing duplication; if you can do it fluently,  the effort of thinking hard before hand becomes simple physical typing movements - which means you can design the code without thinking too much. This conclusion is so striking.
  3. Refactoring -  When I tried the Kata Gilded Rose (a simpler version which have all the tests before),  I really sense the power of simple design - refactoring by doing renaming and extract methods, then the business logic gradually emerged, and design pattern is emerged. For me it means as long as you have all the test cases, then you can refactoring the code without need to understand the business logic, and business logic will be more clear after you refactored.  That is another aha moment for me. Looks like code quality is a separate attribute beside the domain knowledge. If we apply this to code review, it means the good code should be enough understandable without understanding the business background first.

Resources:
  1. Four Elements of Simple Design, by JBrain
  2. Kata: Gilded Rose, this is a great Kata about refactoring, it worth trying more times

No comments:

Post a Comment