Application Architecture
A new engineer joins DabbaGo and is asked to add "customers can skip tomorrow's tiffin". She opens the ordering app and finds skip logic in three places: the checkout screen, a nightly script and the kitchen report. Which one is real? Nobody drew the inside of the app, so every developer put things wherever was nearest. Application architecture exists to stop exactly this.
The rule
Give every rule one obvious home inside the app.
Application architecture is the architecture of one application: one codebase that is built and deployed as a unit. The application architect is responsible for:
- Modules and boundaries. What the main parts of the app are and what each owns. DabbaGo's ordering app might have
menu,cart,ordersandpayments. - Layers. How code is stacked, for example screens and API handlers on top, business rules in the middle, database access at the bottom.
- Dependencies. Which module may call which.
ordersmay askpaymentsto charge a card;paymentsshould not reach intoorders' tables. - Frameworks and conventions. The web framework, how errors are handled, how things are logged and tested, so every module looks familiar.
- The app's own quality needs. How fast checkout must be, what happens if the payment gateway is down.
A simple module map for the ordering app:
ordering-app/
menu/ today's dishes, prices, kitchens
cart/ what the customer is about to buy
orders/ placed orders, skips, cancellations, cut-off time
payments/ charging, refunds (talks to the gateway)"One obvious home" is the test. When the rule is "skips must happen before 10:30 pm the night before", there should be no debate: it is about an order's lifecycle, so it lives in orders, once.