I'm pretty new to Clean Architecture and like the principals. If we define data access interfaces and the implementation comes later that's all good.
In my case my application will have data from several sources. Now if I have a database instead of using the file system for the implementation, I will need a database login and therefore prompt a user. How does this fit in with Clean Architecture since the domain and application layers shouldn't know about implementation?Only implementing with a database brings a requirement for a login.
Cheers, Alan
Accepting login data from user does not mean you expose domain to implementation details, it only means you get that input from presentation layer (and of course should save it in a secured way for later use) rather than save it ahead somewhere in your infrastructure layer.
In a way, ui client and infrastructure are similar, they are both considered as implementation details. That is why they are both presented in the same outer circle of the CA diagram.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With