Using a Registry to look up collaborators in Rails, like external APIs.| mattbrictson.com
Explaining the Dependency Injection pattern, by contrasting it with Service Locator. The choice between them is less important than the principle of separating configuration from use.| martinfowler.com
How to use Faraday and other gems to implement circuit breakers, gracefully handle API rate limits, pool connections for better performance, and more.| mattbrictson.com
Update: Rails v7.1 will introduce a new configuration method config.autoload_lib to make it safer and easier to autoload the /lib directory and explicitly exclude directories from autoloading. When released, this advice may no longer be relevant, though I imagine it will still be possible for developers to twist themselves into knots and cause outages with autoloading overrides.| island94.org