Auth factories in Laravel
summary
Explains how Laravel applies factory and abstract factory patterns via Socialite, the service container and session drivers, using a Slack OAuth implementation to show concrete code-level interactions. Covers how the Socialite manager and session manager are constructed by the service container, how provider drivers are resolved and callbacks handled, and when to use abstract factories and configuration-driven product families.
AI-written summary · about
chapters (22)
- 0:00Start
- 0:39Mary introduces herself
- 1:42A Laravel powered jobs board for her local tech meetup
- 2:20Explaining OAuth, access management and how Socialite wraps providers
- 2:45Refusing to believe OAuth could be that easy in Laravel until it worked first try
- 3:05Determination to understand what was happening beneath the surface
- 3:50Decoupling is essential for factory patterns
- 4:10Introducing the factory pattern
- 5:00How the Socialite manager functions as a factory
- 5:40HTTP statelessness and session storage
- 6:30Socialite and session managers are factories created by the service container
- 7:10Walkthrough of session manager construction
- 8:12How Socialite and session products interact at runtime
- 9:03Why concrete Laravel code provides more meaningful insight for self taught developers
- 9:40Why Laravel source code is excellent for learning
- 10:03Reviewing when to use abstract factories and how Laravel meets those conditions
- 11:05Discussing configuration driven families of products
- 12:00Tying together factory creation of Socialite manager and session manager
- 12:40How Socialite provider drivers are resolved, callbacks are handled and customising behaviour
- 13:10Walking through building a provider
- 13:45Reading code is challenging at first but improves with practice
- 14:28Final takeaway
related talks
21mSoftware Design Patterns in Laravel 4
40mEngineering Complex Applications with Laravel 4
37mOrganizing Code in Laravel
48mLaravel Authentication Deep Dive
40mCrafting Elegant APIs with Laravel
49mLaravel - If, how and why you should use it!
29mLuke Downing :: Lessons from the Laravel Framework
48m12 Factors Laravel
