Building Dependency Webs in J2EE
Subject:   Transitive dependencies do not exist., and your graphs are useless
Date:   2003-02-02 16:41:27
From:   anonymous2
You state

"A complete Dependency Web includes all transitive dependencies; that is, A -> B, B -> C implies A -> C. "

This is not the case, A does not depend on C by your definition. There is no reference to C in A, in either the source or class file.

I would further argue, that your definition of dependency is very weak. And your example graphs are far from usefull artifacts.

You define "depends on" as simply reffering to another component in the source (you don't even consider the class file, but you should). Your definition does not account for the actuall demands that A will place on B. There are many contracts that exists between components, and dealing only with "reffers to" relationship is not usefull at all. You will typically end up with a highly interconnected graph. Espically if you draw the graph at the class level, as you have done.

Drawing such dependency graphs at a higher level, sucha as package, or even web application level will yield more usefull information. But like I said, these diagrams don't provide much information about contract and protocol. And I find there use highly suspect for this reason.

Full Threads Oldest First

Showing messages 1 through 2 of 2.

  • Transitive dependencies do not exist., and your graphs are useless
    2003-05-01 10:34:46  anonymous2 [View]

    Do you even understand what the word dependency means?

    if class A->B and class B->C then A->C is certainmy true, for a change in the interface of C might imply a change of the interface of B and hence of the interface of A.

    So before making a fool of yourself, think! And if these graphs are too difficult for you maybe you should start thinking of looking for another job, because it's exactly people like you that are making bad overly complex code due to a lack of understanding of dependency.
    • Transitive dependencies do not exist., and your graphs are useless
      2005-09-20 03:34:25  Janick388 [View]

      I absolutely agree.

      In my experience the biggest single factor which leads to high quality, easily maintainable software is an understanding the importance of dependency relationships.

      High quality software should not exhibit any dependency cycles (not just between packages, but between classes within packages too). This is a key principle and the most important difference between software 'engineering' and simply hacking out code.

      For me but the crunch point came several years ago when I ran the source code for my current project through a dependency analysis tool. The code written by the senior developers on my team was 100% free of cycles - but mine was not. Consequently I had to recode everything I had written before anyone else noticed! Since then I have not looked back.

      Unfortunately, most software is not well engineered when you run it through a dependency analysis tool - but then high quality software engineering seems a pretty rare thing.