-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpom.xml
More file actions
2599 lines (2506 loc) · 140 KB
/
Copy pathpom.xml
File metadata and controls
2599 lines (2506 loc) · 140 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<!-- NOTE: the parent <version> must be hardcoded — Maven resolves the parent
BEFORE evaluating <properties>, so ${…} references don't work here.
This is the ONLY legitimate hardcoded version in this file; every other
version MUST live under <properties>. -->
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>4.0.6</version>
<relativePath/>
</parent>
<groupId>org.iris</groupId>
<artifactId>iris</artifactId>
<version>0.0.1-SNAPSHOT</version>
<name>iris</name>
<description>Spring Boot 4 reference application — observability, security, messaging, resilience</description>
<properties>
<!--
Versions not managed by the Spring Boot BOM are pinned here so they are
visible in one place and can be updated without hunting through <dependency> blocks.
spring-ai: milestone release — not yet in the BOM, must be declared explicitly.
springdoc: independently versioned; tracks Spring Boot but is not part of the BOM.
resilience4j: spring-boot3 artifact is not covered by the Spring Boot BOM.
bucket4j: in-memory token-bucket; no Spring Boot BOM entry.
archunit: test-only static analysis; independently versioned.
datasource-micrometer: JDBC observation bridge; not in the BOM.
jjwt: split into three artifacts (api / impl / jackson) — see dependency block.
shedlock: split into two artifacts (spring / provider) — see dependency block.
testcontainers: BOM entry exists but pinned here to guarantee kafka module alignment.
-->
<java.version>25</java.version> <!-- virtual threads (Loom) + pattern matching + record patterns -->
<lombok.version>1.18.44</lombok.version> <!-- generates @Getter/@Setter/@Builder boilerplate at compile time -->
<archunit.version>1.4.1</archunit.version> <!-- architecture rule enforcement in unit tests (disabled on Java 25 — see ArchitectureTest) -->
<bucket4j.version>8.10.1</bucket4j.version> <!-- token-bucket rate limiting (in-memory, per IP) -->
<resilience4j.version>2.4.0</resilience4j.version> <!-- @CircuitBreaker / @Retry / @Bulkhead annotations -->
<!--
Spring AI 1.1.4 GA. Closes five CVEs that were still open on the
1.0.0-M6 milestone: CVE-2026-22730 (8.8 HIGH), CVE-2026-22729 (8.6 HIGH),
CVE-2022-27772 (7.8 HIGH), CVE-2023-20883 (7.5 HIGH), CVE-2018-1196 (5.9).
1.0.0+ renamed the Ollama starter artifact
(spring-ai-ollama-spring-boot-starter → spring-ai-starter-model-ollama).
NOTE: the SB4-compat shims under
src/main/java/org/springframework/boot/autoconfigure/ must stay —
even 1.1.4 GA still has @AutoConfiguration(after = {
org.springframework.boot.autoconfigure.web.client.RestClientAutoConfiguration.class,
org.springframework.boot.autoconfigure.web.reactive.function.client.WebClientAutoConfiguration.class
}) on OllamaApiAutoConfiguration, pointing at the Spring Boot 3 package.
-->
<spring-ai.version>1.1.4</spring-ai.version>
<!--
ONNX Runtime — Microsoft's official Java binding for ONNX models.
Per shared ADR-0060, we use the ONNX format as the cross-language
inference contract (training in Python, serving identically in
Java + Python). The 1.21.0 release ships ~30 MB of bundled native
libs for Linux x86_64, Linux ARM64, macOS x86_64, macOS ARM64,
Windows x86_64 — covers GKE prod (linux/amd64) + macbook-local
dev (darwin/arm64).
-->
<onnxruntime.version>1.21.0</onnxruntime.version>
<datasource-micrometer.version>2.2.1</datasource-micrometer.version> <!-- JDBC DataSource observation bridge → query latency in Prometheus -->
<!--
springdoc 3.0.3 (upgraded from 3.0.2) — bundles swagger-ui 5.32.2 which patches
DOMPurify CVEs present in 5.32.0 (mXSS re-contextualization, prototype-pollution
XSS, predicate bypass — all MEDIUM, dev-only Swagger UI page).
-->
<springdoc.version>3.0.3</springdoc.version>
<pyroscope.version>2.5.2</pyroscope.version> <!-- continuous profiling agent — pushes CPU/memory profiles to Pyroscope -->
<testcontainers.version>1.21.4</testcontainers.version> <!-- 2.0.x core is released but companion modules (junit-jupiter, postgresql, kafka) are not yet published to Central; stay on 1.21.x until they catch up -->
<jjwt.version>0.13.0</jjwt.version> <!-- split into api/impl/jackson — see dependency block -->
<shedlock.version>7.7.0</shedlock.version> <!-- split into spring/provider — see dependency block -->
<!--
Tomcat 11.0.21 (upgraded from 11.0.20 via spring-boot-starter-parent BOM override) —
fixes CVE-2026-34483 (7.5 HIGH), CVE-2026-34486 (7.5 HIGH), CVE-2026-34487 (7.5 HIGH),
CVE-2026-34500 (6.5 MEDIUM). 11.0.21 is the latest GA on Maven Central.
-->
<tomcat.version>11.0.21</tomcat.version>
<!--
Netty + postgresql JDBC pinned ahead of SB 4.0.6 BOM defaults to fix
CVE backlog flagged by grype:scan on 2026-05-10 :
- netty 4.2.12.Final → 4.2.13.Final (5x High GHSA-mj4r-2hfc-f8p6,
GHSA-cm33-6792-r9fm, GHSA-57rv-r2g8-2cj3, GHSA-f6hv-jmp6-3vwv ×2
across compression / dns / http / http2)
- postgresql 42.7.10 → 42.7.11 (High GHSA-98qh-xjc8-98pq)
Both will be removed once SB BOM catches up.
-->
<netty.version>4.2.13.Final</netty.version>
<postgresql.version>42.7.11</postgresql.version>
<!--
Fabric8 Kubernetes client — used by the `org.iris.chaos` feature
slice (ADR-0044 port-style decoupling between "which failure to
inject" and "how to inject it"). The client creates Chaos Mesh
custom resources (PodChaos / NetworkChaos / StressChaos) in the
`app` namespace; RBAC is provisioned under
deploy/kubernetes/base/backend/rbac.yaml. Not covered by the
Spring Boot BOM, pin explicitly.
-->
<fabric8-kubernetes-client.version>7.3.1</fabric8-kubernetes-client.version>
<!--
jqwik — property-based testing framework for JUnit 5.
Test-scope only. Used by AggregationServicePropertyTest to verify
parallelism invariants across generated input sizes (see Phase 2.5
T3 in TASKS.md). Not in the Spring Boot BOM, pin explicitly.
-->
<jqwik.version>1.9.3</jqwik.version>
<!-- ──────────────────────────────────────────────────────────────────────
Build-plugin & analyzer versions
──────────────────────────────────────────────────────────────────────
RULE — never leave a <version>X</version> inside a <plugin>, <dependency>,
or <parent> block. Always extract it as a property here and reference it
as ${…-plugin.version}. Reasons:
1. Single place to audit versions (this <properties> block).
2. Dependabot/Renovate bumps land in ONE line, not scattered.
3. Duplicated plugin versions in profiles stay in sync automatically.
Any hardcoded <version> in the rest of this file is a regression —
fix it by extracting to a property before merging.
-->
<!-- Spring Boot (cross-profile: SB3 compat imports its own BOM + plugin) -->
<spring-boot-sb3.version>3.4.5</spring-boot-sb3.version>
<!-- springdoc-sb3.version : pinned in SB3 profile to block V3 Jackson
transitive (springdoc 3.x is SB4-aware and pulls spring-boot-jackson:4
→ tools.jackson V3). 2.7.0 = last 2.x line targeting Spring 6 / SB3. -->
<springdoc-sb3.version>2.7.0</springdoc-sb3.version>
<!-- spring-kafka-sb3.version : pinned in SB3 profile to avoid Spring Kafka 4.x
which hard-references Jackson V3 inside JsonKafkaHeaderMapper (crashes
on SB3's V2-only classpath). 3.3.4 = last 3.x line on the SB 3.4.x track.
ADR-0061 Entry 4. -->
<spring-kafka-sb3.version>3.3.4</spring-kafka-sb3.version>
<!-- Maven build plugins -->
<maven-antrun-plugin.version>3.2.0</maven-antrun-plugin.version>
<maven-javadoc-plugin.version>3.12.0</maven-javadoc-plugin.version>
<maven-jxr-plugin.version>3.6.0</maven-jxr-plugin.version>
<maven-project-info-reports-plugin.version>3.9.0</maven-project-info-reports-plugin.version>
<maven-surefire-report-plugin.version>3.5.5</maven-surefire-report-plugin.version>
<license-maven-plugin.version>2.7.1</license-maven-plugin.version>
<!-- exec-maven-plugin — runs QualityReportGenerator at prepare-package phase.
See ADR-0052 Phase Q-2 for why the quality report moves to build-time. -->
<exec-maven-plugin.version>3.5.0</exec-maven-plugin.version>
<!-- Coverage, mutation, and quality analyzers -->
<jacoco-maven-plugin.version>0.8.14</jacoco-maven-plugin.version>
<pitest-maven.version>1.23.0</pitest-maven.version>
<pitest-junit5-plugin.version>1.2.3</pitest-junit5-plugin.version>
<!-- Static analyzers (note: pmd-core + pmd-java share the same version) -->
<spotbugs-maven-plugin.version>4.9.8.3</spotbugs-maven-plugin.version>
<findsecbugs-plugin.version>1.14.0</findsecbugs-plugin.version>
<maven-pmd-plugin.version>3.28.0</maven-pmd-plugin.version>
<pmd.version>7.23.0</pmd.version>
<maven-checkstyle-plugin.version>3.6.0</maven-checkstyle-plugin.version>
<checkstyle.version>13.4.0</checkstyle.version>
<!-- SCA + SAST + Sonar -->
<dependency-check-maven.version>12.2.1</dependency-check-maven.version>
<sonar-maven-plugin.version>5.5.0.6356</sonar-maven-plugin.version>
<!-- Build provenance — git SHA + tag in /actuator/info -->
<git-commit-id-maven-plugin.version>9.0.2</git-commit-id-maven-plugin.version>
<!-- Bytecode manipulation (ASM) — 9.9.1 adds Java 26 class-file version 70 support
and retains Java 25 (version 69) compatibility. Pulled in by SpotBugs and
overridden at the top-level dependency block. -->
<asm.version>9.9.1</asm.version>
<!-- Non-BOM application dependencies -->
<protobuf.version>4.34.1</protobuf.version>
<!-- Jackson 3.x (tools.jackson.core) pulled in transitively by
spring-data-rest-webmvc. 3.1.0 has CVE GHSA-2m67-wjpj-xhg9 (HIGH);
3.1.1 is the fix. Pin here until the BOM catches up. -->
<jackson3.version>3.1.2</jackson3.version>
<!-- Sentry — error tracking (ADR-0022 nice-to-have). The SDK is a no-op
when SENTRY_DSN is empty, so this dep is safe even without a Sentry
project configured. -->
<sentry.version>8.20.0</sentry.version>
<!--
opentelemetry-logback-appender-1.0 tracks OTel API tightly.
2.26.1-alpha calls LogRecordBuilder.setException(Throwable) which
only exists from OTel API 1.58.0 onward. Spring Boot 4's BOM
resolves OTel API to 1.55.0, so the appender fails at startup
with NoSuchMethodError. Pin the appender to 2.18.1-alpha — the
last release aligned with OTel API 1.55. Revisit when SB bumps
its OTel floor.
-->
<opentelemetry-appender.version>2.18.1-alpha</opentelemetry-appender.version>
<testcontainers-keycloak.version>4.2.0</testcontainers-keycloak.version>
<!--
SonarCloud analysis configuration (sonarcloud.io — free for public repos).
sonar.host.url — overridden at runtime to https://sonarcloud.io (CI sets it via -D flag)
sonar.organization — required by SonarCloud; must match the org created at sonarcloud.io
sonar.token — generate at https://sonarcloud.io/account/security
Set SONAR_TOKEN in GitLab group CI/CD variables.
sonar.coverage.jacoco.xmlReportPaths — SonarCloud accepts multiple comma-separated
JaCoCo XML files and merges them. Providing both unit and IT reports gives Sonar
the full picture: CustomerController, AuthController, messaging classes etc. are
only exercised by @SpringBootTest ITests, not by pure unit tests.
Without jacoco-it.xml, Sonar would see ~32% coverage instead of ~80%.
sonar.exclusions — generated classes, config and shim code that skew metrics.
sonar.coverage.exclusions — mirrors JaCoCo <excludes>: Spring wiring, compat shims,
bootstrap classes and observability infrastructure that have no business logic.
-->
<sonar.host.url>https://sonarcloud.io</sonar.host.url>
<!-- SonarCloud org kept on the legacy 'iris-7' name post-Iris-rebrand
2026-04-28 : the org rename on sonarcloud.io is a manual user action
and we want to preserve the historical analysis (quality gate trend,
coverage history, issue ageing) which is tied to the project key.
If you rename the org on SonarCloud later, update both lines here
AND the in-house mirror at .gitlab-ci/quality.yml's sonar-analysis
job — keep them in sync. -->
<sonar.organization>iris-7</sonar.organization>
<sonar.projectKey>iris-7_iris-service-java</sonar.projectKey>
<sonar.projectName>Iris Service</sonar.projectName>
<sonar.coverage.jacoco.xmlReportPaths>
${project.reporting.outputDirectory}/jacoco/jacoco.xml,
${project.reporting.outputDirectory}/jacoco-it/jacoco.xml
</sonar.coverage.jacoco.xmlReportPaths>
<!--
Test execution report paths — Sonar's "Tests" widget reads these
to show pass/fail/skipped counts, duration, and per-class
execution time. This is the Sonar-philosophy-compliant
equivalent of Maven-site's Surefire + Failsafe HTML: same data,
ingested as metrics instead of rendered as standalone HTML.
-->
<sonar.junit.reportPaths>
${project.build.directory}/surefire-reports,
${project.build.directory}/failsafe-reports
</sonar.junit.reportPaths>
<!--
SARIF ingestion for third-party security scanners. Sonar
treats each SARIF finding as an "External Issue" alongside
its native Java issues, so Semgrep / Trivy findings appear
on the Issues page next to Sonar's own rules.
SARIF files are produced by the corresponding CI jobs
(see .gitlab-ci.yml: semgrep-sast, trivy:scan).
-->
<sonar.sarifReportPaths>
semgrep-report.sarif,
trivy-report.sarif,
spectral-report.sarif
</sonar.sarifReportPaths>
<sonar.exclusions>
**/compat/**,**/*.java17/**,**/*.java21/**,**/*.sb3/**,
**/generated-sources/**,**/target/**
</sonar.exclusions>
<sonar.cpd.exclusions>**/compat/**</sonar.cpd.exclusions>
<!--
Mirrors the JaCoCo <excludes> list so SonarQube computes coverage on the same
classes that the coverage gate checks — avoids false-low percentages from
infrastructure code that is intentionally untested.
-->
<sonar.coverage.exclusions>
org/springframework/**,
**/SecurityConfig.java,**/KeycloakConfig.java,
**/KafkaConfig.java,**/WebSocketConfig.java,
**/OpenApiConfig.java,**/HttpClientConfig.java,
**/ShedLockConfig.java,**/ObservabilityConfig.java,
**/QualityReportEndpoint.java,**/TestReportInfoContributor.java,
**/OtelLogbackInstaller.java,**/PyroscopeConfig.java,
**/IrisApplication.java
</sonar.coverage.exclusions>
</properties>
<!--
Force ASM 9.8 for ArchUnit.
ArchUnit 1.4.x ships with ASM 9.7 which does not support Java 25 bytecode (class version 69).
ASM 9.8 adds Java 25 support. This override propagates to ArchUnit's transitive dependency.
Force protobuf-java 4.34.1 (upgraded from 4.32.0) — CVE-2026-0994 (7.5 HIGH).
protobuf is transitive (spring-boot-starter-opentelemetry → OTel SDK → protobuf-java)
and not exposed as a property in the Spring Boot BOM, so it must be pinned here.
NOTE: CVE-2026-0994 persists on 4.34.1 — NVD does not yet list a patched version.
Kept at latest GA to minimise attack surface; revisit when NVD marks a version safe.
-->
<dependencyManagement>
<dependencies>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java</artifactId>
<version>${protobuf.version}</version>
</dependency>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java-util</artifactId>
<version>${protobuf.version}</version>
</dependency>
<dependency>
<groupId>org.ow2.asm</groupId>
<artifactId>asm</artifactId>
<version>${asm.version}</version>
</dependency>
<dependency>
<groupId>org.ow2.asm</groupId>
<artifactId>asm-commons</artifactId>
<version>${asm.version}</version>
</dependency>
<dependency>
<groupId>org.ow2.asm</groupId>
<artifactId>asm-tree</artifactId>
<version>${asm.version}</version>
</dependency>
<!-- CVE override: see ${jackson3.version} property. -->
<dependency>
<groupId>tools.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
<version>${jackson3.version}</version>
</dependency>
<dependency>
<groupId>tools.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>${jackson3.version}</version>
</dependency>
<dependency>
<groupId>tools.jackson.core</groupId>
<artifactId>jackson-annotations</artifactId>
<version>${jackson3.version}</version>
</dependency>
</dependencies>
</dependencyManagement>
<dependencies>
<!-- Language -->
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>${lombok.version}</version>
<scope>provided</scope>
</dependency>
<!-- Core -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<!--
Security — Spring Security + JWT (JJWT split-JAR pattern)
JJWT uses a three-artifact design to keep compile-time surface minimal:
jjwt-api → compile-time API (interfaces, builder methods) — required at compile scope
jjwt-impl → runtime implementation of the API — runtime only, never leak to consumers
jjwt-jackson → Jackson-based JSON serializer for JWT claims — runtime only
Keeping impl and jackson at runtime scope prevents accidental dependency on internals.
-->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-security</artifactId>
</dependency>
<!-- OAuth2 resource server — validates JWT tokens issued by Keycloak (or any OIDC provider).
When KEYCLOAK_URL is set, the app accepts Keycloak JWTs in addition to its own.
spring-security-oauth2-jose pulls in nimbus-jose-jwt for JWKS validation. -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-oauth2-resource-server</artifactId>
</dependency>
<dependency>
<groupId>io.jsonwebtoken</groupId>
<artifactId>jjwt-api</artifactId>
<version>${jjwt.version}</version>
</dependency>
<dependency>
<groupId>io.jsonwebtoken</groupId>
<artifactId>jjwt-impl</artifactId>
<version>${jjwt.version}</version>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>io.jsonwebtoken</groupId>
<artifactId>jjwt-jackson</artifactId>
<version>${jjwt.version}</version>
<scope>runtime</scope>
</dependency>
<!-- JPA — Spring Data JPA + Hibernate ORM, schema managed by Flyway -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-jpa</artifactId>
</dependency>
<!-- HTTP request input validation — @Valid / @NotBlank / @Email on DTOs -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-validation</artifactId>
</dependency>
<!--
Observability stack — four complementary artifacts:
actuator → /actuator/health, /actuator/prometheus, etc.
micrometer-prometheus → Prometheus registry: scrape at /actuator/prometheus
opentelemetry → OTLP trace + log export to Tempo / Loki via OTEL collector
datasource-micrometer → instruments JDBC DataSource with Micrometer Observations
(query count, latency histograms, slow-query detection)
-->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-actuator</artifactId>
</dependency>
<!-- HATEOAS + HAL Explorer — browse /actuator endpoints visually in a browser -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-hateoas</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.data</groupId>
<artifactId>spring-data-rest-hal-explorer</artifactId>
</dependency>
<dependency>
<groupId>io.micrometer</groupId>
<artifactId>micrometer-registry-prometheus</artifactId>
</dependency>
<!-- spring-boot-starter-opentelemetry: SB4-only, declared in sb4 profile below -->
<!-- SB3 equivalent (micrometer-tracing-bridge-otel + opentelemetry-exporter-otlp) in sb3 profile -->
<!-- OTLP log export: bridges Logback log events to OpenTelemetry pipeline (→ Loki via LGTM) -->
<dependency>
<groupId>io.opentelemetry.instrumentation</groupId>
<artifactId>opentelemetry-logback-appender-1.0</artifactId>
<version>${opentelemetry-appender.version}</version>
</dependency>
<dependency>
<groupId>net.ttddyy.observation</groupId>
<artifactId>datasource-micrometer-spring-boot</artifactId>
<version>${datasource-micrometer.version}</version>
</dependency>
<!--
Fabric8 Kubernetes client — the ChaosController (org.iris.chaos)
uses it to create Chaos Mesh CRs (PodChaos / NetworkChaos /
StressChaos) on demand from the UI chaos page. Off-cluster the
bean still instantiates; the HTTP call fails at runtime with a
clear 503 if no kubeconfig is present (see ChaosController
exception handling). RBAC for the `iris-backend` ServiceAccount
is under deploy/kubernetes/base/backend/rbac.yaml.
-->
<dependency>
<groupId>io.fabric8</groupId>
<artifactId>kubernetes-client</artifactId>
<version>${fabric8-kubernetes-client.version}</version>
</dependency>
<!--
Test-scoped mock Kubernetes API server for ChaosServiceTest.
Shares the kubernetes-client version so the client + server
speak the same API shape. Provides the @EnableKubernetesMockClient
JUnit extension which injects a stubbed KubernetesClient +
KubernetesMockServer into the test class.
-->
<dependency>
<groupId>io.fabric8</groupId>
<artifactId>kubernetes-server-mock</artifactId>
<version>${fabric8-kubernetes-client.version}</version>
<scope>test</scope>
</dependency>
<!-- Pyroscope — continuous profiling agent (CPU, alloc, wall clock).
Pushes JFR profiles to the Pyroscope server every 10s.
Requires no JVM -javaagent flag when using the embedded SDK. -->
<dependency>
<groupId>io.pyroscope</groupId>
<artifactId>agent</artifactId>
<version>${pyroscope.version}</version>
</dependency>
<!-- WebSocket — real-time notifications via STOMP over SockJS -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-websocket</artifactId>
</dependency>
<!--
Sentry — error tracking SaaS. The starter auto-wires an
@ExceptionHandler-aware Spring integration + a Logback appender so
every ERROR log becomes a Sentry event.
DSN comes from the SENTRY_DSN env var (empty = SDK disabled, fine
in local dev / when the free tier is not configured).
Free tier: 5k events/month — covers the ephemeral demo (ADR-0022).
-->
<dependency>
<groupId>io.sentry</groupId>
<artifactId>sentry-spring-boot-starter-jakarta</artifactId>
<version>${sentry.version}</version>
</dependency>
<!-- API docs — SpringDoc generates OpenAPI 3 spec + Swagger UI at /swagger-ui.html -->
<dependency>
<groupId>org.springdoc</groupId>
<artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
<version>${springdoc.version}</version>
</dependency>
<!--
DB — PostgreSQL driver (runtime only) + Flyway migration engine.
flyway-database-postgresql adds the PostgreSQL-specific dialect support
required by Flyway 10+ (the generic flyway-core no longer bundles DB drivers).
-->
<dependency>
<groupId>org.postgresql</groupId>
<artifactId>postgresql</artifactId>
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-flyway</artifactId>
</dependency>
<dependency>
<groupId>org.flywaydb</groupId>
<artifactId>flyway-database-postgresql</artifactId>
</dependency>
<!--
ShedLock — distributed scheduler lock (prevents concurrent cron execution in clusters).
Two-artifact split:
shedlock-spring → Spring @SchedulerLock annotation support + AOP aspect
shedlock-provider-jdbc-template → JDBC backend that uses the shedlock DB table
(created by V2__create_shedlock_table.sql)
-->
<dependency>
<groupId>net.javacrumbs.shedlock</groupId>
<artifactId>shedlock-spring</artifactId>
<version>${shedlock.version}</version>
</dependency>
<dependency>
<groupId>net.javacrumbs.shedlock</groupId>
<artifactId>shedlock-provider-jdbc-template</artifactId>
<version>${shedlock.version}</version>
</dependency>
<!-- Kafka — Spring Kafka for producer/consumer + request-reply pattern -->
<dependency>
<groupId>org.springframework.kafka</groupId>
<artifactId>spring-kafka</artifactId>
</dependency>
<!--
Redis — Spring Data Redis for distributed caching.
Replaces the in-memory RecentCustomerBuffer with a Redis LIST (LPUSH + LTRIM + LRANGE),
which survives pod restarts and is shared across all replicas.
Lettuce is the default (non-blocking) Redis client included transitively.
-->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-redis</artifactId>
</dependency>
<!-- Application-level entity cache — individual customer lookups (findById).
No overlap with Redis which handles the recent-customers ring buffer only. -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-cache</artifactId>
</dependency>
<dependency>
<groupId>com.github.ben-manes.caffeine</groupId>
<artifactId>caffeine</artifactId>
</dependency>
<!-- Bucket4j — in-memory token-bucket rate limiting (100 req/min per IP) -->
<dependency>
<groupId>com.bucket4j</groupId>
<artifactId>bucket4j-core</artifactId>
<version>${bucket4j.version}</version>
</dependency>
<!--
Resilience4j — circuit breaker + retry for external HTTP calls.
Uses the spring-boot3 artifact (not spring-boot2) for Spring Boot 3/4 auto-configuration.
Provides @CircuitBreaker, @Retry, @TimeLimiter annotations via AOP.
-->
<dependency>
<groupId>io.github.resilience4j</groupId>
<artifactId>resilience4j-spring-boot3</artifactId>
<version>${resilience4j.version}</version>
</dependency>
<!-- Spring AI — Ollama starter for local LLM inference (llama3.2 model) -->
<dependency>
<groupId>org.springframework.ai</groupId>
<artifactId>spring-ai-starter-model-ollama</artifactId>
<version>${spring-ai.version}</version>
</dependency>
<!--
Spring AI MCP server (WebMvc transport) — exposes @Tool-annotated
methods as Model Context Protocol tools at /sse + /mcp/message.
Per ADR-0062, the server registers an explicit allowlist of services
(Order/Product/Customer/Chaos/Logs/Metrics/Grafana/Actuator/OpenApi)
via MethodToolCallbackProvider — see org.iris.mcp.McpConfig.
The starter pulls in mcp-spring-webmvc + spring-ai-mcp + the MCP SDK
0.17.0 ; transport is HTTP/SSE so the same Spring Security filter
chain applies to LLM callers as to REST callers.
-->
<dependency>
<groupId>org.springframework.ai</groupId>
<artifactId>spring-ai-starter-mcp-server-webmvc</artifactId>
<version>${spring-ai.version}</version>
</dependency>
<!--
ONNX Runtime — Microsoft's Java bindings for cross-language ML
inference. Loads `.onnx` artefacts produced by the Python
training pipeline (iris-service-python `iris_service.ml.train_churn`)
and runs predictions in-process — NO sidecar service. Per shared
ADR-0060 §"Decision". Ships ~30 MB bundled native libs ; the JAR
stays usable on every runtime arch we deploy to.
-->
<dependency>
<groupId>com.microsoft.onnxruntime</groupId>
<artifactId>onnxruntime</artifactId>
<version>${onnxruntime.version}</version>
</dependency>
<!--
Tests — split into unit (surefire) and integration (failsafe) phases.
spring-boot-starter-test → JUnit 5, Mockito, AssertJ, Spring test support
spring-boot-webmvc-test → RestTestClient (Spring Boot 4 MockMvc DSL)
spring-boot-testcontainers → @ServiceConnection auto-wiring for Testcontainers
junit-jupiter → Testcontainers JUnit 5 extension (@Testcontainers)
postgresql (TC) → PostgreSQL Testcontainer
spring-kafka-test → EmbeddedKafkaBroker for unit tests
kafka (TC) → Kafka Testcontainer for integration tests
archunit-junit5 → architectural constraint tests (disabled on Java 25)
spring-security-test → SecurityMockMvcRequestPostProcessors.user(...)
-->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency>
<!-- spring-boot-webmvc-test: SB4-only, declared in sb4 profile below -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-testcontainers</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.testcontainers</groupId>
<artifactId>junit-jupiter</artifactId>
<version>${testcontainers.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.testcontainers</groupId>
<artifactId>postgresql</artifactId>
<version>${testcontainers.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.springframework.kafka</groupId>
<artifactId>spring-kafka-test</artifactId>
<scope>test</scope>
</dependency>
<!--
jqwik — property-based testing. @Property methods take @ForAll
parameters; jqwik synthesises many inputs per method. Used by
AggregationServicePropertyTest to demonstrate the pattern on a
parallelism invariant (see ADR list / T3 follow-up).
-->
<dependency>
<groupId>net.jqwik</groupId>
<artifactId>jqwik</artifactId>
<version>${jqwik.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.testcontainers</groupId>
<artifactId>kafka</artifactId>
<version>${testcontainers.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.tngtech.archunit</groupId>
<artifactId>archunit-junit5</artifactId>
<version>${archunit.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.springframework.security</groupId>
<artifactId>spring-security-test</artifactId>
<scope>test</scope>
</dependency>
<!-- Testcontainers Keycloak module — spins up a real Keycloak instance for ITests.
Uses the official quay.io/keycloak/keycloak image with a pre-imported realm. -->
<dependency>
<groupId>com.github.dasniko</groupId>
<artifactId>testcontainers-keycloak</artifactId>
<version>${testcontainers-keycloak.version}</version>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<!--
spring-boot-maven-plugin — packages the application as an executable layered JAR.
Layered JARs split content into: dependencies / spring-boot-loader / snapshot-dependencies
/ application. Docker can cache the stable layers (deps) and only rebuild the
application layer on code changes. Also supports AOT processing for GraalVM native images.
Usage: mvn spring-boot:run | mvn package → target/customerservice-0.0.1-SNAPSHOT.jar
-->
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<executions>
<execution>
<id>build-info</id>
<goals><goal>build-info</goal></goals>
</execution>
</executions>
</plugin>
<!--
git-commit-id-maven-plugin — exposes the build's git SHA, tag,
branch, and commit time to /actuator/info as `git.*` keys.
Combined with build-info above (`build.*`) this gives the
README footer + every Tempo trace a clear, immutable identity:
"this trace came from build a1b2c3d (v1.3, 2026-04-19)".
Pinned in <properties>; runs in the `initialize` phase so the
generated git.properties is on the classpath before tests.
-->
<plugin>
<groupId>io.github.git-commit-id</groupId>
<artifactId>git-commit-id-maven-plugin</artifactId>
<version>${git-commit-id-maven-plugin.version}</version>
<executions>
<execution>
<id>get-git-info</id>
<goals><goal>revision</goal></goals>
<phase>initialize</phase>
</execution>
</executions>
<configuration>
<generateGitPropertiesFile>true</generateGitPropertiesFile>
<generateGitPropertiesFilename>${project.build.outputDirectory}/git.properties</generateGitPropertiesFilename>
<!-- Skip if the working tree isn't a git repo (e.g. in
a tarball release) so the build still passes. -->
<failOnNoGitDirectory>false</failOnNoGitDirectory>
</configuration>
</plugin>
<!--
maven-surefire-plugin — unit tests only (fast, no Docker required).
*ITest classes are excluded here: they need a running Docker daemon
(Testcontainers) and are handled by failsafe in the integration-test phase.
Convention: unit tests → *Test.java, integration tests → *ITest.java.
-->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<!--
Spring Boot's parent POM injects JUnit 5 UID tracking via the deprecated
'systemProperties' element in its 'default-test' execution. We override
that execution here to:
1. Replace 'systemProperties' with 'systemPropertyVariables' (non-deprecated)
2. Keep the same tracking properties so JUnit behaviour is unchanged
combine.self="override" on systemProperties clears the parent-injected list.
See: https://issues.apache.org/jira/browse/SUREFIRE-2190
-->
<executions>
<execution>
<id>default-test</id>
<configuration>
<excludes>
<exclude>**/*ITest.java</exclude>
</excludes>
<!-- Suppress deprecated systemProperties from parent POM -->
<systemProperties combine.self="override"/>
<systemPropertyVariables>
<junit.platform.listeners.uid.tracking.enabled>true</junit.platform.listeners.uid.tracking.enabled>
<junit.platform.listeners.uid.tracking.output.dir>${project.build.directory}/test-ids</junit.platform.listeners.uid.tracking.output.dir>
</systemPropertyVariables>
</configuration>
</execution>
</executions>
<configuration>
<excludes>
<exclude>**/*ITest.java</exclude>
</excludes>
<!--
Kept at the default single fork after a parallel trial:
forkCount=1C caused AggregationServiceTest
`aggregate_runsBothTasksInParallel` to flake on CI because
the test asserts that two 200 ms virtual-thread tasks
complete in under 360 ms — the CPU contention between
sibling forks blows that budget (observed 1.2 s wall-clock
in pipeline 345). The unit-test job is already short
(~31 s on CI) so the payoff didn't justify the flakiness.
Revisit once timing-sensitive tests are tagged for
single-thread execution or the assertion is loosened to
cope with parallel forks.
-->
<forkCount>1</forkCount>
<reuseForks>true</reuseForks>
</configuration>
</plugin>
<!--
maven-failsafe-plugin — integration tests (*ITest classes, require Docker).
Runs in the integration-test phase, AFTER surefire unit tests.
Failsafe is fault-tolerant: it always runs the verify goal to report results
even if some tests fail, unlike surefire which stops immediately on failure.
This ensures JaCoCo artifacts are always produced for coverage reporting.
-->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
<configuration>
<includes>
<include>**/*ITest.java</include>
</includes>
<!--
ADR-0034 option A: skip Keycloak-heavy ITs by default
so the macbook-local 4 GB Docker Desktop VM doesn't
OOM (Quarkus container peaks at ~900 MB on top of
Postgres + Kafka + Redis + Spring fork). The weekly
`integration-test:keycloak` CI job opts in via
`-Dgroups=keycloak-heavy`. Local: use the same flag.
-->
<excludedGroups>keycloak-heavy</excludedGroups>
<!-- Same fix as surefire above — override deprecated systemProperties from parent POM -->
<systemPropertyVariables>
<junit.platform.listeners.uid.tracking.enabled>true</junit.platform.listeners.uid.tracking.enabled>
<junit.platform.listeners.uid.tracking.output.dir>${project.build.directory}/test-ids</junit.platform.listeners.uid.tracking.output.dir>
</systemPropertyVariables>
<!--
Kept at the default (single fork) after measurement:
forkCount=2 actually SLOWED the integration-test job
(~120 s → ~121 s) because the two heaviest tests
(KeycloakAuthITest ~95 s, AuthITest ~50 s) each have
their own Testcontainers boot cost (Postgres + Keycloak
image pull) — paid once per fork instead of being
amortised by the JVM's ContextCache. The long-tail
test dominates wall-clock regardless of parallelism.
Revisit if ITest mass grows or we split KeycloakAuthITest
into smaller, more parallelisable pieces.
-->
<forkCount>1</forkCount>
<reuseForks>true</reuseForks>
</configuration>
<executions>
<execution>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
</execution>
</executions>
</plugin>
<!--
JaCoCo — code coverage for unit + integration tests.
Strategy (6 executions):
1. prepare-agent → instruments JVM for surefire → jacoco.exec
2. prepare-agent-integration → instruments JVM for failsafe → jacoco-it.exec
3. report → HTML/XML report for unit tests (target/site/jacoco)
4. report-integration → HTML/XML report for ITests (target/site/jacoco-it)
5. merge → combines jacoco.exec + jacoco-it.exec → jacoco-merged.exec
6. check → fails build if merged instruction coverage < 60 %
Why merge? Unit tests alone cover ~20 % (JwtTokenProviderTest + ArchUnit skips);
integration tests cover the full Spring context stack. Merging gives an accurate
combined coverage figure for the quality gate.
-->
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<!-- Explicit version required: Maven warns when a plugin in <build><plugins> has
no version, even when the parent's pluginManagement already resolves it. -->
<version>${jacoco-maven-plugin.version}</version>
<configuration>
<excludes>
<!--
Classes excluded from coverage measurement — not business logic:
1. Spring Boot 3 / Java 17-21 overlay classes (src/main/java/org/springframework/**):
These are compatibility shims for the -Dsb3 / -Dcompat profiles. They are
never loaded in the default SB4/Java25 build, so measuring their coverage
would just punish the default profile. Exclude by package prefix.
-->
<exclude>org/springframework/**</exclude>
<!--
2. Pure Spring wiring — @Configuration classes whose ONLY job
is to return @Bean instances via the framework's DI glue.
These classes are INCLUDED in coverage as of 2026-04-23
because tests now cover the Bean-factory logic (default
values, guard clauses, conditional @Bean definitions).
The original exclusion was too broad — some configs DO
have testable logic (KeycloakConfig's issuer-URI-shape
branching, SecurityConfig's CORS rules, KafkaConfig's
serialization contract).
Only PyroscopeConfig stays excluded — it wraps a static
PyroscopeAgent.start() call that's hard to test without
mockStatic + pulls the real agent jar.
-->
<exclude>org/iris/observability/PyroscopeConfig.class</exclude>
<!--
3. Observability/tooling infrastructure — now INCLUDED in
coverage as of 2026-04-23. Tests shipped this session :
QualityReportEndpoint (11 tests), TestReportInfoContributor
(4 tests), OtelLogbackInstaller (2 tests), StartupTimeTracker
(4 tests) + all quality/parsers/ + providers/ tests merged
from prior sessions. The "I/O-heavy, excluded" rationale
is no longer the reality — the tests mock the I/O or use
classpath fixtures.
-->
<!--
Phase Q-2 / Q-2b (2026-04-22, ADR-0052) — parsers + providers
now INCLUDED in coverage. Fixture-driven tests shipped for :
SurefireReportParser, JacocoReportParser, SpotBugsReportParser,
PmdReportParser, CheckstyleReportParser, OwaspReportParser,
PitestReportParser, MetricsSectionProvider,
DependenciesSectionProvider, LicensesSectionProvider,
ApiSectionProvider, BuildInfoSectionProvider. Plus the
QualityReportGenerator CLI (3 tests executing main()).
-->
<!-- (parsers + providers + QualityReportGenerator un-excluded
2026-04-23 — see comment above) -->
<!--
4. Application bootstrap
-->
<exclude>org/iris/IrisApplication.class</exclude>
</excludes>
</configuration>
<executions>
<execution>
<id>prepare-agent</id>
<goals><goal>prepare-agent</goal></goals>
</execution>
<execution>
<id>prepare-agent-integration</id>
<goals><goal>prepare-agent-integration</goal></goals>
</execution>
<execution>
<id>report</id>
<phase>test</phase>
<goals><goal>report</goal></goals>
</execution>
<execution>
<id>report-integration</id>
<phase>post-integration-test</phase>
<goals><goal>report-integration</goal></goals>
</execution>
<!-- Merge unit + integration exec files into one before checking -->
<execution>
<id>merge</id>
<phase>post-integration-test</phase>
<goals><goal>merge</goal></goals>
<configuration>
<fileSets>
<fileSet>
<directory>${project.build.directory}</directory>
<includes>
<!-- jacoco.exec (unit) + jacoco-it.exec (integration) -->
<include>jacoco*.exec</include>
</includes>
</fileSet>
</fileSets>
<destFile>${project.build.directory}/jacoco-merged.exec</destFile>
</configuration>
</execution>
<!--
Merged coverage report — HTML + XML + CSV from the
combined unit + IT exec. QualityReportEndpoint reads
the CSV; SonarCloud prefers the XML (wired via
`sonar.coverage.jacoco.xmlReportPaths`). Producing
the merged CSV here moves /actuator/quality from
"unit-only ~45 %" to the real ~70 % figure the gate
already enforces.
-->
<execution>
<id>report-merged</id>
<phase>post-integration-test</phase>
<goals><goal>report</goal></goals>
<configuration>
<dataFile>${project.build.directory}/jacoco-merged.exec</dataFile>
<outputDirectory>${project.reporting.outputDirectory}/jacoco-merged</outputDirectory>
</configuration>
</execution>
<!-- Coverage gate: two-tier per shared ADR-0059.
- global BUNDLE >= 70% (infrastructure/config excluded)
- new e-commerce packages org.iris.{order,product}.* >= 40%
regression gate ; the property tests + cascade integration tests
cover pure-domain methods (canTransitionTo, computeTotal) at
100%, but CRUD controllers + repositories are still ~50%.
CLIMB PLAN: 40% now → 70% after @WebMvcTest land → 90% final.
-->
<execution>
<id>check</id>
<goals><goal>check</goal></goals>
<configuration>
<dataFile>${project.build.directory}/jacoco-merged.exec</dataFile>
<rules>
<rule>
<element>BUNDLE</element>