Stressful Situations Make You Stupid

By | May 12, 2010

Today we came across an interesting issue at work: we have two teams A and B who interchange API calls. Team A needed an API from team B to process a business that is owned by team B of course. The signature was like the following:

public OutputEntity MyMethod(List listOfIds);

It appeared afterward that this method was very slow, and the client was already very upset about the low performance, which consequently caused big pressure on the teams by the superiors to enhance the performance.
After investigating the issue, it appeared that the list of ID’s sent as input consists of some ID’s that do not need to be processed, this criteria of “not need to be processed” is a business owned by team B, done by using properties of the entities these ID’s represent. So the  solution to this issue was one of the following:

  1. Moving the business out of the API to the client application to do the filtering, since the calling method already has the entities themselves (not so good to move business out of scope!)
  2. Let the API do the filtering, but this will worsen the performance because the API will have to retrieve these entities from the database in order to use its’ properties!

So is that a dead end? actually that was stupid! the situation was stressful enough and pressured by our superiors to enhance the performance that we missed a very simple fact: pass the list of entities themselves!

Stressful situations make us stupid, so make as less stress as possible on your team, help them to be smarter.

3 thoughts on “Stressful Situations Make You Stupid

  1. Mohammad Shahrouri

    *sigh* I wish that we can eliminate superiors pressure then every thing will be done smoothly.
    and the worst thing in pressure and stress that it’s contagious and move down the chain till it reach the developers :( .

  2. Ahmad Abu Raddad

    Actually that pressure is the strogest drive towards finding the solution to your performance problem.

    But stress can be a negative thing yeah, and our superiors are adept with that lol.

  3. Emad Alashi Post author

    Well, I believe it’s never black and white, and there is always good and bad in everything.
    Pressure though should be managed in a way that successfully avoids such results. Not neglecting the facts of “adrenaline” for sure 😉

    Pressure vs Stress maybe

Leave a Reply

Your email address will not be published. Required fields are marked *