mayurbm commented on PR #25907:
URL: https://github.com/apache/camel/pull/25907#issuecomment-5473506791

   @davsclaus @gnodet Thank you both — the feedback is correct on all counts.
   
   **Changes made:**
   
   1. **Reframed as defensive hardening** — the JIRA issue type has been 
updated from Bug to Improvement. No claim of a real concurrent race.
   
   2. **Local variable capture** (per gnodet's suggestion): captured `folder` 
into `final Folder currentFolder = folder;` before the try block, and used 
`currentFolder` consistently throughout — `getMessageCount()`, 
`processFolder()`, `getFullName()`, `isOpen()`, `close()`, and the catch log. 
This is the more principled approach that addresses line 185 as well.
   
   3. **Fixed wrong JIRA reference in test** — `CAMEL-24565` → `CAMEL-24567` in 
both the Javadoc and inline comment.
   
   4. **Reworded test Javadoc** — accurately describes what it tests (null-safe 
handling in catch block) without claiming a real concurrent race.
   
   Local `camel-mail` full test suite passes with JDK 21.
   
   _Claude Code on behalf of mayurbm_


-- 
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