Traditionally, when I program a CRUD app, usually the program is structured with different layers such as
- Models
- DAO
- Middleware for business logic
- Configuration
- and so on
Recently I read some articles like [1][2]. There examples like Print, Executable are provided, which is nice. But I have a question. What is a recommended way to structure a context function based Scala 3 CRUD program if my employer asks me to accomplish such tasks?
Also, is it possible to use context function to achieve the effect of IO monad like Cats Effect, or ZIO? I read that APIs like suspension/ continuation are needed, but I can’t find the links I read about those info now. Any related news?
I appreciate any advice. Thanks