Skip to main content

Posts

Showing posts with the label clean architecture

Architecting Resilient .NET Core Applications: Handling Transient Failures.

  Transient Failures happen when server is temporarily overloaded.  We need to handle this instead of sending response back to client and say like that “Server is not responding” In the world of Cloud there are temporary failures that may occur in a system and can be recovered from by retrying the operation. T hese failures typically occur due to network issues, temporary unavailability of external services, timeouts, or rate limiting, and they often resolve themselves after a brief period. Possible Reasons for Transient Failures Resource overloaded:   For example, in high-traffic scenarios, limited system resources (like memory or CPU) can lead to failures when trying to access those resources. Network Issues :  Temporary issues like DNS resolution errors, dropped connections, or network congestion can cause operations to fail. Service Unavailability :  External services or databases might be down or unavailable temporarily.  For example, a database connec...

Design Application using Clean Architecture

  Clean Architecture , introduced by  Robert C. Martin   (Uncle Bob), aims to create systems that are: Independent of frameworks Testable Independent of UI Independent of database Independent of any external agency Clean Architecture emphasizes separating the concerns of different parts of the system and ensuring that each part has a clear responsibility. .NET clean architecture as a development approach, available in a layered form to reduce dependency. The architecture consists of several layers, each with a specific role and dependencies that flow in one direction: from the outer layers to the inner layers. Inner most Layer is independent to its outer layer, means inner most layer does not have any references, it builds and stand independently. Dependency Rule The core principle of Clean Architecture is the  Dependency Rule , which states that source code dependencies can only point inward.  This means: Nothing in inner circle can depend on anything in an out...