Unit 01 of 03
Framework Fundamentals
Inversion of control, the request–response lifecycle, routing, controllers, middleware, the object container and facades — each as a mechanism that decides whether a piece you wrote is called in this request.
Published Updated
Lessons
- 01 Why a Framework A comparison of an if chain whose flow the script drives with a route registration whose flow the framework drives, and a twelve-part measurement built on four names that classify whether a part ran in this request. 1 min read
- 02 The Request–Response Lifecycle The boot phases of service providers, the way the kernel handles a request, and the way work that runs after the response is sent stays outside the response; a comparison of deferred work with work called directly. 3 min read
- 03 Routing Route patterns, parameters, groups and named routes; the first matching route in registration order wins, and a route can be left unwired in the shadow of another route. 2 min read
- 04 Controllers The controller class and the action method, the resource controller exposing seven actions as routes, and the single-action controller; the resolution of constructor dependencies by the object container. 2 min read
- 05 Middleware Moving cross-cutting concerns into layers placed in front of the action, the request passing through the layers to reach the action, the call to $next being made or not made, and the order of the links deciding the result. 3 min read
- 06 Object Container and Facades Binding in the object container, singleton binding and autowiring, a second binding to the same name silently overwriting the first, and the facade resolving the object from the container on every call. 3 min read