09 Nov 2023



Intermediate

Here are some examples of bounded contexts in different domains:

Example 1: E-commerce Platform

  • Order Management: This bounded context handles the creation, processing, and fulfillment of orders. It includes concepts such as customers, products, order lines, shipping, and payments.

    • Order Management Bounded Context:
      • Description: Handles the creation, processing, and fulfillment of orders.
      • Entities and Concepts:
        • Customer: Represents customers placing orders.
        • Product: Represents items available for purchase.
        • Order Line: Contains details about individual products within an order.
        • Shipping: Manages the shipment of orders.
        • Payment: Manages the financial transactions related to orders.
      • Ubiquitous Language: Terms like "Order," "Customer," "Product," "Shipping," and "Payment" are specific to this context.
  • Inventory Management: This bounded context manages the inventory of products. It includes concepts such as product variants, stock levels, and restocking.

    • Inventory Management Bounded Context:
      • Description: Manages the inventory of products.
      • Entities and Concepts:
        • Product Variant: Represents different variations of a product.
        • Stock Levels: Tracks the quantity of products available.
        • Restocking: Manages the replenishment of stock.
      • Ubiquitous Language: Terms like "Product Variant," "Stock Levels," and "Restocking" are specific to this context
  • Customer Relationship Management (CRM): This bounded context manages customer information and interactions. It includes concepts such as customer profiles, contact information, purchase history, and support tickets.

    • Customer Relationship Management (CRM) Bounded Context:
      • Description: Manages customer information and interactions.
      • Entities and Concepts:
        • Customer Profile: Stores information about individual customers.
        • Contact Information: Manages how the platform communicates with customers.
        • Purchase History: Tracks the history of customer transactions.
        • Support Ticket: Handles customer inquiries or issues.
      • Ubiquitous Language: Terms like "Customer Profile," "Contact Information," "Purchase History," and "Support Ticket" are specific to this context.

Example 2: Healthcare System

  • Patient Management: This bounded context manages patient information, including demographics, medical records, and treatment plans.

    • Patient Management Bounded Context:
      • Description: Manages patient information, including demographics, medical records, and treatment plans.
      • Entities and Concepts:
        • Patient: Represents individuals receiving healthcare services.
        • Medical Records: Stores information about a patient's medical history.
        • Treatment Plan: Outlines the recommended course of treatment.
      • Ubiquitous Language: Terms like "Patient," "Medical Records," and "Treatment Plan" are specific to this context.
  • Appointment Scheduling: This bounded context handles the scheduling of appointments with healthcare providers. It includes concepts such as doctor availability, patient preferences, and insurance requirements.

    • Appointment Scheduling Bounded Context:
      • Description: Handles the scheduling of appointments with healthcare providers.
      • Entities and Concepts:
        • Doctor Availability: Manages the availability of healthcare providers.
        • Patient Preferences: Captures preferences and constraints for scheduling appointments.
        • Insurance Requirements: Tracks insurance-related information for appointments.
      • Ubiquitous Language: Terms like "Doctor Availability," "Patient Preferences," and "Insurance Requirements" are specific to this context.
  • Medical Billing: This bounded context manages the billing of patients for medical services. It includes concepts such as insurance claims, patient copays, and payment processing.

    • Medical Billing Bounded Context:
      • Description: Manages the billing of patients for medical services.
      • Entities and Concepts:
        • Insurance Claims: Represents claims submitted to insurance providers.
        • Patient Copays: Handles the financial contribution required from patients.
        • Payment Processing: Manages the processing of financial transactions related to medical billing.
      • Ubiquitous Language: Terms like "Insurance Claims," "Patient Copays," and "Payment Processing" are specific to this context.

Example 3: Education Platform

  • Course Management: This bounded context manages the creation, scheduling, and delivery of courses. It includes concepts such as instructors, students, lesson plans, and assignments.

    • Course Management Bounded Context:
      • Description: Manages the creation, scheduling, and delivery of courses.
      • Entities and Concepts:
        • Instructor: Represents individuals delivering courses.
        • Student: Represents individuals participating in courses.
        • Lesson Plan: Outlines the content and structure of lessons.
        • Assignment: Represents tasks or assessments given to students.
      • Ubiquitous Language: Terms like "Instructor," "Student," "Lesson Plan," and "Assignment" are specific to this context.
  • Learning Management: This bounded context tracks student progress, grades assignments, and generates reports. It includes concepts such as student records, assessment results, and analytics.

    • Learning Management Bounded Context:
      • Description: Tracks student progress, grades assignments, and generates reports.
      • Entities and Concepts:
        • Student Record: Stores information about individual students.
        • Assessment Results: Captures the outcomes of student assessments.
        • Analytics: Provides insights and analysis of student and course performance.
      • Ubiquitous Language: Terms like "Student Record," "Assessment Results," and "Analytics" are specific to this context.
  • Curriculum Development: This bounded context develops and maintains the curriculum for the platform. It includes concepts such as learning outcomes, pedagogical approaches, and assessment rubrics.

    • Curriculum Development Bounded Context:
      • Description: Develops and maintains the curriculum for the platform.
      • Entities and Concepts:
        • Learning Outcomes: Defines the desired outcomes of the educational experience.
        • Pedagogical Approaches: Describes the methods and strategies used for teaching.
        • Assessment Rubrics: Specifies the criteria for evaluating student performance.
      • Ubiquitous Language: Terms like "Learning Outcomes," "Pedagogical Approaches," and "Assessment Rubrics" are specific to this context.

Diagram of bounded contexts

   E-commerce Platform                   Healthcare System             Education Platform
 ___________________________       ___________________________     ___________________________
|                           |     |                           |   |                           |
|  Order Management         |     |  Patient Management        |   |  Course Management        |
|  - Customer              |     |  - Patient                 |   |  - Instructor             |
|  - Product               |     |  - Medical Records         |   |  - Student                |
|  - Order Line            |     |  - Treatment Plan          |   |  - Lesson Plan            |
|  - Shipping              |     |                           |   |  - Assignment             |
|  - Payment               |     |                           |   |                           |
|___________________________|     |___________________________|   |___________________________|

 ___________________________       ___________________________     ___________________________
|                           |     |                           |   |                           |
|  Inventory Management     |     |  Appointment Scheduling    |   |  Learning Management      |
|  - Product Variant        |     |  - Doctor Availability     |   |  - Student Record         |
|  - Stock Levels           |     |  - Patient Preferences     |   |  - Assessment Results     |
|  - Restocking             |     |  - Insurance Requirements  |   |  - Analytics              |
|___________________________|     |___________________________|   |___________________________|

 ___________________________       ___________________________
|                           |     |                           |
|  Customer Relationship    |     |  Medical Billing          |
|  Management               |     |  - Insurance Claims       |
|  - Customer Profile       |     |  - Patient Copays         |
|  - Contact Information    |     |  - Payment Processing     |
|  - Purchase History       |     |                           |
|  - Support Ticket         |     |                           |
|___________________________|     |___________________________|
domain-driven-design-ddd
bounded-context
examples