adb (parent Maven + proxy)
AI-generated content
This document was generated by an AI assistant. Verify accuracy before relying on the details.
Role
adb/ is the parent project of the Java backend. It provides:
- A parent POM that centralizes Spring Boot, Spring Cloud, common dependency (MapStruct, Lombok, Apache POI, etc.) and Maven plugin versions.
- Nine shared modules consumed by every microservice:
adb-common,adb-model,adb-test,adb-actions,adb-action-logs,adb-descriptor,adb-messaging,adb-openapi,adb-communication,adb-security. - The Nginx reverse proxy (
proxy/) that acts as the platform's API gateway.
No runnable service is defined here: it is exclusively shared libraries and configuration.
Tech stack
| Item | Version |
|---|---|
| Java | 18 |
| Spring Boot | 3.1.3 |
| Spring Cloud | 2022.0.4 |
| Maven | 3.6+ |
| MapStruct | 1.5.5.Final |
| Lombok | 1.18.28 |
| Logstash Logback | 6.6 |
| SpringDoc OpenAPI | 2.2.0 |
| Apache POI | 5.2.3 |
| Commons Validator | 1.8.0 |
| Spring Cloud AWS | 3.0.4 |
Current parent version: 0.3.116.
Module architecture
flowchart TB
parent[adb<br/>parent POM]
subgraph Modules
common[adb-common<br/>FQDN, RequestContext]
model[adb-model<br/>shared DTOs]
test[adb-test<br/>test helpers]
actions[adb-actions<br/>action processor]
actionlogs[adb-action-logs<br/>traceability]
descriptor[adb-descriptor<br/>metadata]
messaging[adb-messaging<br/>SQS/SNS abstractions]
openapi[adb-openapi<br/>specs + codegen]
communication[adb-communication<br/>WebClient helpers]
security[adb-security<br/>delegation models]
end
proxy[proxy<br/>Nginx]
parent --> Modules
parent --> proxy
Services[adb-persons<br/>adb-parts<br/>adb-contracts<br/>...]
common -.dependency.-> Services
model -.dependency.-> Services
messaging -.dependency.-> Services
actions -.dependency.-> Services
actionlogs -.dependency.-> Services
adb-common
Core of the module: the FQDN enum (fr.lifeconnect.adb.client.FQDN), a directory of all internal services:
| Constant | URL |
|---|---|
PERSONS | http://adb-persons |
ORGANIZATIONS | http://adb-persons |
PARTS | http://adb-parts |
CONTRACTS | http://adb-contracts |
ACCOUNTING | http://adb-accounting |
FILES | http://adb-files |
UTILITIES | http://adb-utilities |
AGGREGATES | http://adb-aggregates |
VIEWS | http://adb-views |
REPORTS | http://adb-reports |
TICKETS | http://adb-tickets |
NOTES | http://adb-notes |
GRAPH | http://adb-graph |
NOTIFICATIONS | http://adb-notifications |
UI | http://adb-ui |
UI_EXT | http://adb-ui-ext |
Also contains: RequestContextData (user-context propagation), client interfaces (NotesClient, TicketsClient, ...), and various utilities.
adb-model
DTOs shared between services to avoid duplicating business data structures.
adb-messaging
Abstractions on top of Spring Cloud AWS to publish (SnsTemplate) and consume (@SqsListener) events. Configures regions, JSON serializers, and DLQs.
adb-actions / adb-action-logs
adb-actions: framework to trigger and trace business actions (modifications, validations).adb-action-logs: persistence of action logs in MongoDB (one dedicated collection per service).
Used by adb-persons, adb-parts, adb-contracts, adb-accounting, adb-utilities.
adb-openapi
Generates OpenAPI specs from Spring annotations (SpringDoc). Acts as the source for the TypeScript client in adb-web/packages/api-client.
adb-security
Cross-cutting delegation module. Provides the model and service layer for access delegation between entities (e.g. a person delegating scoped access on a contract to another person):
Delegation— persisted record: delegatee, resource (TargetObject), validity window, set of delegated scopes.DelegateePort/DelegationPort— reactive repository interfaces implemented per-service.DelegationService.hasAccess(contextData, resource, requester, scope)— reactive check used in controllers.
Services that need delegation import this module and implement the port interfaces.
adb-test, adb-descriptor, adb-communication
adb-test: integration test helpers (TestContainers, Mongo fixtures).adb-descriptor: module metadata (version, dependencies).adb-communication: reactiveWebClienthelpers (RestClientImpl, retry, error mapping).
proxy/ — Nginx gateway
Nginx configuration (proxy/default.conf) that routes external requests to internal services:
| Path | Target |
|---|---|
/persons | adb-persons |
/parts | adb-parts |
/contracts | adb-contracts |
/accounting | adb-accounting |
/files | adb-files |
/filemetadatas | adb-files (file metadata alias) |
/utilities | adb-utilities |
/aggregates | adb-aggregates |
/view | adb-views |
/reports | adb-reports |
/tickets | adb-tickets |
/notes | adb-tickets (redirected — adb-notes deprecated) |
/graph | adb-graph |
/organizations | adb-persons (organization sub-resource) |
/auth | Keycloak (proxied to hephaestus.life-connect.fr) |
/oauth/ | Keycloak OAuth2 endpoints |
Configuration / deployment
- Build:
mvn clean install -pl adb-common,adb-model,adb-messaging,...ormvn installat the root. - Versioning: SNAPSHOT during development, releases handled via the script
adb/doc/release.md. - Proxy deployment: Helm chart
adb-charts/charts/ingress-route/and Docker image built fromproxy/Dockerfile.
Links
- Code:
adb/ - Parent POM:
adb/pom.xml - FQDN enum:
adb/adb-common/src/main/java/fr/lifeconnect/adb/client/FQDN.java