|
AntiPatterns identify mistakes
committed in software development and offer the
right solutions, writes
Dr R Srinivasan
IN software development a single
design occurrence is an event; two of them are
a coincidence and three occurrences lead to a
'pattern'. We mentioned that if we do not study
Design Patterns, we will not be able to improve
them and hence it will be very difficult to come
up with an improved version in future. However,
Thomas Mowbray and Rapheal Malveau in their book,
'Software Architecture Bootcamp' point out that
Design Patterns have more stringent requirements
for documenting knowledge while they should represent
proven solutions, not merely wishful thinking
about how software development should be done.
We may wonder about such comments particularly
after describing the advantages of following the
philosophy of pattern-oriented software design.
The reason is that Patterns illustrate the cases
only from successful projects where nothing is
brought out on the cases of patterns of failures.
As Jim Coplein says, it is useful and very important
to show the presence of Patterns in unsuccessful
systems also. Moreover, Design Patterns start
with a lengthy discussion on the situation, context
and forces that lead to a unique solution. We
have mentioned in an earlier article that there
is no steady state in software development and
so no classroom lecture or seminar or books can
define many variables that exist for any given
time. In practice we find that the books on Software
Engineering do not and cannot say, "What
do I do when something goes wrong and how to avoid
this problem in future". It is therefore
essential that we should be able to track the
results of negative solutions thereby making us
aware of what does not work. The identification
of what to avoid is a critical factor in successful
software development. This is where another approach
called AntiPatterns is introduced. AntiPatterns
represent the latest concept in a series of revolutionary
changes in software development.
AntiPatterns start with situations
that occur in practice and highlight the potential
consequences leading to intriguing situations
instead of abstract forces as in the case of Patterns.
AntiPatterns will lead us to identify mistakes
committed in software development. By elaborating
the symptoms and consequences of implementing
the bad solution. AntiPatterns will offer a re-factored
solution for the successful software development.
To quote Brown, et. al from their book 'AntiPatterns
- Refactoring Software, Architectures and Projects
in Crisis', while Patterns help us to identify
and implement procedures, designs and codes that
work, AntiPatterns do the exact opposite; they
let you zero in on the development detonators,
architectural tripwires, and personality booby
traps that can spell doom for the project. AntiPatterns
will also be able to identify the so-called good
solutions applied under the wrong context or situation.
Thus AntiPatterns may be considered to be a fall
out of Patterns, focussing on the wide and ever
growing occurrence of repeated software failures
in the effort to understand, prevent and recover
from the failures. By making use of the proper
tools in this new methodology, a welcome service
to the software industry emanates because AntiPatterns
will effectively describe measures to be deployed
at every stage of software development like design,
execution and management.
A question may arise in the minds
of many software developers and project managers
whether such topics and new methodologies like
AntiPatterns are essential to take note of and
follow. The answer is an absolute yes, because
of the following reasons: in the real world we
have been witnessing bad software designs, wrong
decisions by the managers, inadequate test procedures,
noncompliance to quality aspects, etc. Consistent
reasons, common misunderstanding of the context
and classic mistakes lead to bad designs and bad
software. Through AntiPatterns we will be able
to identify the reasons for such mistakes and
failures on time to prevent serious consequences.
It is possible to unearth the truth about deficiencies
of commercial off the shelf methods that may be
infected with defects, contradictions, and false
promises. AntiPatterns will pave the way for explaining
how a software project should be executed and
warn against negative software practices with
respect to change management, etc.
So to summarize, AntiPatterns
will describe the proper measures to be taken
in software development and like their design
counterparts, they provide the industry vocabulary
for the commonly occurring defective processes
and implementations. Once an AntiPattern is correctly
identified, we can derive refactored solution
to make the project become successful. We will
discuss different classifications of AntiPatterns
in the next few issues.
(To
be continued)
(The
author is Chief Technology Officer, Internet Component
Management Group, Bangalore and can be contacted
at: r.srinivasan@iCMGworld.com)
|