Discover this podcast and so much more

Podcasts are free to enjoy without a subscription. We also offer ebooks, audiobooks, and so much more for just $11.99/month.

#5 Design Patterns: What's Their Connection to Fundamental Design Principles?

#5 Design Patterns: What's Their Connection to Fundamental Design Principles?

FromInspect and Adapt


#5 Design Patterns: What's Their Connection to Fundamental Design Principles?

FromInspect and Adapt

ratings:
Length:
40 minutes
Released:
Dec 17, 2019
Format:
Podcast episode

Description

Construx Principal Consultant Steve Tockey and Mark Griffin discuss design patterns in a unique way by emphasizing the importance of understanding fundamental design principles when you’re using patterns.Of the top five reasons that software projects get into trouble, the most significant issue that is directly under the control of software developers is the complexity in the code base. Both industry data and Steve’s own engagement-derived data over 20 years of software consulting support this. As Steve McConnell has argued, the prime directive of the software professional is to manage complexity.Steve and Mark dive into specific kinds of code complexity—such as cyclomatic complexity, depth of decision nesting, fan out, and number of parameters—and describe the fundamental design principle related to complexity: minimize overall complexity by balancing local and global complexity. Without measuring complexity in your code base, you can’t actually effectively control it. By measuring it, you can achieve the balance of complexities that most significantly decreases your code’s overall complexity.Steve and Mark continue by listing the fundamental design principles Steve covers in his design patterns training so as to begin to address a key question: Why is understanding the fundamental design principles important if you’re using design patterns? The list of principles applies across a broader spectrum of software creation than the SOLID principles do. Steve’s list causes you to pay attention to software attributes that you wouldn’t pay attention to if you were using only the SOLID principles.Steve argues that you can’t deeply understand what a pattern is up to unless you understand why the pattern looks the way it does. Each software pattern is primarily driven by a fundamental design principle and can be influenced by other fundamental design principles. For example, the Strategy pattern is primarily driven by the encapsulation principle and is influenced by Liskov substitutability and cohesion and coupling. Understanding the connections between design patterns and design principles vastly deepens your understanding of the patterns and their applicability.The episode ends with a thorough discussion of another fundamental design principle: encapsulation, which is achieved only via Design by Contract. The difference between code syntax and code semantics enters the discussion to help explain how code contracts operate. You have to get beyond syntax to achieve higher quality code with fewer defects, which are semantic inconsistencies. Compilers are ruthless masters of syntax but can’t help with code semantics.Links to Steve Tockey’s books:How to Engineer Software: A Model-Based Approach (Wiley-IEEE Computer Society Press, 2019)Return on Software: Maximizing the Return on Your Software Investment (Addison-Wesley Professional, 2004) 
Released:
Dec 17, 2019
Format:
Podcast episode

Titles in the series (47)

World-class software development requires far more than language/platform expertise and steady sprints. Join us as we describe time-tested, industry-proven software best practices at the team, organization, and leadership levels, sharing examples from recent engagements with software teams of all sizes.Construx is led by industry leader Steve McConnell, author of Code Complete and More Effective Agile. Software experts first and software trainers and consultants second, our team has seen what works and doesn’t work in hundreds of software organizations.Host Mark Griffin spent the first half of his career as an electrical engineer doing silicon hardware design and leading software automation teams. He moved into the sales side of software because he wanted to spread the value of what his company was building. It was supposed to be a one-year assignment that turned into the second half of his career. His balance of deeply technical skills and right-brain artistry also makes him a masterful home brewer!