Skip to main content

All Questions

Tagged with
11votes
7answers
5kviews

How to maintain dependencies shared among microservices?

There is a dependency jar containing tons of service classes mostly used to retrieve data from database, and this jar is used among several different micro services in one cluster. There is a big ...
Rui's user avatar
  • 1,925
6votes
3answers
656views

Hexagonal Architecture + Domain Driven Design. How to perform a correct implementation?

Currently, I am trying to implement these two architectures together with Java and Spring (although technology shouldn't matter I think). But I'm encountering problems getting them to work together. I ...
RuDaHee's user avatar
1vote
4answers
413views

Preventing payment to be processed twice

I have app with paymemt/subscription service, pretty much how the payment works is: Initial payment User initiate payment on the web ( click on "subscribe") Back-End send init request to ...
Darlyn's user avatar
0votes
2answers
221views

Where perform mapping in strict Domain-Driven Design?

I want to create an example application where we use a strict domain-driven design and layering (controller, service, repository). Most notably, we have a clear distinction between the domain and the ...
Gman's user avatar
1vote
1answer
149views

Background thread processing vs queue based processing for relatively short tasks (max 30-40 seconds)

I need suggestion / recommendation on the design approaches mentioned below. UseCase: I have a usecase where a client uses my system to generate some recommendations. Now, these recommendations are ...
Passion's user avatar
25votes
4answers
42kviews

Service layer returns DTO to controller but need it to return model for other services

Following this post https://stackoverflow.com/questions/21554977/should-services-always-return-dtos-or-can-they-also-return-domain-models and best practices in Software Arch suggestions by Martin ...
Youans's user avatar
70votes
4answers
59kviews

Uncle Bob's clean architecture - An entity/model class for each layer?

BACKGROUND : I'm trying to use Uncle Bob's clean architecture in my android app. I studied many open source projects that are trying to show the right way to do it, and I found an interesting ...
Rami Jemli's user avatar
-1votes
1answer
459views

Using a shared enum across 15 nanoservices [closed]

Originally posted here, moved to code review, redirected from code review back here as there is no code to review. I think the question is enough abstract to be asked here. I have a mono repo with ...
Alexander Petrov's user avatar
3votes
1answer
6kviews

Best way to handle lazy models with mapstruct and spring transactional scope

In a typical Java Spring Web APP: we have the following layers: Model [DB Models] Repositories [where you have queries to DB] Services [Business service where you have the @Transactional annotation] ...
Youans's user avatar
0votes
0answers
117views

Spring data exchange between components?

Please advise me what pattern to use in following case: I have a Java/Spring Boot application. There is a component with @KafkaListener method which receives Kafka Messages on CRUD of various subject ...
ALZ's user avatar
  • 107
1vote
1answer
566views

The recommended Spring Boot project structure leads to repetitive code

When implementing projects in Spring Boot (especially CRUD applications), I often find myself writing a lot of repetitive code that just calls functions and services from lower layers. For example, ...
Win32's user avatar
0votes
1answer
240views

Is it secured to accept and execute user provided CURL commands

Assume you have to figure out a dynamic way where the user can provide an API call to hit in the backend for example, user to provide a webhook to call on his end server So, An idea for users to ...
Youans's user avatar
6votes
3answers
3kviews

In vertical slice architecture, how can I deal with entities/repositories that are used in multiple slices?

I'm trying to group the components of my system by funtionality. This is the analysis class diagram of my system model. A service class that involves a Post entity might necessarily interact ...
cidra's user avatar
1vote
1answer
354views

Extract common code into own module

I'm finding myself in a situation where I need to define common behaviour and implement it depending on the environment (minecraft server or javafx runtime). The simple graph below describes my idea. ...
wand555's user avatar
28votes
1answer
48kviews

Splitting a big project to create a multi-module Maven project

I am working on a Spring-MVC application in which we are using Maven for dependency management. As the project is big, we are thinking of splitting the project into several parts. I had some doubts, ...
We are Borg's user avatar

153050per page
close