From jlu at openjdk.org Tue Mar 4 01:42:15 2025 From: jlu at openjdk.org (Justin Lu) Date: Tue, 4 Mar 2025 01:42:15 GMT Subject: RFR: 8351074: Disallow null prefix and suffix in DecimalFormat Message-ID: Please review this PR and associated CSR which disallows passing null to 4 `DecimalFormat` prefix/suffix setter methods. Currently these setters do not check the input String for null. When the prefix/suffix is null, any such DecimalFormat instances are effectively non-functional as it will throw NPE for most operations. ------------- Commit messages: - init Changes: https://git.openjdk.org/jdk/pull/23880/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=23880&range=00 Issue: https://bugs.openjdk.org/browse/JDK-8351074 Stats: 60 lines in 2 files changed: 59 ins; 0 del; 1 mod Patch: https://git.openjdk.org/jdk/pull/23880.diff Fetch: git fetch https://git.openjdk.org/jdk.git pull/23880/head:pull/23880 PR: https://git.openjdk.org/jdk/pull/23880 From jlu at openjdk.org Tue Mar 4 01:47:40 2025 From: jlu at openjdk.org (Justin Lu) Date: Tue, 4 Mar 2025 01:47:40 GMT Subject: RFR: 8351074: Disallow null prefix and suffix in DecimalFormat [v2] In-Reply-To: References: Message-ID: <9YlrvHo8RszYEXGvitEoOr1l6cLODkGXiCV57cD2EJw=.526e1e82-be7b-4b5d-8899-6aa9cb8b66d6@github.com> > Please review this PR and associated CSR which disallows passing null to 4 `DecimalFormat` prefix/suffix setter methods. > > Currently these setters do not check the input String for null. When the prefix/suffix is null, any such DecimalFormat instances are effectively non-functional as it will throw NPE for most operations. Justin Lu has updated the pull request incrementally with one additional commit since the last revision: correct bug ID for test ------------- Changes: - all: https://git.openjdk.org/jdk/pull/23880/files - new: https://git.openjdk.org/jdk/pull/23880/files/56af293b..e13ac0d0 Webrevs: - full: https://webrevs.openjdk.org/?repo=jdk&pr=23880&range=01 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=23880&range=00-01 Stats: 1 line in 1 file changed: 0 ins; 0 del; 1 mod Patch: https://git.openjdk.org/jdk/pull/23880.diff Fetch: git fetch https://git.openjdk.org/jdk.git pull/23880/head:pull/23880 PR: https://git.openjdk.org/jdk/pull/23880 From darcy at openjdk.org Tue Mar 4 03:06:57 2025 From: darcy at openjdk.org (Joe Darcy) Date: Tue, 4 Mar 2025 03:06:57 GMT Subject: RFR: 8343478: Remove unnecessary @SuppressWarnings annotations (core-libs) [v12] In-Reply-To: References: <9ZqHljyJeMr8fPG4-iU6bfQT9hQxTAwrGCl4xsQn3LA=.0b01f899-d849-4e23-8d50-8f186aade664@github.com> Message-ID: On Sat, 15 Feb 2025 21:27:56 GMT, Archie Cobbs wrote: >> Please review this patch which removes unnecessary `@SuppressWarnings` annotations. > > Archie Cobbs has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 22 commits: > > - Merge branch 'master' into SuppressWarningsCleanup-core-libs to fix conflicts. > - Remove a few more unnecessary suppressions. > - Merge branch 'master' into SuppressWarningsCleanup-core-libs > - Update @LastModified tags. > - Revert changes under src/java.desktop (to be moved into a separate PR). > - Bump copyright year to 2025. > - Merge branch 'master' into SuppressWarningsCleanup-core-libs > - Remove more unnecessary suppressions. > - Merge branch 'master' into SuppressWarningsCleanup-core-libs > - Remove more unnecessary @SuppressWarnings annotations. > - ... and 12 more: https://git.openjdk.org/jdk/compare/ba281196...340ca514 The changes in java.base look fine. ------------- Marked as reviewed by darcy (Reviewer). PR Review: https://git.openjdk.org/jdk/pull/21852#pullrequestreview-2655808338 From asemenyuk at openjdk.org Tue Mar 4 15:33:18 2025 From: asemenyuk at openjdk.org (Alexey Semenyuk) Date: Tue, 4 Mar 2025 15:33:18 GMT Subject: RFR: 8343478: Remove unnecessary @SuppressWarnings annotations (core-libs) [v12] In-Reply-To: References: <9ZqHljyJeMr8fPG4-iU6bfQT9hQxTAwrGCl4xsQn3LA=.0b01f899-d849-4e23-8d50-8f186aade664@github.com> Message-ID: On Sat, 15 Feb 2025 21:27:56 GMT, Archie Cobbs wrote: >> Please review this patch which removes unnecessary `@SuppressWarnings` annotations. > > Archie Cobbs has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 22 commits: > > - Merge branch 'master' into SuppressWarningsCleanup-core-libs to fix conflicts. > - Remove a few more unnecessary suppressions. > - Merge branch 'master' into SuppressWarningsCleanup-core-libs > - Update @LastModified tags. > - Revert changes under src/java.desktop (to be moved into a separate PR). > - Bump copyright year to 2025. > - Merge branch 'master' into SuppressWarningsCleanup-core-libs > - Remove more unnecessary suppressions. > - Merge branch 'master' into SuppressWarningsCleanup-core-libs > - Remove more unnecessary @SuppressWarnings annotations. > - ... and 12 more: https://git.openjdk.org/jdk/compare/ba281196...340ca514 jpackage looks good ------------- Marked as reviewed by asemenyuk (Reviewer). PR Review: https://git.openjdk.org/jdk/pull/21852#pullrequestreview-2658012030 From acobbs at openjdk.org Tue Mar 4 15:50:57 2025 From: acobbs at openjdk.org (Archie Cobbs) Date: Tue, 4 Mar 2025 15:50:57 GMT Subject: RFR: 8343478: Remove unnecessary @SuppressWarnings annotations (core-libs) [v12] In-Reply-To: References: <9ZqHljyJeMr8fPG4-iU6bfQT9hQxTAwrGCl4xsQn3LA=.0b01f899-d849-4e23-8d50-8f186aade664@github.com> Message-ID: On Sat, 15 Feb 2025 21:27:56 GMT, Archie Cobbs wrote: >> Please review this patch which removes unnecessary `@SuppressWarnings` annotations. > > Archie Cobbs has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 22 commits: > > - Merge branch 'master' into SuppressWarningsCleanup-core-libs to fix conflicts. > - Remove a few more unnecessary suppressions. > - Merge branch 'master' into SuppressWarningsCleanup-core-libs > - Update @LastModified tags. > - Revert changes under src/java.desktop (to be moved into a separate PR). > - Bump copyright year to 2025. > - Merge branch 'master' into SuppressWarningsCleanup-core-libs > - Remove more unnecessary suppressions. > - Merge branch 'master' into SuppressWarningsCleanup-core-libs > - Remove more unnecessary @SuppressWarnings annotations. > - ... and 12 more: https://git.openjdk.org/jdk/compare/ba281196...340ca514 Thanks for the reviews! ------------- PR Comment: https://git.openjdk.org/jdk/pull/21852#issuecomment-2698092830 From jlu at openjdk.org Tue Mar 4 17:11:59 2025 From: jlu at openjdk.org (Justin Lu) Date: Tue, 4 Mar 2025 17:11:59 GMT Subject: Integrated: 4745837: Make grouping usage during parsing apparent in relevant NumberFormat methods In-Reply-To: References: Message-ID: On Wed, 26 Feb 2025 22:18:17 GMT, Justin Lu wrote: > Please review this PR which clarifies some behavior regarding NumberFormat grouping specifically in the grouping related methods. > > Please see the corresponding CSR for further detail. Note that an alternative would be to specify this at the DecimalFormat level, allowing NumberFormat subclasses to define this behavior how they want. IMO, I would expect `setGroupingUsed(boolean)` to affect both; a subclass could define `(is|set)(Parsing|Formatting)GroupingUsed` if need be, thus the proposed solution. This pull request has now been integrated. Changeset: 5b8d3491 Author: Justin Lu URL: https://git.openjdk.org/jdk/commit/5b8d3491bf685a64b72b0ae763697353d09f61a1 Stats: 14 lines in 1 file changed: 9 ins; 0 del; 5 mod 4745837: Make grouping usage during parsing apparent in relevant NumberFormat methods Reviewed-by: naoto ------------- PR: https://git.openjdk.org/jdk/pull/23813 From naoto at openjdk.org Tue Mar 4 17:56:06 2025 From: naoto at openjdk.org (Naoto Sato) Date: Tue, 4 Mar 2025 17:56:06 GMT Subject: RFR: 8351074: Disallow null prefix and suffix in DecimalFormat [v2] In-Reply-To: <9YlrvHo8RszYEXGvitEoOr1l6cLODkGXiCV57cD2EJw=.526e1e82-be7b-4b5d-8899-6aa9cb8b66d6@github.com> References: <9YlrvHo8RszYEXGvitEoOr1l6cLODkGXiCV57cD2EJw=.526e1e82-be7b-4b5d-8899-6aa9cb8b66d6@github.com> Message-ID: On Tue, 4 Mar 2025 01:47:40 GMT, Justin Lu wrote: >> Please review this PR and associated CSR which disallows passing null to 4 `DecimalFormat` prefix/suffix setter methods. >> >> Currently these setters do not check the input String for null. When the prefix/suffix is null, any such DecimalFormat instances are effectively non-functional as it will throw NPE for most operations. > > Justin Lu has updated the pull request incrementally with one additional commit since the last revision: > > correct bug ID for test src/java.base/share/classes/java/text/DecimalFormat.java line 2815: > 2813: *

