Re:Alan Kay: Smalltalk is not about objects, it’s about mess...
by bsaul on Saturday December 21, 2019 @02:48PM
(#21852996)
but then how do you deal with transactionnal behaviors ?
Re:Alan Kay: Smalltalk is not about objects, it’s about mess...
by pmontra on Saturday December 21, 2019 @05:23PM
(#21853674)
Check Elixir's Ecto module https://hexdocs.pm/ecto/Ecto.html
The general idea is to build the transaction in a pipeline of function calls. Each function gets the old definition of the transaction as an argument and returns a new one. Eventually the call at the end of the pipeline executes the statements in the definition, wrapping them in a transaction.
If the question is how to deal with 100 or 100 k concurrent transactions, the answer again is in the same way a cluster of servers running programs written in any other language do. Eventually SQL is SQL.
In my experience with Elixir there are never many processes that have a state to save in a database. Eventually it's the same load no matter if the implementation is actor based or object oriented.