Portfolio

Golang · Layered MVC Monolith

Go Commerce

A server-rendered Go commerce application covering catalog, wishlist, cart, checkout, shipping, and order history. Gin handles web and API routes, GORM maps PostgreSQL data, and Gorilla Sessions manages authenticated access. The administration area covers orders, inventory, shipping, and notifications, while an invoice service produces PDF documents. The architecture favors a simple deployable binary with clear controller, model, service, and middleware boundaries.

Interface preview for Go Commerce

Tech stack

GoGinGORMPostgreSQLGorilla SessionsViperbcryptGoFPDFDocker ComposeHTML Templates

Architecture

Layered MVC Monolith

Browser and API traffic passes through route groups, controllers, services and models, and GORM into PostgreSQL. Middleware handles authentication, sessions, and HTTP method overrides. Administration and customer routes remain separate while sharing product, cart, order, address, and wishlist models.

Core capabilities

  • Product catalog and categories
  • Wishlist and shopping cart
  • Checkout, payment, and shipping
  • Delivery addresses and order history
  • Vouchers and notifications
  • Inventory and order administration
  • Session-based authentication
  • PDF invoice generation