The Lost Decades
A friend claims that software design evolved as an engineering disipline due to the move from waterfall SDLC (systems development lifecycle) to the agile project management process. He claims that the move from waterfall SDLC to agile methodology is what propelled application design from monolithic style applications to modular code that works with unit testing frameworks.
The first reference to SDLC dates to a 1968 software conference (https://en.wikipedia.org/wiki/NATO_Software_Engineering_Conferences) and ironically, waterfall SDLC was not proposed as a methodology that would succeed but rather it was presented as the antithesis of a workable methodology. His thesis is that methodology impacted the design of application code, pushing it from monolithic to modular. I too am interested in how the style of application code evolved from monolithic programs to modular code. Was it a top down movement driven by methodology or did programmers develop new goals for the code they wrote, going from writing perhaps 10,000 line programs to developing modular code and then to developing and deploying modular components?
Are Modern Apps Produced by Modern Methodology?
Corporate IT relies on SDLC. When the IT governance process requires SDLC design documentation then rest assured, it will be produced. The design diagrams may be Data Flow Diagrams or UML or sequence diagrams.
The Beginning
When programmers who knew assembler were given high level languages in the sixties and seventies, the programmers continued doing as they had done before. What programmers had done before was compare two values (is the amount of the customer's check equal to the amount due?) and depending on the result, jump to the label that identified the code for either paid in full or add to balance owed. Because the new high level language included GOTO which the programmers could substitute for JUMP, the programmers could continue with the habits they were accustomed to and program structure did not change much despite the use of the new language.
Assembler Compare and Jump Instructions | explanation |
---|---|
CMP A,B | compare A to B |
JE | jump if equal |
JNE | jump if not equal |
JG | jump if greater |
JGE | jump if greater or equal |
JL | jump if less than |
JLE | jump if less or equal |
The Rise of Structured Programming
From the mid-1970s to the mid-1990s, most IT developers learned what was considered the proper style of programming from Ed Yourdon’s books. He was the first popular advocate of Structured Programming or what was then often called "GOTOless programming". Besides banning the use of GOTO, structured programming consisted of two things, use of structured control statements (IF-ELSE and DO-WHILE) and the idea that programmers should use subroutines. Use of subroutines resulted in modular code. Structured programming constructs were introduced in COBOL in 1974 and in RPG with the release of RPG III in 1978. Microsoft’s QuickBASIC, introduced in 1985, had structured programming constructs.
The Impetus For Something More
IBM introduced its desktop computer, the PC, in 1981 and sales exceeded IBM’s expectations by 800%. The IBM PC was the catalyst that in the early 1980s filled the largest university auditoriums with students enrolled in intro to programming classes. These students bought Yourdon’s Structured Programming text and they learned structured programming (IF-THEN-ELSE, DO-WHILE) and modular programming (subroutines). Structured programming was taught in the workplace as well. One incongruous fact from that time stands out, program size was never an issue; ten thousand line programs did not warrant attention other than, perhaps, a pat on the back.
Designing Architecture
In the mid-80s and earlier, programs almost always ran on the machine where the data was. That may have been a PC and a floppy disk or a green-screen program and a mainframe. Then, around 1990, offices bought and installed Microsoft SQL Server DBMS and attached PCs to LANs and programmers wrote FoxPro, VB and PowerBuilder programs that interfaced with the database server over the network. This architecture where the components weren’t all in one box was a new paradigm for the majority of programmers. For many, this was the first time they had to think about the individual hardware components their code ran on, the GUI code on the desktop and the SQL on the remote server.
New Challenges, New Tools, New Concepts
Despite having been the most popular author of textbooks for entry level programming courses for two decades, Ed Yourdon is probably most remembered today for his 1990s books, "The Decline and Fall of the American Programmer" (1992) and "The Rise and Ressurection of the Americn Programmer" (1996). The second book was an acknowledgement of the erroneous conclusions of the first, that he had overlooked how modern tools like those of VisualBasic (1991), Powerbuilder (1991) and Interface Builder for NextStep IDE (1988). With these new tools came new concepts.
Extending Utility
The help system in Visual Basic's IDE included code snippets and instructions identifying the which procedure in which to place it. NextStep's Interface Builder generated code as the mouse was used to draw lines between visual components and code.
Conclusion
Spaghetti code, as it was originally, is generally a thing of the past.