How basilbarakat15/a-multi-tier-online-book-store works
Bazar.com is a small three-tier book store. A client uses the frontend’s search, information, and purchase endpoints; the frontend also serves the browser page. The catalog owns book details and stock, while the order service records purchases and asks the catalog to sell a copy. The README also documents price and stock updates, catalog and order queries, and JSON data persisted under data/. Relationships shown here are based on README statements only; source excerpts were not available.
Main entry points: FrontendService.java Frontend API · OrderService.java Order service · CatalogService.java Catalog service · index.html Store page
Components 8
Presentation
- Frontend API
src/main/java/org/example/FrontendService.java - Store page
src/main/resources/public/index.html
Book catalog
- Catalog service
src/main/java/org/example/CatalogService.java - Book records
src/main/java/org/example/Book.java - Books data
data/books.json
Orders
- Order service
src/main/java/org/example/OrderService.java - Order log
data/orders.json
Other components
- Shopper
Connections 8
- Shopper → Frontend API: uses API
README.md - Shopper → Store page: opens
README.md - Frontend API → Store page: serves page
README.md - Frontend API → Catalog service: requests catalog
README.md - Frontend API → Order service: requests purchase
README.md - Order service → Catalog service: sells copy
README.md - Catalog service → Books data: owns data
README.md - Order service → Order log: owns log
README.md