Costs of software maintenance are well documented. This compilation puts maintenance cost at more than 90% of total software cost. The same paper puts the cost of understanding the code at 50% of maintenance cost.
Currently there are no good tools to understand enterprise scale Java applications. Most of the reverse engineering tools generate the class diagrams, a static time view of the system. But when a developer is changing code, he/she is more interested in knowing how classes interact at runtime for a single use case. MaintainJ generates runtime sequence and class diagrams for a single use case.
Change is constant and everywhere - business changes, development teams change, enhancements and bug fixes involve changes, interfacing with new applications need changes, etc.
Change involves risk. Understanding reduces risk. MaintainJ significantly reduces the effort spent in understanding large Java applications.
Typically, developers depend on debuggers to analyze runtime interactions. Debuggers definitely help but diagrams are better for the same reason that managers prefer graphs to numbers.
Most of the currently available reverse engineering tools generate class diagrams and a static sequence diagrams. Generally, the class diagrams generated are not for a single use case. They are more for the entire system and are too cluttered to understand. Static sequence diagrams are generated from code and show the possible call flows starting from a method. This helps to understand the code structure to certain extent but do not help to understand the runtime behavior.
MaintainJ generates runtime diagrams for a use case and that is what
developers crave for while debugging a complex Java application.
In agile development environments, MaintainJ can also be used to generate always
up-to-date
UML documentation from code. MaintainJ is based on open source
Eclipse project and works on any IDE that is built on Eclipse platform.
Dynamic Binding - Dynamic or runtime binding in Java makes understanding code more difficult. Developers often need to understand the runtime object interactions for a specific use case either to debug or enhance the application. Dynamic binding helps in building very flexible systems but, at the same time it increases the time to understand the system. It is also common to employ multiple levels of dynamic binding, like a Vector containing another Vector, which further complicates the issue.
Observer Pattern - Many enterprise applications follow Observer Pattern for flexibility, where 'listener' (or observer) objects change model state besides 'listening' (or observing) for the state changes. When many such listener objects, which are often determined at runtime, change the model, it becomes hard to understand and debug a large application.
Multi-threaded Applications - Multi-threaded applications are always difficult to code and debug. Using MaintainJ, one can see the sequence of method calls happening in each thread in a neat sequence diagram. This makes debugging multi-threaded applications much easier.
Externalized Data and Rules - Externalizing configuration data as well as rule based logic to XML files is very commonly found in the present day Java applications. Very often, the logic to determine the runtime classes is soft-coded in xml files. In a not so well documented large-scale system, it is very hard to understand how the xml file drive the system.
Poor Design - Designing robust and flexible systems at the same time is hard. Maintaining them as the systems evolve is harder. If poor design slips into this equation, it becomes very hard to understand a system after 2-3 years from initial launch.
Here are some other scenarios where MaintainJ helps developers.
Complements Debugger - MaintainJ complements debugger rather than replacing it. By generating the class and sequence diagrams for a use case, it reduces the time spent in debugger. Unlike other reverse engineering tools, MaintainJ offers uncluttered and focused UML diagrams. For sequence diagrams, which get cluttered very easily, MaintainJ offers features like call folding to generate crisp diagrams.
During Code reviews - MaintainJ can also be used during code reviews. Rather than reviewing the entire source code, one can review the diagrams to find deviations from the design standards. Class diagrams showing the dependencies help to weed out unwanted dependencies.
For Agile Teams - For agile programming teams, MaintainJ provides always up-to-date documentation of the system. Useful UML diagrams can be generated whenever one needs them.