chennaji9 opened a new pull request, #6663:
URL: https://github.com/apache/rocketmq-dashboard/pull/6663

   ### Which Issue(s) This PR Fixes
   
   None — small self-contained fix found by inspection (no issue tracked).
   
   ### Brief Description
   
   `NotificationOutboxService.parseRecipients` split the configured recipient 
list on a plain `[,;]` regex before handing each fragment to `InternetAddress`. 
A list like
   
   ```
   "Doe, John" <[email protected]>, [email protected]
   ```
   
   is valid RFC 822 input (`InternetAddress` is already used with display-name 
support), but the split broke it at the comma inside the quoted display name, 
validation failed on the unbalanced fragment, and the notification went to 
retry instead of sending.
   
   - `parseRecipients` now splits on `,` and `;` **only outside a quoted 
display name** (with backslash-escape handling inside quotes), then validates 
each whole address as before. Legacy semicolon-separated lists keep working, 
including a `;` inside a quoted name.
   
   ### How Did You Test This Change?
   
   `cd server && mvn -B -ntp test -Dtest='NotificationOutboxServiceTest' 
-DfailIfNoTests=false` → **Tests run: 36, Failures: 0, Errors: 0** (34 
pre-existing + 2 new).
   
   New tests (both fail on the unfixed code):
   - `dispatchesEmailWithQuotedDisplayNameRecipientsTest` — `"Doe, John" 
<[email protected]>, [email protected]` delivers to `[[email protected], 
[email protected]]`;
   - `dispatchesEmailToSemicolonSeparatedRecipientsTest` — `[email protected]; 
"Night; Shift" <[email protected]>` delivers to `[[email protected], 
[email protected]]`.
   
   Red-green: both tests were run against the unfixed tree and fail there (the 
split fragments never validate), while the pre-existing comma-separated 
delivery test passes unchanged.
   
   Not run: the full `mvn test` suite (integration tests need MySQL 8); the 
change is confined to one private parser covered above.
   
   ### Checklist
   
   - [x] One coherent change; unrelated modifications are not bundled in
   - [x] Commit subject follows Conventional Commits (`fix:`)
   - [x] Tests added or updated for non-trivial changes (2 new red-green tests)
   - [x] New UI text has both Chinese and English entries under `web/src/i18n/` 
(n/a — no UI change)
   - [x] Architecture constraints stay green (same class, same package, no new 
dependency)
   - [x] New source files carry the ASF license header (n/a — no new source 
file)
   - [x] Documentation touched where behaviour changed (n/a — the settings 
field already accepts RFC 822 addresses; only parsing was broken)
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to