You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ofbiz.apache.org by "mridulpathak (via GitHub)" <gi...@apache.org> on 2026/10/30 06:16:01 UTC

[PR] Improved: Remove this-escape warnings in ConfigXMLReader, FlexibleServletAccessor and RecordIterator (OFBIZ-13749) [ofbiz-framework]

mridulpathak opened a new pull request, #2498:
URL: https://github.com/apache/ofbiz-framework/pull/2498

   The constructors of ConfigXMLReader.ControllerConfig, FlexibleServletAccessor and RecordIterator called methods that a subclass could override, which javac reports as this-escape because the subclass could see the object before its constructor finished. Nothing in the framework, applications, themes or plugins subclasses these classes or calls the methods involved, so the constructors now set up the objects themselves. ControllerConfig.loadIncludes is private. FlexibleServletAccessor assigns its fields directly in the constructor and makes them final; its protected init method is removed and the two-argument constructor delegates to the one-argument one. RecordIterator assigns its reader, model and location in the constructors and makes them final; a private static openReader method replaces the protected setupStream method, and reaching the end of the file closes the reader through a private method that the public close method also uses. This removes the this-escape warnings for 
 these three classes under JDK 25.
   


-- 
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: notifications-unsubscribe@ofbiz.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Improved: Remove this-escape warnings in ConfigXMLReader, FlexibleServletAccessor and RecordIterator (OFBIZ-13749) [ofbiz-framework]

Posted by "mridulpathak (via GitHub)" <gi...@apache.org>.
mridulpathak merged PR #2498:
URL: https://github.com/apache/ofbiz-framework/pull/2498


-- 
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: notifications-unsubscribe@ofbiz.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org