Clean Architecture is a book by Robert C. Martin that contains solutions to architecting software solutions. Collectively these concepts are referred to as "Clean Architecture".
Questions tagged [clean-architecture]
236 questions
9
votes
2 answers
In Clean Architecture, aren't Entities another type of Boundary?
In the Clean Architecture, Uncle Bob defines Entities as enterprise-wide business rules and Interactors (Use Cases) as application-specific business rules. Also, he describes that Interactors are responsible for the "dance of the entities", and in…
7
votes
1 answer
Clean Architecture: May the Controller talk to the Presenter directly?
From what I understand from the 'Clean Architecture', the controller determines which usecase to execute dependent on the input of the user. If the input from the CLI for example is invalid, the controller already knows that something is wrong, so…

davidh38
- 173
4
votes
3 answers
How to split up use cases in Clean Architecture? (Dealing with use case dependencies)
I am trying to understand Clean Architecture as explained by Uncle Bob.
My application requires a user to do a test.
A test consists of a collection of questions that a user needs to answer.
A audio file is played for every question.
After the test…

HPage
- 253
3
votes
1 answer
Why dependency direction is determined by levels and not by change frequency?
Clean Architecture defines level as a distance from inputs and outputs. So Entities or business-objects are the highest level.
What is a practical reason to make lower level dependent on higher level?
To me it looks like the frequency of change must…

Anton Petrov
- 356
- 1
- 10
2
votes
2 answers
Should similar use cases be splitted or combined in clean architecture?
In Clean architecture
Suppose I have two actions (approve/deny) a request.
Should I create a use case for approve and another for deny?
or both in one use case (RespondToRequestUseCase) and I determine the action type through the request…

Mohammad Alotol
- 147
1
vote
0 answers
Could output port consist of multiple methods? (Clean Architecture)
The use case output port is called by the Interactor returning the response model, and the output port could be called many times with different responses.
Question: Could the output port has multiple methods and the response model divided into…

Mohammad Alotol
- 147
1
vote
1 answer
Who should validate the request data, controller or useCase?
I use the controller to extract data from a request and Use Cases/Interactors to validate the data. But can I use the controller to extract and validate the request data?

ellandor
- 13
1
vote
1 answer
Clean Architecture how does domain layer communicate with the Infrastructure layer?
I'm trying to get a grasp of the Clean Architecture. In the examples I found the typical solution structure consists of three projects: Core, Infrastructure, and Presentation/UI. The Core project must not have any dependencies. It contains the…

blablaalb
- 13
1
vote
1 answer
Clean Architecture: Layers for decoding messages and working with a map?
I work in the field of military aviation. The application is a WPF-App within a fighters aircraft and the machine, which runs the app is connected to the internal data bus of the aircraft and also to the radio.
All communication from and to external…

Crosell
- 33
- 1
- 1
- 3
0
votes
1 answer
How to balance "Draft capabilities" in Clean Architecture: handling Partial Models and Database Integration
I have an app with "clean architecture" classic layers:
Ports (such as HTTP, GRPC, GRAPHQL resolvers)
Services (CRUD methods and others)
Adapters
Domain
My app has of course multiple "models" such as:
Player
id: String (mandatory)
firstname:…

Fred Hors
- 139
0
votes
0 answers
How to implement repository in clean architecture
I need to rewrite my project due to many underlying issues causing errors and I started following clean architecture by Uncle Bob (I read the book).
I created my domain, infrastructure, application and interface-adapters. In my domain directory I…

z0mbieKale
- 129
- 2
0
votes
0 answers
Job Scheduling in clean architecture
Imagine having the entity Counter and a use case that creates it. Moreover the business logic requires that every time a counter gets created a background task that increases the counter every 1s must be started too, should terms like "scheduling"…

rockson
- 43
0
votes
2 answers
What is enterprise logic, business logic in clean architecture?
I had go through Jason Taylor's link. He mentioned that
The Domain layer contains enterprise logic and types and the Application layer contains business logic and types. The difference is that enterprise logic could be shared across many systems,…

Nest
- 127
-1
votes
1 answer
Understanding Clean Architecture
Below is my understanding of the projects involved .However my confusion comes from the difference between Application/Core/Domain . Is it also correct to say Core = Application + Domain because i have come across some projects without…