iteration

Tracer bullets

Episode Summary

This chapter is truly about a "pragmatic" approach to development - We discuss duplicating knowledge throughout systems, insulating projects from their changing environments, gathering requirements and implement code at the same time, how to give project estimates

Episode Notes

Chapter 2 - A Pragmatic Approach

Overview = combine ideas and processes

  1. duplicate knowledge throughout systems
  2. don't split any one piece of knowledge across multiple system components (orthogonality)
  3. insulate projects from their changing environments
  4. gather requirements and implement code at the same time
  5. how to give project estimates

This chapter is truly about a "pragmatic" approach to development


Tip 11: Don't Repeat Yourself

Duplicated code arises differently:

  1. imposed: devs feel they have no choice
  2. inadvertent: devs don't realize they are duplicating
  3. impatient: devs got lazy because it seems easier
  4. interdeveloper: multiple people on a team duplicate a piece of info

we call these the "four i's"


Tip 12: Make it easy to reuse

TWO OR MORE THINGS are orthogonal if changes in one do not affect any of the others

i.e. database code will be orthogonal to the UI. you can change the interface without affecting the database

driving stick shift is not orthogonal
helicopter controls are not orthogonal

bottom line: non-orthogonal systems are hard to maintain


Tip 13: Eliminate Effects Between Unrelated things

You get two major benefits if you write orthogonal systems: increased productivity and reduced risk.

ways orthogonality can be applied to your work

if i dramatically change the requirements behind a particular function, how many modules are affected?

Toolkits and Libraries

Testing

An orthogonally designed and implemented system is easier to test. Because the interactions between the system's components are formalized and limited, more of the system testing can be performed at the individual module level. This is good news, because module level (or unit) testing is considerably easier to specify and perform than integration testing.

Reversability

Nothing is more dangerous than an idea if it's the only one you have.

Writing more orthogonal code allows you to more easily reverse changess or eb and flow with the needs of the project.

Bottom line: orthognality is about reduction of interdependency among system components


Tip 14: There are no final decisions

instead of carving decisions in stone, think of them mroe as being written in the sand at the beach. A big wave can come along and wipe them out at any time.


Tip 15: User Tracer bullets to find the target

when firing a machine gun in the dark, you either:

  1. calculate everything and make a precise shot
  2. or use tracel bullets.

Tracer ammunition (tracers) are bullets or cannon caliber projectiles that are built with a small pyrotechnic charge in their base. Ignited by the burning powder, the pyrotechnic composition burns very brightly, making the projectile visible to the naked eye. This enables the shooter to follow the projectile trajectory to make aiming corrections.

tracer code is not disposable. you write it for keeps. it contains all the error checking, structuring, documentation, and self-checking that any piece of production code has. it simply is not fully functional

Picks