Re: RFR: 8281298: Revise the creation of unmodifiable list

2022-02-06 Thread Claes Redestad
On Sat, 5 Feb 2022 20:29:50 GMT, Xue-Lei Andrew Fan wrote: > In [JDK-8281289](https://bugs.openjdk.java.net/browse/JDK-8281289), the > SSLParameters class was updated with the patch: > > - return Collections.unmodifiableList(new > ArrayList<>(sniNames.values())); > + return List.copyOf(sniName

Re: RFR: 8281298: Revise the creation of unmodifiable list

2022-02-06 Thread Xue-Lei Andrew Fan
On Sun, 6 Feb 2022 22:11:06 GMT, Claes Redestad wrote: > This looks like an appropriate solution which avoids the minor compatibility > risk introduced by the previous change - and you might even end up being more > efficient both when setting and reading the names/matchers. > > (Since we're g

Integrated: 8281298: Revise the creation of unmodifiable list

2022-02-06 Thread Xue-Lei Andrew Fan
On Sat, 5 Feb 2022 20:29:50 GMT, Xue-Lei Andrew Fan wrote: > In [JDK-8281289](https://bugs.openjdk.java.net/browse/JDK-8281289), the > SSLParameters class was updated with the patch: > > - return Collections.unmodifiableList(new > ArrayList<>(sniNames.values())); > + return List.copyOf(sniName