We may earn an affiliate commission when you visit our partners.
Pluralsight logo

Advanced Defensive Programming Techniques

Zoran Horvat

This course will lead you step by step through the process of developing defensive design practices, which can substitute common defensive coding, for the better of software design and implementation.

Read more

This course will lead you step by step through the process of developing defensive design practices, which can substitute common defensive coding, for the better of software design and implementation.

How often do you have to defend from nulls, zeros, surprising cases hitting switch instruction, impossible else branches, and so on? Is your life a struggle with issues caused by unexpected data or invalid system state? In this course, Advanced Defensive Programming Techniques, you'll learn how to defend by means of design, so that almost all explicit defensive code can be happily removed. First, you'll discover how to build validation. Next, you'll explore how exactly to design a public interface. Finally, you'll cover how to unify error flows, so nothing unpredictable can take you by surprise. By the end of this course, you'll have the necessary knowledge to efficiently develop your own defensive design practice.

Enroll now

What's inside

Syllabus

Course Overview
Understanding Limitations of Traditional Defensive Code
Removing Corruption by Only Creating Consistent Objects
Removing Corruption by Only Making Valid State Transitions
Read more
Dismissing Defensive Code by Avoiding Primitive Types
Defining Function Domains as the Primary Line of Defense
Building Defensive Design Instead of Writing Defensive Code
The Principle of Working with Objects, Not with Nulls
Building Rich Domain Model as an Effective Defense by Design
Designing Alternative Workflows Instead of Defending from Errors

Good to know

Know what's good
, what to watch for
, and possible dealbreakers
Explores defensive programming techniques, a new and promising approach to design
Taught by seasoned professionals with a wealth of knowledge in advanced defensive programming techniques
Suitable for experienced software developers seeking to refine their design and implementation skills
Course concepts are highly applicable to various software development projects
Enforces a rigorous approach to defensive design, promoting clean and reliable code

Save this course

Save Advanced Defensive Programming Techniques to your list so you can find it easily later:
Save

Activities

Be better prepared before your course. Deepen your understanding during and after it. Supplement your coursework and achieve mastery of the topics covered in Advanced Defensive Programming Techniques with these activities:
Review purpose of defensive design
Review the fundamental need for defensive design to decrease the cognitive load of development work
Show steps
  • Read the course overview and syllabus
  • Watch any available videos or tutorials on defensive design
  • Write down a list of the benefits of using defensive design
Read Effective C++ by Scott Meyers
This book contains a number of insights into C++ programming that can be applied to defensive design
Show steps
  • Read the first three chapters of the book
  • Make notes on any interesting or relevant concepts
  • Apply these concepts to your own code
Identify common errors and vulnerabilities in code
Practice makes perfect and this exercise will sharpen your ability to spot potential problems
Browse courses on Defensive Programming
Show steps
  • Find a codebase with known vulnerabilities
  • Review the code and identify any potential issues
  • Suggest ways to mitigate these issues using defensive design techniques
  • Share your findings with the community
Five other activities
Expand to see all activities and additional details
Show all eight activities
Implement a simple defensive design pattern
Gain hands-on experience implementing a defensive design pattern
Browse courses on Defensive Programming
Show steps
  • Choose a simple defensive design pattern
  • Design and implement the pattern in a small project
  • Test your implementation to ensure it is working as expected
Attend a workshop on defensive design
Network with other professionals and learn from experts in the field
Browse courses on Defensive Programming
Show steps
  • Find a workshop on defensive design
  • Register for the workshop
  • Attend the workshop and participate actively
Develop a defensive design strategy for a specific software application
Develop a comprehensive plan for implementing defensive design in a real-world scenario
Browse courses on Defensive Programming
Show steps
  • Identify the software application to be analyzed
  • Gather information about the application's architecture, design, and implementation
  • Identify potential vulnerabilities and threats to the application
  • Develop a defensive design strategy to address the identified vulnerabilities and threats
  • Document the defensive design strategy
Mentor a junior developer on defensive programming techniques
Share your knowledge and help others improve their skills
Browse courses on Defensive Programming
Show steps
  • Find a junior developer who is interested in learning about defensive programming
  • Meet with the developer regularly to discuss defensive programming concepts and techniques
  • Provide feedback on the developer's code and help them to identify and fix potential vulnerabilities
