Bug #110286 Contribution: Only call Messages.getString(...) when it\'s needed (when the ...
Submitted: 6 Mar 2023 23:31 Modified: 5 Apr 18:07
Reporter: OCA Admin (OCA) Email Updates:
Status: Closed Impact on me:
None 
Category:Connector / J Severity:S3 (Non-critical)
Version:8.0 OS:Any
Assigned to: CPU Architecture:Any
Tags: Contribution

[6 Mar 2023 23:31] OCA Admin
Description:
This bug tracks a contribution by Janick Reynders (Github user: janickr) as described in http://github.com/mysql/mysql-connector-j/pull/94

How to repeat:
See description

Suggested fix:
See contribution code attached
[6 Mar 2023 23:31] OCA Admin
Contribution submitted via Github - Only call Messages.getString(...) when it's needed (when the SQLException is thr 
(*) Contribution by Janick Reynders (Github janickr, mysql-connector-j/pull/94#issuecomment-1457175525): I confirm the code being submitted is offered under the terms of the OCA, and that I am authorized to contribute it.

Contribution: git_patch_1264932630.txt (text/plain), 2.42 KiB.

[7 Mar 2023 4:17] MySQL Verification Team
Hello Janick Reynders,

Thank you for the report and contribution.

regards,
Umesh
[5 Apr 18:07] Daniel So
Posted by developer:
 
Added the following entry to the Connector/J 8.4.0 changelog: 

"When a SQLException is thrown, the calling of Messages.getString() is now delayed until it is really necessary, in order to save resources. Thanks to Janick Reynders for contributing to this fix."