GeezerVison is showing github.com — fix(dpa-mail): show signing-link expiry in German local time by Storypapst · Pull Request #159 · OpenResilienceInitiative/ORISO-ConsultingTypeService
Conversation
What was wrong
The mail that sends a Träger the contract signing link says until when the link works. That time was two hours off. On dev, a link that really expires at 00:43 German time on 7 October said "gültig bis 06.10.2026, 22:43 Uhr".
The reason: the expiry reaches this service as a UTC time without a zone marker, and the mail printed it as if it were already German time.
What changed
DpaSigningEmailService converts the expiry from UTC to Europe/Berlin before formatting it. The wording of the mail is unchanged, and no zone label was added because the copy never had one.
- Summer time (+2h, including the jump to the next day) and winter time (+1h) are both covered by tests.
Evidence
Measured on dev on 2026-09-23: the signing mail said "gültig bis 06.10.2026, 22:43 Uhr", but German local time was 00:43 on the next day.
RED before the fix (DpaSigningEmailServiceTest):
- summer: expected
gültig bis 07.10.2026, 00:43 Uhr., got gültig bis 06.10.2026, 22:43 Uhr.
- winter: expected
gültig bis 15.01.2027, 23:43 Uhr., got gültig bis 15.01.2027, 22:43 Uhr.
GREEN after the fix (JDK 21, ./mvnw -B -o):
DpaSigningEmailServiceTest 6/6, DpaSigningEmailServiceOriginBindingTest 3/3, DpaSigningEmailControllerTest 5/5, DpaSigningEmailRoutingIT 3/3, NoHardcodedUrlFallbacksTest 1/1 (18 in total)
spotless:check clean
Related
- The UserService PR on the same branch name fixes the matching "AVV unterzeichnet" notice time and the generic name "Ihrer Organisation" → "Ihre Organisation". That generic name is what put "Vertragsunterlagen für Ihrer Organisation" into this mail's subject and body. This service only passes the name through, so that fix belongs in UserService.
🤖 Generated with Claude Code
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
The expiry arrives as zoneless UTC but was printed as-is, so the German
signing mail on dev said "gültig bis 06.10.2026, 22:43 Uhr" for a link
that really expires at 00:43 on 07.10. Convert UTC to Europe/Berlin
before formatting; covered for a summer (+2h, date rollover) and a
winter (+1h) timestamp.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
coderabbitai
Bot
commented
Sep 22, 2026
•
edited
Loading
Uh oh!
There was an error while loading. Please reload this page.
|

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.
No actionable comments were generated in the recent review. 🎉
ℹ️ Recent review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Team
Run ID: eb4ec37a-baa0-4ad3-881f-c36487065767
📥 Commits
Reviewing files that changed from the base of the PR and between 8a61b1a and 47deaa1.
📒 Files selected for processing (2)
src/main/java/de/caritas/cob/consultingtypeservice/api/service/DpaSigningEmailService.java
src/test/java/de/caritas/cob/consultingtypeservice/api/service/DpaSigningEmailServiceTest.java
Included review availability: 0 reviews are currently available. Your included PR review attempts over the past 7 days set your current allowance at 2 reviews per hour.
📜 Recent review details
🧰 Additional context used
🧠 Learnings (1)
📓 Common learnings
Learnt from: Storypapst
URL: https://github.com/OpenResilienceInitiative/ORISO-ConsultingTypeService/pull/159
Timestamp: 2026-09-23T01:56:13.281Z
Learning: In OpenResilienceInitiative/ORISO-ConsultingTypeService, `DpaSigningEmailController` parses the DPA signing-mail `expiresAt` request value as a zoneless `LocalDateTime`. The upstream UserService contract supplies that value in UTC. `DpaSigningEmailService` must therefore attach `ZoneOffset.UTC` before converting it to `Europe/Berlin` for the German signing mail.
🔇 Additional comments (2)
src/main/java/de/caritas/cob/consultingtypeservice/api/service/DpaSigningEmailService.java (1)
9-10: LGTM!
Also applies to: 25-27, 130-132
src/test/java/de/caritas/cob/consultingtypeservice/api/service/DpaSigningEmailServiceTest.java (1)
109-135: LGTM!
📝 Summary
Summary by CodeRabbit
-
Bug Fixes
- Expiry times in DPA signing emails are now displayed in German local time, correctly accounting for summer and winter time.
- Email expiry timestamps no longer show the original UTC hour when a local-time conversion is required.
-
Tests
- Added coverage for summer- and winter-time expiry display scenarios.
Walkthrough
The DPA signing email service now interprets expiry timestamps as zoneless UTC, converts them to Europe/Berlin time, and formats the local time. Tests cover summer- and winter-time conversions.
Changes
DPA expiry time-zone handling
| Layer / File(s) |
Summary |
UTC to Berlin expiry conversion src/main/java/de/caritas/cob/consultingtypeservice/api/service/DpaSigningEmailService.java |
The service treats expiresAt as UTC, converts it to Europe/Berlin, then formats and escapes the result. |
Seasonal conversion tests src/test/java/de/caritas/cob/consultingtypeservice/api/service/DpaSigningEmailServiceTest.java |
Tests verify the displayed date and time for summer- and winter-time UTC timestamps. A shared helper creates expiry-test commands. |
Priority: ⬇️ Low
Estimated code review effort: 2 (Simple) | ~10 minutes
Change: Bug fix
Merge Risk: ⚪ Minimal · up to 47dea
The signing email now displays expiry times in German local time across daylight-saving transitions. No actionable merge risk remains.
🚥 Pre-merge checks | ✅ 4 | ❌ 1
❌ Failed checks (1 warning)
| Check name |
Status |
Explanation |
Resolution |
| Docstring Coverage |
⚠️ Warning |
Docstring coverage is 16.67% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 6 functions across 2 files. |
Write docstrings for the functions missing them to satisfy the coverage threshold. |
✅ Passed checks (4 passed)
| Check name |
Status |
Explanation |
| Title check |
✅ Passed |
The title clearly and concisely describes the main change: displaying signing-link expiry in German local time. |
| Description check |
✅ Passed |
The description directly explains the UTC interpretation issue, the Europe/Berlin conversion, test coverage, and validation results. |
| Linked Issues check |
✅ Passed |
Check skipped because no linked issues were found for this pull request. |
| Out of Scope Changes check |
✅ Passed |
Check skipped because no linked issues were found for this pull request. |
- Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
- Commit to this branch
- Create a new PR
✨ Simplify code
- Commit to this branch
- Create a new PR
Comment @coderabbitai help to get the list of available commands.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
|
Autofix pass by the coding agent (Claude Code), 2026-09-23, head 47deaa1.
Review findings: none. CodeRabbit skipped this PR (base is not the default branch), and no human review has been posted. I checked the change myself:
- The expiry is the only date this mail prints (
EXPIRY_FORMAT is used once). The conversion atOffset(UTC).atZoneSameInstant(Europe/Berlin) is correct for summer and winter time. The two new tests pin both, including the jump to the next day.
- UserService passes
expiresAt through unchanged as a zoneless LocalDateTime (DefaultDpaSigningEmailDispatchService, expiresAt.toString()), so no zone information reaches this service. The dev measurement in the description (00:43 German time mailed as 22:43) shows the value is UTC.
Tests (JDK 21, mvn -B spotless:check verify): unit 142/142, integration 119/119, spotless clean, BUILD SUCCESS. The branch is level with origin/dev (0 commits behind), no conflicts.
Heads-up: OpenResilienceInitiative/ORISO-UserService#1238 moves the contract signing mail into UserService. Once it is merged, ConsultingTypeService is no longer called for this mail, so this fix becomes dead code. It is still correct and harmless to merge first. If #1238 lands first, this PR can be closed instead.
@coderabbitai review
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
coderabbitai
Bot
commented
Sep 23, 2026
•
edited
Loading
Uh oh!
There was an error while loading. Please reload this page.
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -euo pipefail
printf '%s\n' '--- PR metadata ---'
gh pr view 159 --repo OpenResilienceInitiative/ORISO-ConsultingTypeService \
--json number,title,baseRefName,headRefName,headRefOid,mergeable,state \
--jq '{number,title,baseRefName,headRefName,headRefOid,mergeable,state}'
printf '%s\n' '--- Changed files ---'
gh pr diff 159 --repo OpenResilienceInitiative/ORISO-ConsultingTypeService --name-only
printf '%s\n' '--- Diff ---'
gh pr diff 159 --repo OpenResilienceInitiative/ORISO-ConsultingTypeService --patch
printf '%s\n' '--- Candidate source and test files ---'
fd -t f 'DpaSigningEmailService|DpaSigningEmailServiceTest' .
printf '%s\n' '--- Source outline ---'
source_file=$(fd -t f -a '^DpaSigningEmailService\.java$' . | head -n1 || true)
if [ -n "$source_file" ]; then
ast-grep outline "$source_file" --items all
fi
printf '%s\n' '--- Test outline ---'
test_file=$(fd -t f -a '^DpaSigningEmailServiceTest\.java$' . | head -n1 || true)
if [ -n "$test_file" ]; then
ast-grep outline "$test_file" --items all
fi
Length of output: 10411
🏁 Script executed:
#!/bin/bash
set -euo pipefail
source_file="src/main/java/de/caritas/cob/consultingtypeservice/api/service/DpaSigningEmailService.java"
test_file="src/test/java/de/caritas/cob/consultingtypeservice/api/service/DpaSigningEmailServiceTest.java"
printf '%s\n' '--- Service: complete relevant implementation ---'
nl -ba "$source_file" | sed -n '1,220p'
printf '%s\n' '--- Unit test: complete fixture and relevant tests ---'
nl -ba "$test_file" | sed -n '1,230p'
printf '%s\n' '--- Command construction and expiry handling in production code ---'
rg -n -C 4 --glob '*.java' \
'new\s+DpaSigningEmailService\.DpaSigningEmailCommand\s*\(|new\s+DpaSigningEmailCommand\s*\(|\bexpiresAt\s*\(' \
src/main src/test
printf '%s\n' '--- DPA email controller/service paths ---'
rg -n -C 4 --glob '*.java' \
'\b(DpaSigningEmailService|DpaSigningEmailCommand|preview|send)\s*\(' \
src/main/java src/test/java
Length of output: 76906
@Storypapst, review complete. I found no issues.
DpaSigningEmailService now interprets the zoneless expiresAt value as UTC and converts the same instant to Europe/Berlin before it formats the mail text. The implementation handles daylight-saving rules through ZoneId.
The new tests cover:
- Summer time with UTC+02:00 and date rollover.
- Winter time with UTC+01:00.
I inspected the controller flow. It parses expiresAt as LocalDateTime, so the documented upstream UTC contract is required and matches this change.
I did not execute the test suite in this inspection environment.
✏️ Learnings added
Learnt from: Storypapst
URL: https://github.com/OpenResilienceInitiative/ORISO-ConsultingTypeService/pull/159
Timestamp: 2026-09-23T01:56:13.198Z
Learning: In OpenResilienceInitiative/ORISO-ConsultingTypeService, `DpaSigningEmailController` parses the DPA signing-mail `expiresAt` request value as a zoneless `LocalDateTime`. The upstream UserService contract supplies that value in UTC. `DpaSigningEmailService` must therefore attach `ZoneOffset.UTC` before converting it to `Europe/Berlin` for the German signing mail.
Note: Learnings are effective only in the context of similar code segments. To apply general coding guidelines, please configure review instructions. You can manage existing learnings in the app.
✅ Action performed
Review finished.
Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
This was referenced Sep 23, 2026
Reviewers
shazia-k
Awaiting requested review from shazia-k
Uh oh!
There was an error while loading. Please reload this page.
Assignees
No one assigned
Milestone
No milestone
Development
Successfully merging this pull request may close these issues.
Uh oh!
There was an error while loading. Please reload this page.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
|