<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/when-rails-gives-you-a-schema-instead-of-a-boundary-ffv3cawez" -->

---
title: When Rails gives you a schema instead of a boundary
description: Large Rails codebases often suffer from missing boundaries: a single User model serves Identity, Billing, Reporting, and the core domain simultaneously, making...
canonical: https://daily.dev/posts/when-rails-gives-you-a-schema-instead-of-a-boundary-ffv3cawez
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: When Rails gives you a schema instead of a boundary | daily.dev
og:description: Large Rails codebases often suffer from missing boundaries: a single User model serves Identity, Billing, Reporting, and the core domain simultaneously, making...
og:url: https://daily.dev/posts/when-rails-gives-you-a-schema-instead-of-a-boundary-ffv3cawez
og:image: https://api.daily.dev/og/posts/FfV3CaweZ.png
og:image:alt: When Rails gives you a schema instead of a boundary
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# When Rails gives you a schema instead of a boundary

**[Ruby Flow](https://daily.dev/sources/rubyflow)** · 7 min read · 1 upvotes · 0 comments

## Summary

Large Rails codebases often suffer from missing boundaries: a single User model serves Identity, Billing, Reporting, and the core domain simultaneously, making onboarding painful and changes unpredictable. The post argues for applying Domain-Driven Design bounded contexts inside Rails by organizing code into subdomain directories (identity/, billing/, reporting/) and enforcing team agreements about what may cross each boundary. Key insight: Billing::Seat knows an occupant ID but nothing about passwords or emails, because none of that has ever changed an invoice. The author distinguishes two separate decisions — drawing a boundary (cheap, almost always worth it) versus abandoning ActiveRecord inside that boundary (expensive, only justified in the core subdomain where complexity lives). The translation layer at subdomain edges feels like duplication but is actually where ambiguity is made explicit and caught in intentional code.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://paweldabrowski.com/farewell-to-rails-way/when-rails-gives-you-a-schema-instead-of-a-boundary>

## Similar posts on daily.dev

- [When your code speaks Rails instead of the domain](https://daily.dev/posts/when-your-code-speaks-rails-instead-of-the-domain-vndv0arqg) · Ruby Flow · 0 upvotes · 0 comments
- [Adding multi-tenancy to a DDD Rails app](https://daily.dev/posts/adding-multi-tenancy-to-a-ddd-rails-app-cqm2w83zd) · arkency · 0 upvotes · 0 comments

---

Tags: [#architecture](https://daily.dev/tags/architecture), [#ruby](https://daily.dev/tags/ruby), [#rails](https://daily.dev/tags/rails), [#domain-driven-design](https://daily.dev/tags/domain-driven-design)

[View this post on daily.dev](https://daily.dev/posts/when-rails-gives-you-a-schema-instead-of-a-boundary-ffv3cawez)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"When Rails gives you a schema instead of a boundary","url":"https://daily.dev/posts/when-rails-gives-you-a-schema-instead-of-a-boundary-ffv3cawez","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/when-rails-gives-you-a-schema-instead-of-a-boundary-ffv3cawez"},"datePublished":"2026-08-04T15:59:17.611Z","dateModified":"2026-08-04T16:47:43.388Z","description":"Large Rails codebases often suffer from missing boundaries: a single User model serves Identity, Billing, Reporting, and the core domain simultaneously, making...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/11e3ed386b9f1da0d4deaa6414d742b5?_a=AQAEuop","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/11e3ed386b9f1da0d4deaa6414d742b5?_a=AQAEuop","isAccessibleForFree":true,"articleSection":"Ruby Flow","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Ruby Flow","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/a21aaa8bcbbf448193a016895c90a0e1","url":"https://daily.dev/sources/rubyflow"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/when-rails-gives-you-a-schema-instead-of-a-boundary-ffv3cawez","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":1},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"architecture,ruby,rails,domain-driven-design","timeRequired":"PT7M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Ruby Flow","item":"https://daily.dev/sources/rubyflow"},{"@type":"ListItem","position":3,"name":"When Rails gives you a schema instead of a boundary"}]}
```

