Abstracting a Service - A Case Study in Forward Thinking with SOA
summary
A large Rails app with ~40 gems is split into three services: a users repo, a devices service, and a middleman that enforces per-user device rules, using Sinatra for lightweight endpoints. HTTP clients use Her + Faraday for ActiveRecord-like remote models; session proxy middleware forwards Rails session tokens for auth (a temporary but working solution). Tests use WebMock and VCR, uniqueness uses UUIDs for global IDs, and search/aggregation relies on Elasticsearch; the refactor reduces coupling and proves operational.
AI-written summary · about
chapters (10)
- 0:00Introduction and background
- 3:30Problem with monolithic app
- 6:18Service-oriented architecture approach
- 8:44Choosing Sinatra and HTTP tools
- 10:13Authentication across services
- 11:58Handling object uniqueness
- 13:23Testing HTTP interactions
- 15:58Key learnings and best practices
- 18:29Documenting interfaces
- 19:42Q&A session
related talks
37mRails as an SOA Client
36mAn Iterative Approach to Service Oriented Architecture
22mNitty Gritty Service Building
34mSOA and the Monolithic Rails App Anti-Pattern
43mRails services in the walled garden
28mNitty Gritty Service Building
40mMonoliths Between Microservices
30mService Oriented Design in Practice
