Robert "Uncle Bob" Martin - Architecture: The Lost Years
Why Stack Overflow recommends it
Stack Overflow users link it when answering questions about clean architecture, domain entities, and keeping frameworks and databases as details rather than the core of an app.
Recommended by 2 people across 2 different months, 2017 to 2021.
What it is
A 2014 conference talk by Robert C. "Uncle Bob" Martin on software architecture, arguing that architecture should be driven by use cases and kept independent of frameworks, databases and delivery mechanisms. It was recorded at a Handybook Tech Talk in NYC and is about 96 minutes long.
What people said
Recommends René Link · 2020-08 · Stack Overflow · on “Annotations in domain objects with JPA violates Database is a detail”
Yes, these annotations are details and should be kept away from the entities of the clean architecture. Don't be confused about the name entity in the clean architecture and the @Entity annotation from your persistence framework. They are different things. There is a video [LINK] of Uncle Bob about clean architecture and at the end he makes it really clear, because he says: the entities are not instances of database tables. They are usually constructions from many database tables. In another video [LINK] he talks about dependency injection and the annotations that these frameworks use. Well, dependency injection has nothing to do with persistence that you asked for, but this video makes clea
Recommends user9455607 · 2021-04 · Stack Overflow · on “PHP/MVC/PDO - beginTransaction outside of Database class”
Some suggestions: [a] You shouldn't create objects (with "new" ) inside class methods. Instead you should inject existent instances into constructors/setters. This is named dependency injection and can be applied with a dependency injection container . Dependency Injection and Dependency Inversion in PHP - James Mallison - PHPTour 2017 Nantes [LINK] PHP-DI The dependency injection container for humans [LINK] [b] Indeed, inject a single PDO instance in the constructor. Injection is the job of the DI container. For example, in PHP-DI [LINK] : return [ 'database-connection' => function (ContainerInterface $container) { $parameters = $container->get('database.connection'); $dsn = $parameters['ds
Cites albert · 2017-12 · Stack Overflow · on “How to upgrade a Symfony 3 bundled application to a Symfony 4 bundle-less one?”
Symfony and bundles Symfony 2 mentioned "Bundles is a 1st class citizen in the symfony framework". So it was a bit opinionated framework where everything was a bundle even your app. Later on the good practices recommended that a bundle should be only the reusable components of your app but we keep using bundles for everything to organize code. This has created that lots of developers keep replicating the default bundle structure over and over ignoring what will work better for them. Just because it helps you to not have to think about architecture, you run a command and it generate all the folder structure and controllers. If you have a look at the (well designed, compatible with other frame