Context:
I have completed chapter 3 (data), chapter 4 (functions) and chapter 5 (testing) of Designing Elixir Systems with OTP. And i’m currently building an e-commerce platform with the following functionalities:
-
User
can create an account - The authenticated
user
can addproducts
to theircart
- The
user
can checkout theirproducts
from thecart
- The
user
receives anorder
confirmation
Questions:
Here is a quote from the book explaining a bank as a data
It’s an initial balance plus a set of transactions at a point in time. These transactions are functions.
-
In the context of an ecommerce application what are the initial “balance” and “set of transactions at a point in time” do I need to keep a track off for:
users
,products
andorders
? -
In the context of an ecommerce CMS application what are the initial “balance” and “set of transactions at a point in time” do I need to keep a track off for:
users
,products
andorders
?