GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Send a Träger's invites and DPA mails through its own mail server by Storypapst · Pull Request #1337 · OpenResilienceInitiative/ORISO-UserService

Conversation

@Storypapst

@Storypapst Storypapst commented Oct 1, 2026 •
edited by coderabbitai Bot
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Collaborator

Refs #1251

What this changes

A Träger that entered its own mail server in the Admin still had its invites, the contract signing mail and the "contract documents signed" notice sent from the platform address. With this change those three mails leave through the Träger's own mail server, with the Träger's own sender address. A Träger without its own server sees no change. A platform-admin invite (no Träger) and the invite for a Träger that is still being created stay on the platform server.

If a Träger chose its own server but the settings are incomplete, or the Träger settings cannot be read, the mail is not sent through the platform as a fallback. The send fails with a clear "not sent" error instead, so nobody gets a mail from the wrong server.

What has to happen first

This depends on TenantService allowing the three new mail purposes: OpenResilienceInitiative/ORISO-TenantService#298 (stacked on OpenResilienceInitiative/ORISO-TenantService#280, the 279/1251 contract purposes). Until #298 is deployed, an invite for a Träger with its own server is rejected by TenantService and fails as "not sent". Merge and deploy TenantService #298 before this PR.

Not in this PR: the "Träger via ORISO" display name and Reply-To for the platform relay (waits for the decision in OpenResilienceInitiative/ORISO-Frontend#1562), and magic-link / password-reset mails.

What is verified, and what is not

  • Verified by automated tests in UserService (details below), including a two-tenant test: the Träger with its own server reaches TenantService's relay with purpose ACCOUNT_INVITE, the other Träger reaches the platform SMTP server with the platform From address.
  • Not verified on a deployed Dev with a real Träger that has its own SMTP server. No mail was received in a test mailbox. The From header of an own-server mail is set inside TenantService and is not visible to UserService tests.

For developers — design and contract (skip if you only need the status):

InviteMailDispatchService
  send(..., tenantId, language, InviteMailOrigin origin)
  sendRendered(recipient, mail, InviteMailOrigin origin)
  InviteMailOrigin = (Long tenantId, TenantSystemEmailDelivery.Purpose purpose)
  -> TenantSystemEmailRouteService.resolveTransport(tenantId)
       null/<=0 tenant          -> PLATFORM, no tenant read
       smtpMode PLATFORM        -> PLATFORM (existing global SMTP path, unchanged)
       no settings / smtpMode null -> PLATFORM (legacy rows; TenantService never relays them) [bfff0723a]
       smtpMode OWN, complete   -> OWN, ignores featureSystemNotificationEmailsEnabled
       OWN incomplete / unknown -> SmtpSendException SMTP_DISABLED_OR_INCOMPLETE, CONFIRMED_NOT_SENT
       tenant read fails        -> SmtpSendException SMTP_SETTINGS_UNAVAILABLE, CONFIRMED_NOT_SENT
  OWN -> TenantSystemEmailClient.deliverStrict(tenantId, purpose, recipient, rendered, correlationId)
       200                      -> receipt
       204 / 422                -> SMTP_DISABLED_OR_INCOMPLETE, CONFIRMED_NOT_SENT
       other 4xx                -> SMTP_SETTINGS_UNAVAILABLE, CONFIRMED_NOT_SENT
       5xx (incl. 502) / timeout-> SMTP_TRANSPORT_FAILED, DELIVERY_UNCERTAIN

Call sites and purposes
  InviteDelivery                         ACCOUNT_INVITE      tenant = invite.tenantId, null while the
                                                             Träger id is only reserved (reservation token set)
  ExistingAccountSetupIssuer             ACCOUNT_INVITE      tenant = identity.tenantId
  DefaultDpaSigningEmailDispatchService  DPA_SIGNING_REQUEST tenant = tenantId
  DpaSignedNoticeService                 DPA_SIGNED_NOTICE   tenant = tenantId

Side fix: TenantSystemEmailClient.deliver() caught only HttpClientErrorException.UnprocessableEntity.
Spring 7 resolves a real 422 to HttpStatus.UNPROCESSABLE_CONTENT and throws UnprocessableContent,
so a real 422 escaped as a raw HttpClientErrorException on the notification path. Both methods now
check the numeric status 422. New test uses HttpStatus.valueOf(422).

The SMTP password never leaves TenantService; UserService only reads the redacted tenant settings.
No schema change.

For developers — test runs (JDK 21, Maven, local, narrow selection):

Unit tests, 331 green, 0 failed:
  InviteMailTenantRoutingTest (new, 12: two-tenant routing, tenantless, notification switch off,
    DPA purposes, incomplete OWN, unreadable tenant, 204/422/400/502/500, timeout),
  InviteMailDispatchServiceTest, TenantSystemEmailRouteServiceTest (+2), TenantSystemEmailClientTest (+1),
  TenantSystemEmailDeliveryTest, AccountInviteServiceTest (+2), ExistingAccountSetupIssuerTest,
  DefaultDpaSigningEmailDispatchServiceTest, DpaSignedNoticeServiceTest, DpaSignedNoticeFooterTest,
  DpaSigningMailDesignSystemTest, InviteEmailPreviewServiceTest, JakartaInviteMailTransportTest,
  SupervisorAddedEmailNotificationServiceTest, NotificationMailSenderTest, CaseHandoverMailSenderTest,
  FeedbackMessageEmailServiceTest, RequestedContactSheetServiceTest
Spring ITs (H2), 160 green, 0 failed:
  UserServiceApplicationIT (context wiring), AccountInviteExistingTenantIT, ExistingAccountSetupExpiryIT,
  CreateAdminServiceIT, QueuedInviteReleaseOnOnboardingIT, UserAdminControllerE2EIT,
  UserAdminControllerMultiTenancyTrueE2EIT, AccountInviteDirectSendAtomicIT,
  AccountInviteTopicPermissionIT, AccountInviteUnitQueueIT, AccountInviteRevokeAcceptRaceIT
Mutation check: forcing PLATFORM in the dispatcher fails 9 routing tests; dropping the
  reservation-token rule fails the new AccountInviteServiceTest case.
spotless:check clean.
NOT run: full test suite, AccountInviteRevokeAcceptRaceMariaDbIT (needs Docker; its stubs were
  edited via the shared RevokeAcceptRaceContract), the other invite ITs that mock the dispatcher
  without stubbing it, CI, any deployed environment.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • New Features
    • Account invitation and data-protection agreement emails can now be sent through a tenant’s configured mail server; other eligible messages continue through the platform mail service.
    • Email delivery now identifies the tenant and message type, helping route messages appropriately.
  • Bug Fixes
    • Invalid tenant mail settings and relay responses are handled explicitly, with delivery outcomes distinguished when a message may not have been sent or its status is uncertain.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@Storypapst @claude
feat(mail): send Träger invites and DPA mails through its own server (#…
a1f4eb5
…1251)

Invites, the DPA signing mail and the signed notice always left through the
platform SMTP server, even for a Träger with its own mail server (smtpMode OWN).
InviteMailDispatchService now takes an InviteMailOrigin (tenant + relay purpose),
resolves the tenant's transport from the redacted tenant read and, for OWN,
delivers through TenantService's relay (password stays there). Tenantless and
reserved-only Träger mail stays on the platform server. No silent fallback:
incomplete OWN settings or an unreadable tenant fail as CONFIRMED_NOT_SENT.

- TenantSystemEmailRouteService.resolveTransport ignores the notification switch
- TenantSystemEmailClient.deliverStrict maps relay answers onto SmtpSendException:
  204/422/other 4xx -> CONFIRMED_NOT_SENT, 5xx/timeout -> DELIVERY_UNCERTAIN
- New relay purposes ACCOUNT_INVITE, DPA_SIGNING_REQUEST, DPA_SIGNED_NOTICE
  (TenantService must allow them first)
- deliver() also treats a real 422 (Spring 7: UnprocessableContent) as invalid
  OWN configuration; it only caught the deprecated UnprocessableEntity before

Refs #1251

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@coderabbitai

coderabbitai Bot commented Oct 1, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

Review in Change Stack →

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: Repository: OpenResilienceInitiative/ORISO-UserService/.coderabbit.yaml

Review profile: ASSERTIVE

Plan: Team

Run ID: 6ebba05a-f9c1-44a5-944c-9d238018a6ef

📥 Commits

Reviewing files that changed from the base of the PR and between 6572c06 and 59ed82e.

📒 Files selected for processing (30)
  • src/main/java/de/caritas/cob/userservice/api/service/accountinvite/ExistingAccountSetupIssuer.java
  • src/main/java/de/caritas/cob/userservice/api/service/accountinvite/InviteDelivery.java
  • src/main/java/de/caritas/cob/userservice/api/service/accountinvite/mail/InviteMailDispatchService.java
  • src/main/java/de/caritas/cob/userservice/api/service/accountinvite/mail/InviteMailOrigin.java
  • src/main/java/de/caritas/cob/userservice/api/service/notification/DefaultDpaSigningEmailDispatchService.java
  • src/main/java/de/caritas/cob/userservice/api/service/notification/DpaSignedNoticeService.java
  • src/main/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailClient.java
  • src/main/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailDelivery.java
  • src/main/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailRouteService.java
  • src/test/java/de/caritas/cob/userservice/api/adapters/web/controller/QueuedInviteReleaseOnOnboardingIT.java
  • src/test/java/de/caritas/cob/userservice/api/adapters/web/controller/UserAdminControllerE2EIT.java
  • src/test/java/de/caritas/cob/userservice/api/adapters/web/controller/UserAdminControllerMultiTenancyTrueE2EIT.java
  • src/test/java/de/caritas/cob/userservice/api/admin/service/admin/create/CreateAdminServiceIT.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/AccountInviteDirectSendAtomicIT.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/AccountInviteServiceTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/AccountInviteTopicPermissionIT.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/AccountInviteUnitQueueIT.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/DpaSigningMailDesignSystemTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/ExistingAccountSetupExpiryIT.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/ExistingAccountSetupIssuerTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/InviteEmailPreviewServiceTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/RevokeAcceptRaceContract.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/mail/InviteMailDispatchServiceTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/mail/InviteMailTenantRoutingTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/mail/TenantMailRoutingFixture.java
  • src/test/java/de/caritas/cob/userservice/api/service/notification/DefaultDpaSigningEmailDispatchServiceTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/notification/DpaSignedNoticeFooterTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/notification/DpaSignedNoticeServiceTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailClientTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailRouteServiceTest.java

Included review availability: This review used your included allowance. 0 included reviews remain after this review. Your included PR review attempts over the past 7 days set your current allowance at 6 reviews per hour.

📜 Recent review details
⏰ Context from checks skipped due to timeout. (7)
  • GitHub Check: mariadb-contract / MariaDB schema, statistics, scheduler lease and replica contracts
  • GitHub Check: test, build and Docker validation
  • GitHub Check: integration tests with the tenant filter on
  • GitHub Check: required integration tests
  • GitHub Check: mariadb-contract / MariaDB schema, statistics, scheduler lease and replica contracts
  • GitHub Check: required integration tests
  • GitHub Check: test and build UserService
🧰 Additional context used
📓 Path-based instructions (2)
Check behavior against the surrounding ORISO flow, not only types.

⚙️ CodeRabbit configuration file

Files:

  • src/main/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailDelivery.java
  • src/main/java/de/caritas/cob/userservice/api/service/notification/DpaSignedNoticeService.java
  • src/main/java/de/caritas/cob/userservice/api/service/accountinvite/mail/InviteMailOrigin.java
  • src/main/java/de/caritas/cob/userservice/api/service/accountinvite/ExistingAccountSetupIssuer.java
  • src/main/java/de/caritas/cob/userservice/api/service/notification/DefaultDpaSigningEmailDispatchService.java
  • src/main/java/de/caritas/cob/userservice/api/service/accountinvite/InviteDelivery.java
  • src/main/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailRouteService.java
  • src/main/java/de/caritas/cob/userservice/api/service/accountinvite/mail/InviteMailDispatchService.java
  • src/main/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailClient.java
Tests must be able to fail.

⚙️ CodeRabbit configuration file

Files:

  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/AccountInviteTopicPermissionIT.java
  • src/test/java/de/caritas/cob/userservice/api/service/notification/DpaSignedNoticeFooterTest.java
  • src/test/java/de/caritas/cob/userservice/api/adapters/web/controller/QueuedInviteReleaseOnOnboardingIT.java
  • src/test/java/de/caritas/cob/userservice/api/adapters/web/controller/UserAdminControllerE2EIT.java
  • src/test/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailClientTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/DpaSigningMailDesignSystemTest.java
  • src/test/java/de/caritas/cob/userservice/api/admin/service/admin/create/CreateAdminServiceIT.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/ExistingAccountSetupIssuerTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/notification/DefaultDpaSigningEmailDispatchServiceTest.java
  • src/test/java/de/caritas/cob/userservice/api/adapters/web/controller/UserAdminControllerMultiTenancyTrueE2EIT.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/AccountInviteUnitQueueIT.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/RevokeAcceptRaceContract.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/ExistingAccountSetupExpiryIT.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/InviteEmailPreviewServiceTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/mail/InviteMailDispatchServiceTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailRouteServiceTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/mail/InviteMailTenantRoutingTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/mail/TenantMailRoutingFixture.java
  • src/test/java/de/caritas/cob/userservice/api/service/notification/DpaSignedNoticeServiceTest.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/AccountInviteDirectSendAtomicIT.java
  • src/test/java/de/caritas/cob/userservice/api/service/accountinvite/AccountInviteServiceTest.java
🪛 Betterleaks (1.8.1)
src/test/java/de/caritas/cob/userservice/api/service/accountinvite/mail/InviteMailTenantRoutingTest.java

[high] 104-104: Detected a potential hardcoded password literal, which may expose account credentials.

(generic-password)

🪛 PMD (7.27.0)
src/main/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailClient.java

[Medium] 90-91: PreserveStackTrace (Best Practices): Thrown exception does not preserve the stack trace of exception 'ex' on all code paths

(PreserveStackTrace (Best Practices))

🔇 Additional comments (30)
src/main/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailRouteService.java (1)

30-64: LGTM!

src/main/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailDelivery.java (1)

31-34: LGTM!

src/main/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailClient.java (1)

95-176: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailClientTest.java (1)

148-166: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailRouteServiceTest.java (1)

116-182: LGTM!

src/main/java/de/caritas/cob/userservice/api/service/accountinvite/mail/InviteMailOrigin.java (1)

1-26: LGTM!

src/main/java/de/caritas/cob/userservice/api/service/accountinvite/mail/InviteMailDispatchService.java (1)

82-164: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/accountinvite/mail/InviteMailDispatchServiceTest.java (1)

25-38: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/accountinvite/mail/InviteMailTenantRoutingTest.java (1)

1-315: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/accountinvite/mail/TenantMailRoutingFixture.java (1)

1-26: LGTM!

src/main/java/de/caritas/cob/userservice/api/service/accountinvite/ExistingAccountSetupIssuer.java (1)

139-143: LGTM!

src/main/java/de/caritas/cob/userservice/api/service/accountinvite/InviteDelivery.java (1)

142-148: LGTM!

src/test/java/de/caritas/cob/userservice/api/adapters/web/controller/QueuedInviteReleaseOnOnboardingIT.java (1)

137-137: LGTM!

src/test/java/de/caritas/cob/userservice/api/adapters/web/controller/UserAdminControllerE2EIT.java (1)

261-261: LGTM!

src/test/java/de/caritas/cob/userservice/api/adapters/web/controller/UserAdminControllerMultiTenancyTrueE2EIT.java (1)

173-173: LGTM!

src/test/java/de/caritas/cob/userservice/api/admin/service/admin/create/CreateAdminServiceIT.java (1)

143-143: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/accountinvite/AccountInviteDirectSendAtomicIT.java (1)

154-154: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/accountinvite/AccountInviteServiceTest.java (1)

241-291: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/accountinvite/AccountInviteTopicPermissionIT.java (1)

305-305: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/accountinvite/AccountInviteUnitQueueIT.java (1)

147-147: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/accountinvite/DpaSigningMailDesignSystemTest.java (1)

100-104: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/accountinvite/ExistingAccountSetupExpiryIT.java (1)

176-176: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/accountinvite/ExistingAccountSetupIssuerTest.java (1)

219-222: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/accountinvite/InviteEmailPreviewServiceTest.java (1)

66-70: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/accountinvite/RevokeAcceptRaceContract.java (1)

424-424: LGTM!

src/main/java/de/caritas/cob/userservice/api/service/notification/DefaultDpaSigningEmailDispatchService.java (1)

42-44: LGTM!

src/main/java/de/caritas/cob/userservice/api/service/notification/DpaSignedNoticeService.java (1)

347-354: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/notification/DefaultDpaSigningEmailDispatchServiceTest.java (1)

56-60: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/notification/DpaSignedNoticeFooterTest.java (1)

164-168: LGTM!

src/test/java/de/caritas/cob/userservice/api/service/notification/DpaSignedNoticeServiceTest.java (1)

258-267: LGTM!


📝 Walkthrough

Walkthrough

Invite and DPA email dispatch now uses origin metadata to select tenant-owned SMTP relay delivery or platform SMTP. Transport routing and relay error outcomes are handled by the mail dispatch and tenant email client services.

Changes

Tenant-aware email delivery

Layer / File(s) Summary
Resolve transport and relay outcomes
src/main/java/de/caritas/cob/userservice/api/service/notification/TenantSystemEmailRouteService.java, TenantSystemEmailClient.java, TenantSystemEmailDelivery.java, src/test/java/de/caritas/cob/userservice/api/service/notification/*Test.java
Transport resolution selects a route from tenant settings. The relay client handles shared request construction and classifies response and runtime failure outcomes. The purpose enum adds account-invite and DPA mail values.
Dispatch mail by origin
src/main/java/de/caritas/cob/userservice/api/service/accountinvite/mail/InviteMailDispatchService.java, InviteMailOrigin.java, src/test/java/de/caritas/cob/userservice/api/service/accountinvite/mail/*
The dispatcher takes an origin and routes messages through the tenant relay for OWN mode or platform SMTP otherwise. Tests cover transport selection, rendered content, and delivery outcomes.
Attach origins to account-invite mail
src/main/java/de/caritas/cob/userservice/api/service/accountinvite/ExistingAccountSetupIssuer.java, InviteDelivery.java, src/test/java/de/caritas/cob/userservice/api/service/accountinvite/*, src/test/java/de/caritas/cob/userservice/api/adapters/web/controller/*, src/test/java/de/caritas/cob/userservice/api/admin/service/admin/create/CreateAdminServiceIT.java
Invite sends provide ACCOUNT_INVITE origin metadata. A reservation token selects a platform origin; otherwise, the invite tenant is used. Tests assert origin selection and update dispatcher mocks to the expanded signatures.
Attach origins to DPA mail
src/main/java/de/caritas/cob/userservice/api/service/notification/DefaultDpaSigningEmailDispatchService.java, DpaSignedNoticeService.java, src/test/java/de/caritas/cob/userservice/api/service/notification/*
DPA signing and signed-notice sends provide tenant and purpose metadata. Tests check the updated dispatch calls.

Priority: ➖ Normal

Estimated code review effort: 3 (Moderate) | ~25 minutes

Change: Feature

Sequence Diagram(s)

sequenceDiagram
  participant InviteMailDispatchService
  participant TenantSystemEmailRouteService
  participant TenantSystemEmailClient
  participant PlatformSmtpSettingsProvider
  participant InviteMailTransport
  InviteMailDispatchService->>TenantSystemEmailRouteService: resolveTransport(tenantId)
  alt OWN route
    InviteMailDispatchService->>TenantSystemEmailClient: deliverStrict(tenantId, purpose, recipient, email, correlationId)
  else PLATFORM route
    InviteMailDispatchService->>PlatformSmtpSettingsProvider: resolve platform SMTP settings
    InviteMailDispatchService->>InviteMailTransport: transmit message
  end
Loading

Merge Risk: ⚪ Minimal · up to 59ed8

No actionable merge-blocking issue remains from the reviewed changes. Deploy the required TenantService relay support before enabling own-server delivery.

🚥 Pre-merge checks | ✅ 5 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 12.59% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 135 functions across 30 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly describes the main change: routing Träger invites and DPA mails through the tenant’s own mail server. It is concise and identifies the affected ORISO mail area.
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.
Validation Evidence ✅ Passed PASS — The PR changes product behavior and adds relevant automated coverage. The diff adds InviteMailTenantRoutingTest with tests for own-server routing, platform fallback, DPA purposes, incomplete …
  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Autopilot is currently an internal CodeRabbit preview.


Comment @coderabbitai help to get the list of available commands.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@Storypapst Storypapst added this to ORISO Roadmap Oct 1, 2026
@Storypapst Storypapst moved this to In progress in ORISO Roadmap Oct 1, 2026
@Storypapst
Storypapst marked this pull request as ready for review October 1, 2026 22:42
@Storypapst
Storypapst requested review from Shirloin and shazia-k October 1, 2026 22:42
@Storypapst Storypapst self-assigned this Oct 1, 2026
@Storypapst @claude
fix(mail): keep unclassified Träger on the platform server (#1251)
bfff072
Legacy tenant rows keep smtpMode null until they are classified, and
TenantService never relays such a tenant. Treating a missing mode as an
error made every invite and DPA mail of those Träger fail as not sent.
A missing settings object or mode now selects the platform transport;
an unknown explicit mode and incomplete OWN settings still fail.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@Storypapst Storypapst mentioned this pull request Oct 1, 2026
DPA signed notice: make the deliberate re-send after an uncertain delivery documented, tested and observable #1341
Closed
11 tasks
@shazia-k
Merge branch 'dev' into feat/1251-own-relay-invite-mails
59ed82e
coderabbitai[bot]
coderabbitai Bot approved these changes Oct 2, 2026
View reviewed changes
@shazia-k
shazia-k merged commit 8430db8 into dev Oct 2, 2026
13 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@shazia-k
shazia-k deleted the feat/1251-own-relay-invite-mails branch October 2, 2026 06:51
shazia-k
shazia-k approved these changes Oct 2, 2026
View reviewed changes
shazia-k pushed a commit that referenced this pull request Oct 2, 2026
Shazia Kausar
Merge dev into feat/876-service-notice-sender
e9ec44f
Keep both relay purposes: dev's ACCOUNT_INVITE/DPA_* (#1337) and SERVICE_NOTICE.
This was referenced Oct 2, 2026
DPA signed notice: document, test and measure the deliberate re-send after an unclear delivery #1346
Merged
Mails of a Träger with its own mail server still leave from the platform address #1251
Closed
@Hassan9215 Hassan9215 mentioned this pull request Oct 8, 2026
Release UserService v2.0.11 #1381
Merged
@Storypapst Storypapst moved this from In review to QA internal in ORISO Roadmap Oct 13, 2026
@coderabbitai coderabbitai Bot mentioned this pull request Oct 21, 2026
fix: reliable notification email delivery and internal-chat mail #1376
Merged
12 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@coderabbitai coderabbitai[bot] coderabbitai[bot] approved these changes
@shazia-k shazia-k shazia-k approved these changes
@Shirloin Shirloin Awaiting requested review from Shirloin

Uh oh!

There was an error while loading. Please reload this page.

Assignees

@Storypapst Storypapst

Labels

None yet

Projects

ORISO Roadmap
Status: QA internal

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.

2 participants

@Storypapst @shazia-k
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.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.