There was an old woman who swallowed a fly [anti-pattern]

On many occasions I find myself humming this tune:

I'm sure there's another name for this anti-pattern, but it's a variation of yak shaving in which each progressive solution to a perceived problem becomes more imperfect and workarounds and unlikely solutions are progressively applied. Ultimately, the question often forgotten is "what was the original problem?"

I'll give the technical verision of what happens:

  1. Someone discovers that logging in to a web application isn't working for some users
  2. it's discovered the service that accepts userid and password is returning an error for what we believe to be a valid userid and password for these users
  3. digging further it's discovered that the code to validate userid and password is calling another service to load a user's customer record and this service is returning a new error
  4. when researching this customer service, it's discovered a new error started 2 weeks ago that seem to impact a small percentage of the user base
  5. when researching these particular users, it's discovered they were all created within the same 2 day window (years ago)
  6. when researching what happened at that time, it's discovered that there was a deploy that happened before and after the failing records were created
  7. Upon further investigation, it's discovered the first deployment introduced code that caused a different problem and the second deploy backed out a set of changes
  8. That it turns out, in addition to the problem that was known, caused the new problem
and so on and so on...

The reality is that this can progress in such a way that each new discovery requires some sort of change to diagnose and trouble shoot that ultimately causes new unknown problems that, when discovered, will have no clear path back too why the change was introduced in the first place and no way to know if it should be reversed. Worse yet, the original problem that you set out to solve is lost and often even forgotten.

The anti-pattern part of this is essential the "dark side" of following the Boy Scout Rule, which is too always leave things in a better state than when you arrived. The negative part of this is that it can be diffiicult too ignore little problems, but often because there are so many "little problems" that it defocuses your effort and attention from the "original problem".

In short, it is important to remember the task at hand and stop and think about "is this more important/necessary than what I was originally trying to do?" coupled with keeping track of "what did I set out to do and does this activity get me closer to my objective or not?".

Comments

Popular posts from this blog

Push versus pull deployment models

the myth of asynchronous JDBC

Installing virtualbox guest additions on Centos 7 minimal image