Find a mentor who can provide guidance on defensive design
Seek out guidance from experienced professionals
Browse courses on Defensive Programming
Show steps
  • Identify the skills and knowledge you want to develop
  • Network with other professionals in your field
  • Attend industry events and conferences
  • Reach out to potential mentors and ask for their guidance

Career center

Learners who complete Advanced Defensive Programming Techniques will develop knowledge and skills that may be useful to these careers:
Data Scientist
Data Scientists are responsible for the design, development, and maintenance of data science models. This course may be useful in teaching you how to design and develop better data science models.
Machine Learning Engineer
Machine Learning Engineers are responsible for the design, development, and maintenance of machine learning models. This course may be useful in teaching you how to design and develop better machine learning models.
Software Engineer
Software Engineers are responsible for designing and developing computer software. They apply the principles of computer science and software engineering to the design, development, maintenance, testing, and evaluation of computer software and systems. This course may be useful in teaching you how to design and develop better software.
Database Administrator
Database Administrators are responsible for the design, implementation, and maintenance of databases. This course may be useful in teaching you how to design and implement better databases.
Web Developer
Web Developers are responsible for the design, development, and maintenance of websites. This course may be useful in teaching you how to design and develop better websites.
Network Administrator
Network Administrators are responsible for the design, implementation, and maintenance of computer networks. This course may be useful in teaching you how to design and implement better networks.
Cloud Architect
Cloud Architects are responsible for the design, development, and maintenance of cloud computing systems. This course may be useful in teaching you how to design and develop better cloud computing systems.
DevOps Engineer
DevOps Engineers are responsible for the design, development, and maintenance of DevOps pipelines. This course may be useful in teaching you how to design and develop better DevOps pipelines.
IT Manager
IT Managers are responsible for the design, development, and maintenance of IT systems. This course may be useful in teaching you how to design and develop better IT systems.
Software Developer
Software Developers are responsible for the design, development, and maintenance of software applications. This course may be useful in teaching you how to design and develop better software applications.
Systems Analyst
Systems Analysts analyze an organization's current business processes and then design and implement new or improved systems to meet the organization's needs. This course may be useful in teaching you how to design and implement better systems.
Security Analyst
Security Analysts are responsible for the design, implementation, and maintenance of computer security systems. This course may be useful in teaching you how to design and implement better security systems.
Software Architect
Software Architects are responsible for the design and development of complex software systems. This course may be useful in teaching you how to design and develop better software systems.
Computer Programmer
Computer Programmers write, modify, and test code that allows computer applications and software programs to run. This course may be useful in teaching you how to write better code.
Artificial Intelligence Engineer
Artificial Intelligence Engineers are responsible for the design, development, and maintenance of artificial intelligence models. This course may be useful in teaching you how to design and develop better artificial intelligence models.

Reading list

We've selected eight books that we think will supplement your learning. Use these to develop background knowledge, enrich your coursework, and gain a deeper understanding of the topics covered in Advanced Defensive Programming Techniques.
Offers 78 specific and proven techniques you can apply right now to improve the performance, maintainability, and correctness of your Java code.
Classic in the field of software engineering, providing timeless insights into the challenges and complexities of software development.
Focuses on the principles and practices of writing clean and maintainable code, which aligns with the goals of defensive programming.
Foundational work in domain-driven design, providing a comprehensive overview of the concepts and principles behind this approach.
Offers a comprehensive guide to software construction, covering all aspects of the software development process, including design, implementation, testing, and maintenance.
Provides a visual and engaging introduction to design patterns, making them accessible to beginners.
Provides a comprehensive overview of software engineering principles and practices, making it a valuable reference for students and practitioners alike.

Share

Help others find this course page by sharing it with your friends and followers:
Our mission

OpenCourser helps millions of learners each year. People visit us to learn workspace skills, ace their exams, and nurture their curiosity.

Our extensive catalog contains over 50,000 courses and twice as many books. Browse by search, by topic, or even by career interests. We'll match you to the right resources quickly.

Find this site helpful? Tell a friend about us.

Affiliate disclosure

We're supported by our community of learners. When you purchase or subscribe to courses and programs or purchase books, we may earn a commission from our partners.

Your purchases help us maintain our catalog and keep our servers humming without ads.

Thank you for supporting OpenCourser.

© 2016 - 2024 OpenCourser