Questions tagged [hexagonal-architecture]

The Hexagonal Architecture is a software architecture proposed by Alistair Cockburn. It is also called Ports and Adapters. It is similar to the Onion Architecture proposed by Jeffrey Palermo.

Alistair Cockburn proposed the Hexagonal Architecture, also called Ports and Adapters. The architecture is similar to the Onion Arcitecture proposed by Jeffrey Palermo.

The fundamental motivation of the approach is to avoid layer-to-layer dependencies usually associated with the N-tier architecture approach. This is achieved by placing all infrastructure, including databases, outside the problem domain.

The problem domain is then completely independent of the required infrastructure (testing, databases, security, etc.). For example, this means that testing database accesses can be done thoroughly without a real database.

176 questions
0
votes
1 answer

DDD and Hexagonal architecture - Services

It's been a while since I started to build my DDD/Hexagonal architecture application, and I got quite overwhelmed with the amount of concepts related to both of them. Though I started to go slightly and trying to apply concepts when I found them…
0
votes
1 answer

Guice and restricting clients to getting only certain instances

When using Guice, how to restrict clients to getting instances from a specific group of classes (aka the Facebook problem)? Imagine I architect my system using ports-and-adapters and I have an admin adapter side, a business logic component, and a…
beluchin
  • 12,047
  • 4
  • 24
  • 35
0
votes
1 answer

How can I split domain logic and data access in Grails

How can I split domain logic and data access in Grails (and is it a good idea)? Many software applications we write are rather data(base) centered and in Grails one often persist from service classes or controllers directly to a database configured…
0
votes
0 answers

Who and when creates Boundary stereotyped objects

In the Entity-Control-Boundary pattern, when is the boundary classes created and initiated, and by which stereotyped class? This question could also be equivalent to; In the hexagonal-architecture, Whom is responsible for creating Primary…
-1
votes
0 answers

.NET how to apply DI for a specific assembly only

I'm using Hexagon Architecture I have 2 driving sides, let's call them A and B (they are two difference assemblies) The problem is the all the Dependency Injection configuration of the driving A are also applied on the driving B, and I don't want…
-1
votes
1 answer

hex-arc golang - overcome import cycling error when testing

I am having trouble testing foo_handler in my Go project. My project has the following structure: ├── Makefile ├── cmd │ └── main.go ├── go.mod ├── go.sum └── internal ├── api │ ├── router.go │ └── server.go ├── core │ …
Dana
  • 57
  • 1
  • 4
-1
votes
3 answers

What are the drawbacks of adding a specialized port when using Hexagonal Architecture?

You have a set of microservices A, B, C that interact with microservice D for various reasons and one day you discover that sometimes one of the input fields of one of the REST Apis of D need to be potentially cleaned or transformed, by joining it…
Edmondo
  • 19,559
  • 13
  • 62
  • 115
-1
votes
1 answer

use case/business logic returning multiple values best practice?

I am implementing a clean architecture in an application. I have a layer where the application/usecase classes which does the business logic and interacts with mutliple outgoing ports (interfaces to adapters for database calls, http api calls etc).…
cani
  • 210
  • 3
  • 10
-2
votes
1 answer

DDD Laravel. Repository pattern. How to retrieve an object from persistency and convert it into a not Laravel Entity model?

I'm aplying DDD in Laravel. In this architecture, the entity (conformed by the corresponding value objects) is not a Laravel Model extended class (because the domain layer needs to be agnostic to the infrastructure) So... when I retrieve some data…
-2
votes
2 answers

Hexagonal architecture get aggregate in controller or service

I have a service with Hexagonal architecture that is responsible for creating leads in the system. In this service I don't have the users, I have to call an external service. In the lead create request that I receive through API, I don't have the…
-2
votes
1 answer

Moving a star marker along a hexagon trajectory?

I want to move a star marker along hexagon trajectory similar to "Circle trajectory" that I have added at the end of my question. Thanks. This is the source code to that I have written yet for creating concentric hegzagons but I don't know how to…
zein
  • 35
  • 6
1 2 3
11
12