J
John Gagon
Ed said:Hi, John,
I'm not entirely sure what you mean by, "Guarantee certain metrics." Do
you mean, "Are the tool's metrics guaranteed to be correct?"
I believe yes. I notice you include a lot of the standard metrics that
I use in the various analysis views. I'm assuming that once one
achieves the Fractal Class Composition score of 1.0, that the metrics
for instability, for example would be zero (afferent/efferent
couplings) and cyclomatic complexity would all be at a certain optimum
or value. I'm guessing some might come in as perfect while others are
"fairly close" to an ideal value (like distance and abstractness). In
any case, I wonder if some metric limits are reached by achieving a
score of 1.0 perhaps as a function of number of packages and classes.
Well, we
use them in our work, and I know of two other shops that use them; but
would I sign an iron-clad, financially-punitive contract declaring that
the tool is free from all bugs and so the metrics are guaranteed to be
correct for all inputs?" Sadly, I would not. To date, however, there
have been few major complaints.
It's always hard to tell that one. Amount of money to risk seems to me
proportionate to perceived stability, I would think it would depend on
the amount in the contract.
I get the feeling, however, that this is not what you meant.
Do you still get the feeling? (as I lost what your pronoun 'this'
(above) might refer to other than generally my question about
guaranteeing of certain metrics)
I would be delighted to receive your corrections. Engineering has
withered my English language skills to the point where they must cart
around their own bottled oxygen with them, and still they wheeze and
splutter at the slightest grammatical exertion; I would appreciate any
comments you have. It's rare indeed that anyone volunteers so
surprisingly important a service.
I have sent them to you personally in a separate email.
and I like
Excellent point. I should make the source examples available as
downloads. Examples, in fact, are probably not enough; so as a gesture
of appreciation for your offer above, I'll open-source a full
application with a fractal index of a perfect 1.0. Give me a couple of
weeks to cobble together a program description; I'll post notification here.
Yes, that would be *very* useful. Very good idea there. I'll search for
it periodically in the future. Feel free to CC my email if you would
like me to look at it too. ;-)
but I noticed you have it
I'm fortunately unafflicted by perfectionism: I hear it can be tiresome.![]()
It sure can be. Well, a somewhat perfectionist, to be pedantic, is not
quite as bad as an absolute perfectionist though is it?
As with all metrics and as I'm sure you're aware, metrics should be
viewed with healthy caution. I'm not sure how much value can be gleaned
from pouring code that was designed without the fractal class
composition in mind into the Fractality code analyser because there are
many different methodologies that people use to maximise the OOness of
their system.
I use principles of keeping packages, classes and method sizes in a
certain range and I try to organize dependencies and in the past, I've
used a more bandaid approach using an open source tool call depfind
that searched the code for dependencies and spat out megabytes of xml
or html. As a maintainer of a mature codebase, this was more crucial
because stability was a primary goal at that point. Every code change
needed impact analysis and I would use the dependency checker run in an
ant script to find out the current dependencies and find the number of
other classes affected by the change. This preventative approach
reduces that need quite a bit. I used to work on this at HP before
offshoring and reduction of workforce occured with the incoming CEO
replacing Carly.
A fractal index of 0.58 does indeed suggest that a module was not,
"Programmed to an interface repository," and did not, "Eliminate
descendant dependencies;" but if these concepts were not used in the
construction of that module, then we're viewing the code from an angle
not considered by the designer: it's then perhaps no surprise that it
looks a little askew, but that doesn't imply that the code is poorly
designed; it's just designed in a way unfamiliar to an unbending code
analyser.
The code started out cleaner but then became more ratsnesty / spaghetti
and even with just myself programming it, it grew out of control since
I would work on it weekend to weekend since it was my own, on the side,
skunkwork/moonlighting project.
If, however, a module is designed from scratch with the fractal class
composition in mind, and yet still scores badly in Fractality, then we
can ask some drilling questions.
Yes. I plan on refactoring to this standard if only for future
maintenance. It will be a guiding principle for all others working on
my free open version. I'm writing a tool which I will soon publish on
Sourceforge and java.net and later, I will finish a commercial grade
version with extra features. My tool is something more related to
prototyping and quick model driven development similar to projects like
trails/ruby on rails etc but with one other design goal in mind besides
"do not repeat yourself". It's been a long journey but I've got about
60% completion right now. (I'm also working on a personal tracking tool
like xplanner but supporting more calendar and recurring functions)
John Gagon