Skip to content

Commit 618cd2a

Browse files
committed
test(store-redis): improve coverage from 77% to 84% and raise threshold to 80%
- Add test exercising buildConnection() exception path directly - Raise minimumCoverage from 0.77 to 0.80 in store-redis/build.gradle - Refresh all gradle.lockfiles for Java 21 compatibility - Add CLAUDE.md with codebase guidance for Claude Code
1 parent e37ab36 commit 618cd2a

10 files changed

Lines changed: 252 additions & 155 deletions

File tree

CLAUDE.md

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
# CLAUDE.md
2+
3+
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
4+
5+
## What this repo is
6+
7+
`path-facilities` is a multi-module Gradle library providing facility implementations for the [MX Path SDK](https://github.com/mxenabled/path-core). Each subproject implements a facility interface from `path-core` using a specific third-party technology. The `platform` subproject is a BOM (Bill of Materials) consumed by downstream services.
8+
9+
**Subprojects and their facility type:**
10+
- `store-redis``Store` implementation backed by Redis via Lettuce
11+
- `store-vault``Store` implementation backed by HashiCorp Vault
12+
- `encryption-service-jasypt``EncryptionService` using Jasypt
13+
- `encryption-service-vault``EncryptionService` using Vault transit engine
14+
- `message-broker-nats``MessageBroker` using NATS
15+
- `fault-tolerant-executor-resilience4j``FaultTolerantExecutor` using Resilience4j (circuit breaker, bulkhead, time limiter)
16+
- `exception-reporter-honeybadger``ExceptionReporter` using Honeybadger
17+
18+
## Code patterns
19+
20+
Each subproject follows the same structure:
21+
- A main implementation class (e.g. `RedisStore`) that takes a `@Configuration`-annotated configuration POJO in its constructor
22+
- A configuration class annotated with `@Data` (Lombok) where each field is annotated with `@ConfigurationField`
23+
- Module-specific exception classes for distinct failure modes (authentication, operation, configuration, unsupported operation)
24+
25+
Tests are written in **Groovy** (Spock framework) even though sources are Java.
26+
27+
## Commands
28+
29+
**Build all:**
30+
```shell
31+
./gradlew clean build
32+
```
33+
34+
**Test all:**
35+
```shell
36+
./gradlew clean test
37+
```
38+
39+
**Format (Spotless):**
40+
```shell
41+
./gradlew spotlessApply
42+
```
43+
44+
**Single subproject (via helper scripts):**
45+
```shell
46+
./bin/build store-redis
47+
./bin/test store-redis
48+
./bin/format store-redis
49+
```
50+
51+
**Single subproject (via Gradle):**
52+
```shell
53+
./gradlew :store-redis:clean :store-redis:build
54+
./gradlew :store-redis:clean :store-redis:test
55+
./gradlew :store-redis:spotlessApply
56+
```
57+
58+
**Publish locally for testing in other services:**
59+
```shell
60+
./gradlew publishToMavenLocal
61+
```
62+
63+
**Dependency management:**
64+
```shell
65+
./gradlew assemble --write-locks # regenerate lockfiles for all projects
66+
./gradlew :store-redis:dependencies --write-locks # regenerate lockfile for one project
67+
./gradlew vogueReport # view outdated dependencies
68+
./gradlew dependencyCheckAnalyze # scan for vulnerabilities
69+
```
70+
71+
## Commits and releases
72+
73+
Commits must follow [Conventional Commits](https://www.conventionalcommits.org/). Allowed types: `build`, `chore`, `docs`, `feat`, `fix`, `perf`, `refactor`, `revert`, `style`, `test`. Use `git cz` (commitizen) for interactive prompting after running `bin/setup`.
74+
75+
Releases are automated via [release-please](https://github.com/googleapis/release-please). The version in `build.gradle` and `README.md` is managed by release-please (do not manually bump it). Published to Maven Central under group `com.mx.path-facilities`.

encryption-service-jasypt/gradle.lockfile

Lines changed: 23 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -9,15 +9,16 @@ com.fasterxml.jackson.core:jackson-databind:2.21.3=testRuntimeClasspath
99
com.fasterxml.jackson:jackson-bom:2.21.3=testRuntimeClasspath
1010
com.github.oowekyala.ooxml:nice-xml-messages:3.1=pmd
1111
com.github.rholder:guava-retrying:2.0.0=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
12-
com.github.spotbugs:spotbugs-annotations:4.9.8=annotationProcessor,compileClasspath,spotbugs,testAnnotationProcessor,testCompileClasspath
13-
com.github.spotbugs:spotbugs:4.9.8=spotbugs
12+
com.github.spotbugs:spotbugs-annotations:4.10.2=compileClasspath,spotbugs,testCompileClasspath
13+
com.github.spotbugs:spotbugs-annotations:4.9.8=annotationProcessor,testAnnotationProcessor
14+
com.github.spotbugs:spotbugs:4.10.2=spotbugs
1415
com.github.stephenc.jcip:jcip-annotations:1.0-1=spotbugs
1516
com.google.code.findbugs:jsr305:3.0.2=annotationProcessor,checkstyle,compileClasspath,runtimeClasspath,spotbugs,testAnnotationProcessor,testCompileClasspath,testRuntimeClasspath
16-
com.google.code.gson:gson:2.13.2=pmd,spotbugs
17-
com.google.code.gson:gson:2.14.0=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
17+
com.google.code.gson:gson:2.13.2=pmd
18+
com.google.code.gson:gson:2.14.0=compileClasspath,runtimeClasspath,spotbugs,testCompileClasspath,testRuntimeClasspath
1819
com.google.errorprone:error_prone_annotations:2.36.0=checkstyle
19-
com.google.errorprone:error_prone_annotations:2.41.0=pmd,spotbugs
20-
com.google.errorprone:error_prone_annotations:2.48.0=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
20+
com.google.errorprone:error_prone_annotations:2.41.0=pmd
21+
com.google.errorprone:error_prone_annotations:2.48.0=compileClasspath,runtimeClasspath,spotbugs,testCompileClasspath,testRuntimeClasspath
2122
com.google.guava:failureaccess:1.0.1=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
2223
com.google.guava:failureaccess:1.0.3=checkstyle
2324
com.google.guava:guava:32.1.3-jre=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
@@ -40,7 +41,7 @@ commons-beanutils:commons-beanutils:1.11.0=checkstyle
4041
commons-codec:commons-codec:1.14=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
4142
commons-codec:commons-codec:1.15=checkstyle
4243
commons-collections:commons-collections:3.2.2=checkstyle
43-
commons-io:commons-io:2.20.0=spotbugs
44+
commons-io:commons-io:2.21.0=spotbugs
4445
commons-logging:commons-logging:1.2=testRuntimeClasspath
4546
info.picocli:picocli:4.7.7=checkstyle
4647
io.github.cdimascio:dotenv-java:2.3.2=testRuntimeClasspath
@@ -51,7 +52,7 @@ io.opentracing:opentracing-util:0.33.0=testRuntimeClasspath
5152
jakarta.activation:jakarta.activation-api:2.1.4=testRuntimeClasspath
5253
jakarta.xml.bind:jakarta.xml.bind-api:4.0.4=testRuntimeClasspath
5354
jakarta.xml.soap:jakarta.xml.soap-api:3.0.2=testRuntimeClasspath
54-
jaxen:jaxen:2.0.0=spotbugs
55+
jaxen:jaxen:2.0.6=spotbugs
5556
net.bytebuddy:byte-buddy-agent:1.17.7=testCompileClasspath,testRuntimeClasspath
5657
net.bytebuddy:byte-buddy:1.17.7=testCompileClasspath
5758
net.bytebuddy:byte-buddy:1.18.3=testRuntimeClasspath
@@ -62,12 +63,10 @@ net.sourceforge.pmd:pmd-core:7.22.0=pmd
6263
net.sourceforge.pmd:pmd-java:7.22.0=pmd
6364
org.antlr:antlr4-runtime:4.13.2=checkstyle
6465
org.antlr:antlr4-runtime:4.9.3=pmd
65-
org.apache.bcel:bcel:6.11.0=spotbugs
66+
org.apache.bcel:bcel:6.12.0=spotbugs
6667
org.apache.commons:commons-lang3:3.18.0=checkstyle
67-
org.apache.commons:commons-lang3:3.19.0=spotbugs
68-
org.apache.commons:commons-lang3:3.20.0=compileClasspath,pmd,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
69-
org.apache.commons:commons-text:1.14.0=spotbugs
70-
org.apache.commons:commons-text:1.15.0=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
68+
org.apache.commons:commons-lang3:3.20.0=compileClasspath,pmd,runtimeClasspath,spotbugs,testCompileClasspath,testRuntimeClasspath
69+
org.apache.commons:commons-text:1.15.0=compileClasspath,runtimeClasspath,spotbugs,testCompileClasspath,testRuntimeClasspath
7170
org.apache.commons:commons-text:1.3=checkstyle
7271
org.apache.httpcomponents.client5:httpclient5:5.1.3=checkstyle
7372
org.apache.httpcomponents.core5:httpcore5-h2:5.1.3=checkstyle
@@ -76,8 +75,8 @@ org.apache.httpcomponents:httpclient:4.5.13=checkstyle
7675
org.apache.httpcomponents:httpclient:4.5.14=testRuntimeClasspath
7776
org.apache.httpcomponents:httpcore:4.4.14=checkstyle
7877
org.apache.httpcomponents:httpcore:4.4.16=testRuntimeClasspath
79-
org.apache.logging.log4j:log4j-api:2.25.3=spotbugs
80-
org.apache.logging.log4j:log4j-core:2.25.3=spotbugs
78+
org.apache.logging.log4j:log4j-api:2.26.0=spotbugs
79+
org.apache.logging.log4j:log4j-core:2.26.0=spotbugs
8180
org.apache.maven.doxia:doxia-core:1.12.0=checkstyle
8281
org.apache.maven.doxia:doxia-logging-api:1.12.0=checkstyle
8382
org.apache.maven.doxia:doxia-module-xdoc:1.12.0=checkstyle
@@ -109,26 +108,28 @@ org.jspecify:jspecify:1.0.0=checkstyle
109108
org.junit.jupiter:junit-jupiter-api:5.14.0=testCompileClasspath,testRuntimeClasspath
110109
org.junit.platform:junit-platform-commons:1.14.0=testCompileClasspath,testRuntimeClasspath
111110
org.junit.platform:junit-platform-engine:1.14.0=testCompileClasspath,testRuntimeClasspath
112-
org.junit:junit-bom:5.14.0=annotationProcessor,spotbugs,testAnnotationProcessor,testCompileClasspath,testRuntimeClasspath
111+
org.junit:junit-bom:5.14.0=annotationProcessor,testAnnotationProcessor,testCompileClasspath,testRuntimeClasspath
112+
org.junit:junit-bom:6.1.0=spotbugs
113113
org.mockito:mockito-core:5.23.0=testCompileClasspath,testRuntimeClasspath
114114
org.objenesis:objenesis:3.3=runtimeClasspath,testRuntimeClasspath
115115
org.opentest4j:opentest4j:1.3.0=testCompileClasspath,testRuntimeClasspath
116-
org.ow2.asm:asm-analysis:9.9=spotbugs
116+
org.ow2.asm:asm-analysis:9.10.1=spotbugs
117+
org.ow2.asm:asm-commons:9.10.1=spotbugs
117118
org.ow2.asm:asm-commons:9.8=jacocoAnt
118-
org.ow2.asm:asm-commons:9.9=spotbugs
119+
org.ow2.asm:asm-tree:9.10.1=spotbugs
119120
org.ow2.asm:asm-tree:9.8=jacocoAnt
120-
org.ow2.asm:asm-tree:9.9=spotbugs
121-
org.ow2.asm:asm-util:9.9=spotbugs
121+
org.ow2.asm:asm-util:9.10.1=spotbugs
122+
org.ow2.asm:asm:9.10.1=spotbugs
122123
org.ow2.asm:asm:9.8=jacocoAnt
123-
org.ow2.asm:asm:9.9=spotbugs
124124
org.ow2.asm:asm:9.9.1=pmd
125125
org.pcollections:pcollections:4.0.2=pmd
126126
org.projectlombok:lombok:1.18.42=annotationProcessor,compileClasspath,lombok,testAnnotationProcessor,testCompileClasspath
127127
org.reflections:reflections:0.10.2=checkstyle,testRuntimeClasspath
128128
org.slf4j:jul-to-slf4j:1.7.36=pmd
129129
org.slf4j:slf4j-api:1.7.30=compileClasspath,runtimeClasspath,testCompileClasspath
130130
org.slf4j:slf4j-api:1.7.32=testRuntimeClasspath
131-
org.slf4j:slf4j-api:2.0.17=spotbugs,spotbugsSlf4j
131+
org.slf4j:slf4j-api:2.0.17=spotbugsSlf4j
132+
org.slf4j:slf4j-api:2.0.18=spotbugs
132133
org.slf4j:slf4j-simple:1.7.30=testCompileClasspath,testRuntimeClasspath
133134
org.slf4j:slf4j-simple:2.0.17=spotbugsSlf4j
134135
org.spockframework:spock-bom:2.4-M6-groovy-3.0=testCompileClasspath,testRuntimeClasspath

encryption-service-vault/gradle.lockfile

Lines changed: 23 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,16 @@ com.fasterxml.jackson.core:jackson-databind:2.21.3=testRuntimeClasspath
1010
com.fasterxml.jackson:jackson-bom:2.21.3=testRuntimeClasspath
1111
com.github.oowekyala.ooxml:nice-xml-messages:3.1=pmd
1212
com.github.rholder:guava-retrying:2.0.0=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
13-
com.github.spotbugs:spotbugs-annotations:4.9.8=annotationProcessor,compileClasspath,spotbugs,testAnnotationProcessor,testCompileClasspath
14-
com.github.spotbugs:spotbugs:4.9.8=spotbugs
13+
com.github.spotbugs:spotbugs-annotations:4.10.2=compileClasspath,spotbugs,testCompileClasspath
14+
com.github.spotbugs:spotbugs-annotations:4.9.8=annotationProcessor,testAnnotationProcessor
15+
com.github.spotbugs:spotbugs:4.10.2=spotbugs
1516
com.github.stephenc.jcip:jcip-annotations:1.0-1=spotbugs
1617
com.google.code.findbugs:jsr305:3.0.2=annotationProcessor,checkstyle,compileClasspath,runtimeClasspath,spotbugs,testAnnotationProcessor,testCompileClasspath,testRuntimeClasspath
17-
com.google.code.gson:gson:2.13.2=pmd,spotbugs
18-
com.google.code.gson:gson:2.14.0=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
18+
com.google.code.gson:gson:2.13.2=pmd
19+
com.google.code.gson:gson:2.14.0=compileClasspath,runtimeClasspath,spotbugs,testCompileClasspath,testRuntimeClasspath
1920
com.google.errorprone:error_prone_annotations:2.36.0=checkstyle
20-
com.google.errorprone:error_prone_annotations:2.41.0=pmd,spotbugs
21-
com.google.errorprone:error_prone_annotations:2.48.0=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
21+
com.google.errorprone:error_prone_annotations:2.41.0=pmd
22+
com.google.errorprone:error_prone_annotations:2.48.0=compileClasspath,runtimeClasspath,spotbugs,testCompileClasspath,testRuntimeClasspath
2223
com.google.guava:failureaccess:1.0.1=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
2324
com.google.guava:failureaccess:1.0.3=checkstyle
2425
com.google.guava:guava:32.1.3-jre=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
@@ -41,7 +42,7 @@ commons-beanutils:commons-beanutils:1.11.0=checkstyle
4142
commons-codec:commons-codec:1.14=testRuntimeClasspath
4243
commons-codec:commons-codec:1.15=checkstyle
4344
commons-collections:commons-collections:3.2.2=checkstyle
44-
commons-io:commons-io:2.20.0=spotbugs
45+
commons-io:commons-io:2.21.0=spotbugs
4546
commons-logging:commons-logging:1.2=testRuntimeClasspath
4647
info.picocli:picocli:4.7.7=checkstyle
4748
io.github.cdimascio:dotenv-java:2.3.2=testRuntimeClasspath
@@ -52,7 +53,7 @@ io.opentracing:opentracing-util:0.33.0=testRuntimeClasspath
5253
jakarta.activation:jakarta.activation-api:2.1.4=testRuntimeClasspath
5354
jakarta.xml.bind:jakarta.xml.bind-api:4.0.4=testRuntimeClasspath
5455
jakarta.xml.soap:jakarta.xml.soap-api:3.0.2=testRuntimeClasspath
55-
jaxen:jaxen:2.0.0=spotbugs
56+
jaxen:jaxen:2.0.6=spotbugs
5657
net.bytebuddy:byte-buddy-agent:1.17.7=testCompileClasspath,testRuntimeClasspath
5758
net.bytebuddy:byte-buddy:1.17.7=testCompileClasspath
5859
net.bytebuddy:byte-buddy:1.18.3=testRuntimeClasspath
@@ -63,12 +64,10 @@ net.sourceforge.pmd:pmd-core:7.22.0=pmd
6364
net.sourceforge.pmd:pmd-java:7.22.0=pmd
6465
org.antlr:antlr4-runtime:4.13.2=checkstyle
6566
org.antlr:antlr4-runtime:4.9.3=pmd
66-
org.apache.bcel:bcel:6.11.0=spotbugs
67+
org.apache.bcel:bcel:6.12.0=spotbugs
6768
org.apache.commons:commons-lang3:3.18.0=checkstyle
68-
org.apache.commons:commons-lang3:3.19.0=spotbugs
69-
org.apache.commons:commons-lang3:3.20.0=compileClasspath,pmd,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
70-
org.apache.commons:commons-text:1.14.0=spotbugs
71-
org.apache.commons:commons-text:1.15.0=compileClasspath,runtimeClasspath,testCompileClasspath,testRuntimeClasspath
69+
org.apache.commons:commons-lang3:3.20.0=compileClasspath,pmd,runtimeClasspath,spotbugs,testCompileClasspath,testRuntimeClasspath
70+
org.apache.commons:commons-text:1.15.0=compileClasspath,runtimeClasspath,spotbugs,testCompileClasspath,testRuntimeClasspath
7271
org.apache.commons:commons-text:1.3=checkstyle
7372
org.apache.httpcomponents.client5:httpclient5:5.1.3=checkstyle
7473
org.apache.httpcomponents.core5:httpcore5-h2:5.1.3=checkstyle
@@ -77,8 +76,8 @@ org.apache.httpcomponents:httpclient:4.5.13=checkstyle
7776
org.apache.httpcomponents:httpclient:4.5.14=testRuntimeClasspath
7877
org.apache.httpcomponents:httpcore:4.4.14=checkstyle
7978
org.apache.httpcomponents:httpcore:4.4.16=testRuntimeClasspath
80-
org.apache.logging.log4j:log4j-api:2.25.3=spotbugs
81-
org.apache.logging.log4j:log4j-core:2.25.3=spotbugs
79+
org.apache.logging.log4j:log4j-api:2.26.0=spotbugs
80+
org.apache.logging.log4j:log4j-core:2.26.0=spotbugs
8281
org.apache.maven.doxia:doxia-core:1.12.0=checkstyle
8382
org.apache.maven.doxia:doxia-logging-api:1.12.0=checkstyle
8483
org.apache.maven.doxia:doxia-module-xdoc:1.12.0=checkstyle
@@ -109,26 +108,28 @@ org.jspecify:jspecify:1.0.0=checkstyle
109108
org.junit.jupiter:junit-jupiter-api:5.14.0=testCompileClasspath,testRuntimeClasspath
110109
org.junit.platform:junit-platform-commons:1.14.0=testCompileClasspath,testRuntimeClasspath
111110
org.junit.platform:junit-platform-engine:1.14.0=testCompileClasspath,testRuntimeClasspath
112-
org.junit:junit-bom:5.14.0=annotationProcessor,spotbugs,testAnnotationProcessor,testCompileClasspath,testRuntimeClasspath
111+
org.junit:junit-bom:5.14.0=annotationProcessor,testAnnotationProcessor,testCompileClasspath,testRuntimeClasspath
112+
org.junit:junit-bom:6.1.0=spotbugs
113113
org.mockito:mockito-core:5.23.0=testCompileClasspath,testRuntimeClasspath
114114
org.objenesis:objenesis:3.3=runtimeClasspath,testRuntimeClasspath
115115
org.opentest4j:opentest4j:1.3.0=testCompileClasspath,testRuntimeClasspath
116-
org.ow2.asm:asm-analysis:9.9=spotbugs
116+
org.ow2.asm:asm-analysis:9.10.1=spotbugs
117+
org.ow2.asm:asm-commons:9.10.1=spotbugs
117118
org.ow2.asm:asm-commons:9.8=jacocoAnt
118-
org.ow2.asm:asm-commons:9.9=spotbugs
119+
org.ow2.asm:asm-tree:9.10.1=spotbugs
119120
org.ow2.asm:asm-tree:9.8=jacocoAnt
120-
org.ow2.asm:asm-tree:9.9=spotbugs
121-
org.ow2.asm:asm-util:9.9=spotbugs
121+
org.ow2.asm:asm-util:9.10.1=spotbugs
122+
org.ow2.asm:asm:9.10.1=spotbugs
122123
org.ow2.asm:asm:9.8=jacocoAnt
123-
org.ow2.asm:asm:9.9=spotbugs
124124
org.ow2.asm:asm:9.9.1=pmd
125125
org.pcollections:pcollections:4.0.2=pmd
126126
org.projectlombok:lombok:1.18.42=annotationProcessor,compileClasspath,lombok,testAnnotationProcessor,testCompileClasspath
127127
org.reflections:reflections:0.10.2=checkstyle,testRuntimeClasspath
128128
org.slf4j:jul-to-slf4j:1.7.36=pmd
129129
org.slf4j:slf4j-api:1.7.30=compileClasspath,runtimeClasspath,testCompileClasspath
130130
org.slf4j:slf4j-api:1.7.32=testRuntimeClasspath
131-
org.slf4j:slf4j-api:2.0.17=spotbugs,spotbugsSlf4j
131+
org.slf4j:slf4j-api:2.0.17=spotbugsSlf4j
132+
org.slf4j:slf4j-api:2.0.18=spotbugs
132133
org.slf4j:slf4j-simple:1.7.30=testCompileClasspath,testRuntimeClasspath
133134
org.slf4j:slf4j-simple:2.0.17=spotbugsSlf4j
134135
org.spockframework:spock-bom:2.4-M6-groovy-3.0=testCompileClasspath,testRuntimeClasspath

0 commit comments

Comments
 (0)