Skip to content

sonoran-scala/clean

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Let's build a hit counter using a functional domain model based on the Tagless-Final style and The Clean Architecture.

This project is based on the post F[unctional] Core, IO[mperative] Shell.

Layers

The domain is the lowest layer. Each additional layer may access any of the layers beneath it.

.-------------------------------------------.
| LAYER 4: RUNNERS                        o |
|-----------------------------------------|-|
| * Main method with an http server       | |
'-----------------------------------------|-'
                                          |
.-----------------------------------------|-.
| LAYER 3: DRIVERS                     o  v |
|--------------------------------------|--|-|
| * In-memory data store               |  | |
| * RDBMS/JDBC data store              |  | |
'--------------------------------------|--|-'
                                       |  |
impure                                 |  |
=======================================|==|==
pure                                   |  |
                                       |  |
.--------------------------------------|--|-.
| LAYER 2: USE CASES                o  v  v |
|-----------------------------------|--|--|-|
| * Increment and get the count     |  |  | |
'-----------------------------------|--|--|-'
                                    |  |  |
.-----------------------------------|--|--|-.
| LAYER 1: DOMAIN                   v  v  v |
|-------------------------------------------|
| * Entities                                |
|     * Count                               |
| * Operations                              |
|     * Increment the count                 |
|     * Get the count                       |
'-------------------------------------------'

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published