Top 10 Project Killers

I could not resist to post what I have found on straw-dogs.co.uk

There is a short article entitled “Top 10 Project Killers”, in which the author enumerates some hot points from the “life” of a project, which are most likely the sources of most  project failures…

Here what the author  found until now:

1. Excessive Promises

2. Change

3. Lack of Communication

4. Inexperience

5. Lack of Planning

6. Lack of Priority

7. Relying on a Due-Date

8. Hardware

9. Ignorant Managerial Interference

10. Insufficient Resources

Nice list, I agree 100% with it.

I mostly like the “Titanium Rocket Car” part ;-) . So…so true….

Read the whole article here.

Topic of the day: “Don’t develop for living and you will be a better developer”

Finally someone who dares to say the truth:

Just read the following article:

http://blog.konem.net/java/index.php?blog=1&title=don_t_develop_for_living_and_you_will_be&more=1&c=1&tb=1&pb=1

…now sit back and think for a while…

What do you say?…is this true?…or can it be true?

….

Concerning me…I have to say that I have taught, and still thinking a lot, about changing my day job(as a developer) for something else…I kind of feel that I reached a point from where there is no up-wards movement, just downwards…

I feel kind of tired writing code, not developing, writing code…day by day… I actually don’t feel that it is fun anymore…it became A JOB…it lost its charm… and that is kind of sad…

Maybe it is time to develop also some other skills and after that start departing from the SW development as a day job and concentrate on something else, and maybe the SW development will become again a passion…as it was before…

What you opinion about this?

Happy coding

Breaking the Law of Demeter…

Hy all,

Remember Law of Demeter? Wel, here is what is it about (transcript from Wikipedia):

“The Law of Demeter (LoD), or Principle of Least Knowledge, is a design guideline for developing software, particularly object-oriented programs. The guideline was invented at Northeastern University towards the end of 1987, and can be succinctly summarized as “Only talk to your immediate friends.” The fundamental notion is that a given object should assume as little as possible about the structure or properties of anything else (including its subcomponents)…..

When applied to object-oriented programs, the Law of Demeter can be more precisely called the “Law of Demeter for Functions/Methods” (LoD-F). In this case, an object A can request a service (call a method) of an object instance B, but object A cannot “reach through” object B to access yet another object, C, to request its services. Doing so would mean that object A implicitly requires greater knowledge of object B’s internal structure. Instead, B’s class should be modified if necessary so that object A can simply make the request directly of object B, and then let object B propagate the request to any relevant subcomponents. Or A should have a direct reference to object C and make the call directly. If the law is followed, only object B knows its own internal structure.

More formally, the Law of Demeter for functions requires that a method M of an object O may only invoke the methods of the following kinds of objects:

  1. O itself
  2. M’s parameters
  3. any objects created/instantiated within M
  4. O’s direct component objects

In particular, an object should avoid invoking methods of a member object returned by another method. For many modern object oriented languages that use a dot as field identifier, the law can be stated simply as “use only one dot”. That is, the code “a.b.Method()” breaks the law where “a.Method()” does not.

The advantage of following the Law of Demeter is that the resulting software tends to be more maintainable and adaptable. Since objects are less dependent on the internal structure of other objects, object containers can be changed without reworking their callers…..” (read the whole thing here)

Following this today I rad into an interesting article called Dependency Injection Myth: Reference Passing which lead me to another interesting reading:
Breaking the Law of Demeter is Like Looking for a Needle in the Haystack.

After I have read these it made me thinking about how true the facts are…

These days I am working on a middle ware project which consists in implementation of a communication layer between a third party application and the product developed by my company. Challenging indeed, but there is small problem… I have already implemented almost 80% of what the mw needs to do bu I am facing the problem of how to make a test suite to validate what I have done.

After spending some time to think about it, more and more I have the feeling that I have done something wrong…I made something almost untestable, or at least testable but requiring a whole bunch of work to implement a real test suite…hmm. I think I am kind of near the haystack thing mentioned by MiÅ¡ko Hevery in his post…

I think its time to sit back and revise the thing… to make sure that it complies with the Law of Demeter, and after that rethink the testing startegy.

Have ever been in this kind of situation? Did you managed to make something so hardly testable that the effort of implementing a test suite would be to high?

Well welcome in the club…

Until next time…

Happy coding, and happier testing ;-)