4 ms·
This is a very similar idea to Gary Bernhardt's: Functional Core, Functional Core, Imperative Shell: https://www.destroyallsoftware.com/screencasts/catalog/func
by RubenSandwich 9y ago
This is a very similar idea to Gary Bernhardt's: Functional Core, Functional Core, Imperative Shell: https://www.destroyallsoftware.com/screencasts/catalog/functional-core-imperative-shell https://www.destroyallsoftware.com/screencasts/catalog/funct....
I prefer Gary's explanation of it because he jumps right into the meat of the problem and shows code that models this architecture. The video doesn't require you to know Ruby to understand what he is saying, just as long as you know some basic testing phrases; Mocking, Stubbing, Etc, you should be able to follow along.
- theptip 9y agoI like Bernhardt's rendition of this concept too. His talk "Boundaries" is my favourite summary: https://www.destroyallsoftware.com/talks/boundaries https://www.destroyallsoftware.com/talks/boundaries Note that the Functional Core architecture makes an additional restriction on top of the Clean/Hexagonal architecture, namely that the core should be functional; the OP doesn't make such prescriptions on how you implement the Entities and business logic (though it doesn't discourage you from doing so either of course).
- RubenSandwich 9y agoYou are right that the above article doesn't specifically mention the core being functional. I merely interpreted that from one of the stated properties of his and the other architectures he showcases: "2. Testable. The business rules can be tested without the UI, Database, Web Server, or any other external element." If that doesn't scream functional, then I don't know what does. :)
- ceronman 9y agoFor the Python programmers, there is also a better explanation of the same concept by Brandon Rhodes: The Clean Architecture in Python. https://www.youtube.com/watch?v=DJtef410XaM https://www.youtube.com/watch?v=DJtef410XaM
- js8 9y agoIt also kinda reminds me these two articles, previously discussed on HN: http://degoes.net/articles/modern-fp http://degoes.net/articles/modern-fp http://degoes.net/articles/modern-fp-part-2 http://degoes.net/articles/modern-fp-part-2