Examples: +123, $123, sFr123 > 2814: * > 2815: * @param newValue the new positive prefix Although it may be apparent with the `@throws` tag, `@param` can also mention the new value is non-null. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/23880#discussion_r1979942411 From jlu at openjdk.org Tue Mar 4 18:12:48 2025 From: jlu at openjdk.org (Justin Lu) Date: Tue, 4 Mar 2025 18:12:48 GMT Subject: RFR: 8351074: Disallow null prefix and suffix in DecimalFormat [v3] In-Reply-To: References: Message-ID: > Please review this PR and associated CSR which disallows passing null to 4 `DecimalFormat` prefix/suffix setter methods. > > Currently these setters do not check the input String for null. When the prefix/suffix is null, any such DecimalFormat instances are effectively non-functional as it will throw NPE for most operations. Justin Lu has updated the pull request incrementally with one additional commit since the last revision: Make non-null apparent in param tag as well ------------- Changes: - all: https://git.openjdk.org/jdk/pull/23880/files - new: https://git.openjdk.org/jdk/pull/23880/files/e13ac0d0..623bfdac Webrevs: - full: https://webrevs.openjdk.org/?repo=jdk&pr=23880&range=02 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=23880&range=01-02 Stats: 4 lines in 1 file changed: 0 ins; 0 del; 4 mod Patch: https://git.openjdk.org/jdk/pull/23880.diff Fetch: git fetch https://git.openjdk.org/jdk.git pull/23880/head:pull/23880 PR: https://git.openjdk.org/jdk/pull/23880 From naoto at openjdk.org Tue Mar 4 18:32:04 2025 From: naoto at openjdk.org (Naoto Sato) Date: Tue, 4 Mar 2025 18:32:04 GMT Subject: RFR: 8351074: Disallow null prefix and suffix in DecimalFormat [v3] In-Reply-To: References: Message-ID: On Tue, 4 Mar 2025 18:12:48 GMT, Justin Lu wrote: >> Please review this PR and associated CSR which disallows passing null to 4 `DecimalFormat` prefix/suffix setter methods. >> >> Currently these setters do not check the input String for null. When the prefix/suffix is null, any such DecimalFormat instances are effectively non-functional as it will throw NPE for most operations. > > Justin Lu has updated the pull request incrementally with one additional commit since the last revision: > > Make non-null apparent in param tag as well LGTM ------------- Marked as reviewed by naoto (Reviewer). PR Review: https://git.openjdk.org/jdk/pull/23880#pullrequestreview-2658576784 From acobbs at openjdk.org Wed Mar 5 17:36:13 2025 From: acobbs at openjdk.org (Archie Cobbs) Date: Wed, 5 Mar 2025 17:36:13 GMT Subject: Integrated: 8343478: Remove unnecessary @SuppressWarnings annotations (core-libs) In-Reply-To: <9ZqHljyJeMr8fPG4-iU6bfQT9hQxTAwrGCl4xsQn3LA=.0b01f899-d849-4e23-8d50-8f186aade664@github.com> References: <9ZqHljyJeMr8fPG4-iU6bfQT9hQxTAwrGCl4xsQn3LA=.0b01f899-d849-4e23-8d50-8f186aade664@github.com> Message-ID: On Sat, 2 Nov 2024 15:40:30 GMT, Archie Cobbs wrote: > Please review this patch which removes unnecessary `@SuppressWarnings` annotations. This pull request has now been integrated. Changeset: 661bd5bf Author: Archie Cobbs URL: https://git.openjdk.org/jdk/commit/661bd5bfe883a7449c6949c9f4bd6b5d82d20e10 Stats: 211 lines in 93 files changed: 0 ins; 90 del; 121 mod 8343478: Remove unnecessary @SuppressWarnings annotations (core-libs) Reviewed-by: darcy, asemenyuk, joehw ------------- PR: https://git.openjdk.org/jdk/pull/21852 From jlu at openjdk.org Wed Mar 5 18:16:08 2025 From: jlu at openjdk.org (Justin Lu) Date: Wed, 5 Mar 2025 18:16:08 GMT Subject: Integrated: 8351074: Disallow null prefix and suffix in DecimalFormat In-Reply-To: References: Message-ID: On Tue, 4 Mar 2025 01:37:57 GMT, Justin Lu wrote: > Please review this PR and associated CSR which disallows passing null to 4 `DecimalFormat` prefix/suffix setter methods. > > Currently these setters do not check the input String for null. When the prefix/suffix is null, any such DecimalFormat instances are effectively non-functional as it will throw NPE for most operations. This pull request has now been integrated. Changeset: c3b48196 Author: Justin Lu URL: https://git.openjdk.org/jdk/commit/c3b48196af40356a8251b42db13e02ed905c2139 Stats: 64 lines in 2 files changed: 59 ins; 0 del; 5 mod 8351074: Disallow null prefix and suffix in DecimalFormat Reviewed-by: naoto ------------- PR: https://git.openjdk.org/jdk/pull/23880 From naoto at openjdk.org Thu Mar 6 23:42:25 2025 From: naoto at openjdk.org (Naoto Sato) Date: Thu, 6 Mar 2025 23:42:25 GMT Subject: RFR: 8351017: ChronoUnit.MONTHS.between() not giving correct result when date is in February Message-ID: Clarifying the explanation for `TemporalUnit.between()`. There is already an example for the `HOURS` case where the minutes are not enough to make a full hour. Explaining how smaller units contribute to determining the whole number, along with an explicit `MONTHS` example, which was the case reported by the bug submitter, will help users. ------------- Commit messages: - initial commit Changes: https://git.openjdk.org/jdk/pull/23937/files Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=23937&range=00 Issue: https://bugs.openjdk.org/browse/JDK-8351017 Stats: 9 lines in 1 file changed: 6 ins; 0 del; 3 mod Patch: https://git.openjdk.org/jdk/pull/23937.diff Fetch: git fetch https://git.openjdk.org/jdk.git pull/23937/head:pull/23937 PR: https://git.openjdk.org/jdk/pull/23937 From scolebourne at openjdk.org Fri Mar 7 06:50:51 2025 From: scolebourne at openjdk.org (Stephen Colebourne) Date: Fri, 7 Mar 2025 06:50:51 GMT Subject: RFR: 8351017: ChronoUnit.MONTHS.between() not giving correct result when date is in February In-Reply-To: References: Message-ID: <_SL0c6sLPnjoMI5DUDK6Qf0WRvUDGWYvfeEIzpwXFIY=.30f0ae78-e7a9-4db7-bb05-57fd5fff3564@github.com> On Thu, 6 Mar 2025 23:36:29 GMT, Naoto Sato wrote: > Clarifying the explanation for `TemporalUnit.between()`. There is already an example for the `HOURS` case where the minutes are not enough to make a full hour. Explaining how smaller units contribute to determining the whole number, along with an explicit `MONTHS` example, which was the case reported by the bug submitter, will help users. Marked as reviewed by scolebourne (Author). ------------- PR Review: https://git.openjdk.org/jdk/pull/23937#pullrequestreview-2666401651 From rriggs at openjdk.org Fri Mar 7 15:47:54 2025 From: rriggs at openjdk.org (Roger Riggs) Date: Fri, 7 Mar 2025 15:47:54 GMT Subject: RFR: 8351017: ChronoUnit.MONTHS.between() not giving correct result when date is in February In-Reply-To: References: Message-ID: <1Tovre03xAO-vYF_SbW_0NcE7MzFUF3LMF93kfXWsO4=.d071de1b-9e79-4ad0-a41c-aa2ff1c0b892@github.com> On Thu, 6 Mar 2025 23:36:29 GMT, Naoto Sato wrote: > Clarifying the explanation for `TemporalUnit.between()`. There is already an example for the `HOURS` case where the minutes are not enough to make a full hour. Explaining how smaller units contribute to determining the whole number, along with an explicit `MONTHS` example, which was the case reported by the bug submitter, will help users. A nice, simple and direct clarification. Thanks ------------- Marked as reviewed by rriggs (Reviewer). PR Review: https://git.openjdk.org/jdk/pull/23937#pullrequestreview-2667651475 From swen at openjdk.org Sun Mar 9 15:42:57 2025 From: swen at openjdk.org (Shaojin Wen) Date: Sun, 9 Mar 2025 15:42:57 GMT Subject: RFR: 8337279: Optimize format instant [v15] In-Reply-To: <9ntqc-mXvifLuLvIuP8WVd2fcfz8kx3TSUiwLmHOqjA=.6e455335-2ff3-48ad-9ad4-b71193cf7f3e@github.com> References: <17bf2n2yLh8dwpk9nsTF9G9UKHYWLDXDh0kie-9YrcA=.f19351bb-d47f-4ded-8a63-07914de70b4f@github.com> <9ntqc-mXvifLuLvIuP8WVd2fcfz8kx3TSUiwLmHOqjA=.6e455335-2ff3-48ad-9ad4-b71193cf7f3e@github.com> Message-ID: On Mon, 3 Feb 2025 22:31:10 GMT, Shaojin Wen wrote: >> By removing the redundant code logic in DateTimeFormatterBuilder$InstantPrinterParser#formatTo, the codeSize can be reduced and the performance can be improved. > > Shaojin Wen has updated the pull request incrementally with one additional commit since the last revision: > > from @natoj Keep it alive. ------------- PR Comment: https://git.openjdk.org/jdk/pull/20353#issuecomment-2708921754 From swen at openjdk.org Sun Mar 9 15:43:55 2025 From: swen at openjdk.org (Shaojin Wen) Date: Sun, 9 Mar 2025 15:43:55 GMT Subject: RFR: 8349189: Speed up DateTime parse & format via Class File API [v11] In-Reply-To: References: Message-ID: On Tue, 4 Feb 2025 13:39:28 GMT, Shaojin Wen wrote: >> By using the Class File API to dynamically generate a CompositePrinterParser, and defining DateTimePrinterParser[] printerParsers as a specific field, C2 can do TypeProfile optimization. >> >> Since the CompositePrinterParser is generated based on the pattern, we can make the following optimizations: >> >> 1. For example, for the parse and print of Month/DayOfMonth/Hour/Minute/Second with a fixed length of 2, do targeted parse and print optimization. >> >> 2. Parse uses LocalDate/LocalTime/LocalDateTime/OffsetDateTime for TemporalQuery to avoid the overhead of constructing DateTimeParseContext. >> >> These optimizations can significantly improve performance, with more than 100% performance improvement in many scenarios. > > Shaojin Wen has updated the pull request incrementally with one additional commit since the last revision: > > more use getInt & add more test Keep it alive. ------------- PR Comment: https://git.openjdk.org/jdk/pull/23384#issuecomment-2708922153 From naoto at openjdk.org Mon Mar 10 16:16:03 2025 From: naoto at openjdk.org (Naoto Sato) Date: Mon, 10 Mar 2025 16:16:03 GMT Subject: RFR: 8351017: ChronoUnit.MONTHS.between() not giving correct result when date is in February In-Reply-To: References: Message-ID: On Thu, 6 Mar 2025 23:36:29 GMT, Naoto Sato wrote: > Clarifying the explanation for `TemporalUnit.between()`. There is already an example for the `HOURS` case where the minutes are not enough to make a full hour. Explaining how smaller units contribute to determining the whole number, along with an explicit `MONTHS` example, which was the case reported by the bug submitter, will help users. Thank you for the reviews! ------------- PR Comment: https://git.openjdk.org/jdk/pull/23937#issuecomment-2711119572 From naoto at openjdk.org Mon Mar 10 16:16:04 2025 From: naoto at openjdk.org (Naoto Sato) Date: Mon, 10 Mar 2025 16:16:04 GMT Subject: Integrated: 8351017: ChronoUnit.MONTHS.between() not giving correct result when date is in February In-Reply-To: References: Message-ID: On Thu, 6 Mar 2025 23:36:29 GMT, Naoto Sato wrote: > Clarifying the explanation for `TemporalUnit.between()`. There is already an example for the `HOURS` case where the minutes are not enough to make a full hour. Explaining how smaller units contribute to determining the whole number, along with an explicit `MONTHS` example, which was the case reported by the bug submitter, will help users. This pull request has now been integrated. Changeset: 32f2c2d8 Author: Naoto Sato URL: https://git.openjdk.org/jdk/commit/32f2c2d80894552b8c5329cfa51c7e836314901f Stats: 9 lines in 1 file changed: 6 ins; 0 del; 3 mod 8351017: ChronoUnit.MONTHS.between() not giving correct result when date is in February Reviewed-by: scolebourne, rriggs ------------- PR: https://git.openjdk.org/jdk/pull/23937 From jlu at openjdk.org Tue Mar 11 00:37:56 2025 From: jlu at openjdk.org (Justin Lu) Date: Tue, 11 Mar 2025 00:37:56 GMT Subject: RFR: 8345940: Migrate security-related resources from Java classes to properties files [v9] In-Reply-To: References: Message-ID: On Mon, 10 Mar 2025 17:57:42 GMT, Artur Barashev wrote: >> These resources files are in Java classes. If converted to properties files, the localized versions can use UTF-8 encoding directly. >> >> ./src/java.base/share/classes/sun/security/tools/keytool/Resources.java >> ./src/java.base/share/classes/sun/security/util/Resources.java >> ./src/java.base/share/classes/sun/security/util/AuthResources.java >> ./src/jdk.jartool/share/classes/sun/security/tools/jarsigner/Resources.java > > Artur Barashev has updated the pull request incrementally with one additional commit since the last revision: > > Keep the original copyright year Skimmed some tricky values and the conversions looked correct to me. Since it was tested that the values are the same before and after, this change looks good to me. ------------- Marked as reviewed by jlu (Committer). PR Review: https://git.openjdk.org/jdk/pull/22774#pullrequestreview-2672454949 From jlu at openjdk.org Tue Mar 11 00:37:57 2025 From: jlu at openjdk.org (Justin Lu) Date: Tue, 11 Mar 2025 00:37:57 GMT Subject: RFR: 8345940: Migrate security-related resources from Java classes to properties files [v4] In-Reply-To: References: Message-ID: On Mon, 10 Mar 2025 14:33:14 GMT, Artur Barashev wrote: >> src/jdk.jartool/share/classes/sun/security/tools/jarsigner/resources/jarsigner_de.properties line 40: >> >>> 38: If.keystore.is.not.password.protected.then.storepass.and.keypass.must.not.be.specified=Wenn der Keystore nicht kennwortgesch?tzt ist, d?rfen -storepass und -keypass nicht angegeben werden >>> 39: Usage.jarsigner.options.jar.file.alias=Verwendung: jarsigner [options] jar-file alias >>> 40: .jarsigner.verify.options.jar.file.alias.=\u0020 jarsigner -verify [options] jar-file [alias...] >> >> We have generally kept `\u0020` in these properties files for the purpose of making it clear that trailing white space in a value is intentional. Can we convert these non trailing `\u0020` to just ` `? > > In properties files the whitespaces after `=` get trimmed when compiled, so when we replace `\u0020` with ` ` we get an incorrect string. Ah, you're right, I am used to seeing those cases starting with `` to preserve the leading white space. Since it's just a stylistic choice, this seems fine then. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/22774#discussion_r1988192291 From erikj at openjdk.org Tue Mar 11 15:45:56 2025 From: erikj at openjdk.org (Erik Joelsson) Date: Tue, 11 Mar 2025 15:45:56 GMT Subject: RFR: 8345940: Migrate security-related resources from Java classes to properties files [v9] In-Reply-To: References: Message-ID: <5irTdPcTdpBrzwzWUiAaZqHKbGINiONFtIYDLIguyws=.1f241454-7cae-4f45-9383-57953b37de8b@github.com> On Mon, 10 Mar 2025 17:57:42 GMT, Artur Barashev wrote: >> These resources files are in Java classes. If converted to properties files, the localized versions can use UTF-8 encoding directly. >> >> ./src/java.base/share/classes/sun/security/tools/keytool/Resources.java >> ./src/java.base/share/classes/sun/security/util/Resources.java >> ./src/java.base/share/classes/sun/security/util/AuthResources.java >> ./src/jdk.jartool/share/classes/sun/security/tools/jarsigner/Resources.java > > Artur Barashev has updated the pull request incrementally with one additional commit since the last revision: > > Keep the original copyright year Build changes look good. Thanks for removing this special case in the build! ------------- Marked as reviewed by erikj (Reviewer). PR Review: https://git.openjdk.org/jdk/pull/22774#pullrequestreview-2675130279 From duke at openjdk.org Tue Mar 11 19:29:06 2025 From: duke at openjdk.org (duke) Date: Tue, 11 Mar 2025 19:29:06 GMT Subject: RFR: 8345940: Migrate security-related resources from Java classes to properties files [v9] In-Reply-To: References: Message-ID: On Mon, 10 Mar 2025 17:57:42 GMT, Artur Barashev wrote: >> These resources files are in Java classes. If converted to properties files, the localized versions can use UTF-8 encoding directly. >> >> ./src/java.base/share/classes/sun/security/tools/keytool/Resources.java >> ./src/java.base/share/classes/sun/security/util/Resources.java >> ./src/java.base/share/classes/sun/security/util/AuthResources.java >> ./src/jdk.jartool/share/classes/sun/security/tools/jarsigner/Resources.java > > Artur Barashev has updated the pull request incrementally with one additional commit since the last revision: > > Keep the original copyright year @artur-oracle Your change (at version 7d911bce09aa7ee1684a6f35cdb11e96167a53a3) is now ready to be sponsored by a Committer. ------------- PR Comment: https://git.openjdk.org/jdk/pull/22774#issuecomment-2715472109 From abarashev at openjdk.org Tue Mar 11 20:10:04 2025 From: abarashev at openjdk.org (Artur Barashev) Date: Tue, 11 Mar 2025 20:10:04 GMT Subject: Integrated: 8345940: Migrate security-related resources from Java classes to properties files In-Reply-To: References: Message-ID: On Mon, 16 Dec 2024 22:03:59 GMT, Artur Barashev wrote: > These resources files are in Java classes. If converted to properties files, the localized versions can use UTF-8 encoding directly. > > ./src/java.base/share/classes/sun/security/tools/keytool/Resources.java > ./src/java.base/share/classes/sun/security/util/Resources.java > ./src/java.base/share/classes/sun/security/util/AuthResources.java > ./src/jdk.jartool/share/classes/sun/security/tools/jarsigner/Resources.java This pull request has now been integrated. Changeset: 9a494181 Author: Artur Barashev Committer: Weijun Wang URL: https://git.openjdk.org/jdk/commit/9a49418138b93bc8ed8879be5c9b9b9c85ef47e1 Stats: 16201 lines in 83 files changed: 6064 ins; 10109 del; 28 mod 8345940: Migrate security-related resources from Java classes to properties files Reviewed-by: jlu, weijun, erikj ------------- PR: https://git.openjdk.org/jdk/pull/22774