Phase 3a

Due Date: see roadmap

Objectives

An understanding of
  • Domain-driven design
  • Automated regression testing
    • unit (component-level) testing
    • integration testing
    • mock objects
  • Dependency injection
    • Lightweight object containers
    • Spring framework
    • Scala Cake idiom

Your Job

For this phase, your job is to develop your domain model and service layer in freestanding form, that is, in absence of the layers above or below. You should distinguish between entities, value objects, and aggregates. In addition, you should use services to provide functionality that cuts across domain objects, repositories for managing collections of domain objects, and factories for encapsulating the creation of objects. Use the Scala Cake idiom to manage dependencies among components. Your repository implementations should be in-memory (non-persistent).

These functional requirements apply, but you should leave out authentication in this phase. We will add when we develop the web interface. 

Testing

Testing should be included as follows:
  • Domain objects and other components without dependencies: simple, component-level unit testing.
  • Services and other components with dependencies: Cake-managed integration testing using your in-memory repositories and suitable mock objects. (For production deployment, integration would be done similarly but with proper persistence.)

Writing Component

Your submission for this phase will include a doc folder with a brief description (200-300 words, about one page of plain text or Markdown) of your team's experience with this project phase. In particular, you should discuss these questions:
  • How helpful was the Domain-Driven Design approach?
  • What did it take to identify the various domain and service components?
  • How did you design and implemented the in-memory repositories?
  • What purpose does the Cake idiom serve in the resulting architecture?
  • How were you able to test components with dependencies?
Include any other observations you consider noteworthy.

Example

The LinearRegressionDomainOnlyMaven project in the repository serves as a Java example for this phase. This is a stripped-down version containing only the domain model and service layer, as well as the DAO interface. (The DAO roughly corresponds to a repository in DDD terminology.) An equivalent Scala-based example will be available shortly.

References

Comments