Monday, October 13, 2014

Software Reuse

Reading Response to Chapter 16
There are benefits and drawbacks to the reuse of existing software. All of the re-purposed code must be well documented, as it will likely be utilized by a developer who did not originally work on it. It must be well tested, so that it can be guaranteed to work correctly with the new code. The list goes on. Besides these requirements, the development flow changes in order to accommodate this reuse of code and software. This can be both a benefit and a drawback. On the positive side, you don't have to reinvent the wheel, as you have something pre-determined to use at your leisure. On the other hand, it can promote lazy coding (if it's already been written why write it again?) and create a hodge-podge of code in a stylistic sense. 

In my experience, I have rarely seen entire software systems reused, it's more often component or object and function reuse. The practice of re-purposing all of some software can result in redundant or under-utilized portions of that software being used and it is often more prudent to pick and choose functions or components specific to the new program's needs. 

Of course, sometimes it's just not possible to rewrite a feature multiple times and software reuse becomes a necessity. Take for example development for several platforms. Nowadays it's essentially a requirement to develop for web, mobile-web, iOS and Android. Because of the need to have consistency across platforms there will be a point where the same feature needs to be developed twice. At this point the technical debt may become too high, and code written for one platform must be reused to develop the same feature for another platform.

In some cases it may be better to rewrite the feature. Perhaps if the new platform is drastically different, the reuse of old code may result in too much time spent refactoring and testing.  

It essentially boils down to looking at the trade offs and evaluating the system-specific situation. One must identify the goal, the possible paths in order to complete this goal, and then measure the potential technical cost for each situation. Sometimes reusing code will be the best choice, and sometimes it won't. It's all about knowing the system.
 

0 comments:

Post a Comment

Powered by Blogger.
 
 
Copyright © Software Engineering
Theme by BloggerThemes. Design by Diovo.com. Edited by Laura Barber.