Dependency Injection Principles, Practices, and Patterns
Y**E
Fast delivery.
Fast delivery! Book came intact
J**Y
Writing loosely coupled and maintainable code
When the first edition of the book was published, I couldn’t comprehend how a discussion about dependency injection justified 500+ pages. In fact, it wasn’t entirely clear to me why a book was needed at all. Surely, this is a topic that could be covered by a few articles, with any gaps filled in on StackOverflow?Since then, this has become required reading for my software development staff. There are two realizations that informed this.The first is that there are a LOT of misunderstandings about dependency injection out there, with quite a few otherwise-reliable sources promoting “best practices” that, ultimately, introduce complexity without necessarily solving the underlying problems. When you go down this rabbit hole, and attempt to make sense of conflicting guidance, two names ultimately emerge from—and stand above—the confusion: Mark Seemann and Steven van Deursen. Consistently, they provide comprehensive, deeply-considered, and rational guidance that not only demonstrates a depth of knowledge, but also establishes a framework, vocabulary, and set of heuristics for thinking through dependency injection challenges. Together, they are the authoritative source on the topic, and this book neatly collates hundreds of articles and StackOverflow responses they’ve made on the topic over the last decade. The book will not only answer your questions, but also address real-world challenges you haven’t yet discovered.The second is that this isn’t actually a book about dependency injection. It is a design patterns book about writing loosely-coupled and maintainable applications. It is true that it frames this primarily in terms of dependency injection—and, thus, the title of the book. But what the authors recognized is that many of the misunderstandings about dependency injection actually represent more fundamental misunderstandings about software design. As such, instead of simply providing guidance on dependency injection, this book carefully lays out the various approaches people take to solve the underlying problem, how those ultimately fail, and then examines the various design patterns that help address them. In doing so, the book ends up offering a surprisingly practical and approachable exploration of common design patterns.This is one of those books that will, as you read it, inspire you to refactor your past projects, and immediately change how you approach new code. And not (just) because you’ve leaned a new set of tools or even techniques, but because your knowledge and understanding of fundamental software development practices will have matured. Instead of simply prescribing a set of approaches, this will change how you think about the software design and development.From this perspective, the second edition is a welcome and impressive update. Yes, it overhauls the technical content to accommodate .NET Core, if that happens to be your framework of choice. More importantly, though, it fully embraces the above perspective, and reorganizes the content around design patterns. The new material on aspect-oriented programming and domain events, in particular, is masterfully presented, and really solidifies (SOLIDifies?) its broader relevance. Further, the guidance regarding what patterns (and tools) to use in which situations has continued to improve, and is both clear-headed and actionable.Indeed, even if you’ve recently read the first edition of the book, the second edition might well be worth picking up simply for chapters 6, 10, 11, and 12, in particular. (Chapters 10 and 11 are entirely new material; Chapters 6 and 12 have been updated considerably.)[Disclosure: I was a technical reviewer—an independent, unpaid role—for this edition. I have no commercial interest in the book.]
S**N
A must read for all software developers
I thought I knew what dependency injection was until I read this book. The authors broke the concept down to its core and I finally understood the 'why' of DI, not just the 'how'. The authors then built my knowledge up again, first using a 'no-framework' implementation and then using common .Net DI frameworks. I now heartily recommend this book to any software developers who want to go from the doing to the understanding.
A**B
Highly recommeded for .Net Developers and Architects
DI is quite misunderstood topic, but authors explained them in depth. They explained these concepts without using any frameworks. Chapter 4 provides a good pattern decision process, while chapter 5 and 6 are really helpful for intermediate developers, not only author shows anti-patterns, but also refactoring techniques to overcome them. I personally got a lot of insights from refactoring and various design alternatives.
A**A
Fantastic book
This book did a great job explaining various topics that are so important when working with dependency injection like DI anti patterns, Code smells, and some techniques when it comes to manage lifetime of the dependencies. Examples are also very good and helps to understand the concept author tries to explain.Highly recommend this book.
C**N
Una de las mejores compras que he hecho sobre libros de diseño y desarrollo
Un libro imprescindible para entender y poner en práctica la inyección de dependencias. Todo lo que se trata aporta siempre algún concepto, visión o práctica interesante... Es estratosférico!!!
F**R
Good one
Highly recommended if you are using DI in your project.
R**J
Wrong vs Right way to design and code explained in detail
Good example of how to design an application.Covers much more than DI and guides us on design principles, etc.Simplest and easy example gives you easy to understand
J**N
Worth a read
Really good book with some great info. Even if you already know about DI, the latter half of the book goes into other related subjects which every dev should learn!
Trustpilot
1 month ago
2 months ago