Methods relying on the System's default locale or character set may cause unexpected results:
jshell> import org.archive.url.WaybackURLKeyMaker;
jshell> WaybackURLKeyMaker surtKeyMaker = new WaybackURLKeyMaker(true);
surtKeyMaker ==> org.archive.url.WaybackURLKeyMaker@4534b60d
jshell> surtKeyMaker.makeKey("https://SITE.ORG/")
$3 ==> "org,site)/"
jshell> Locale.setDefault(Locale.of("tr", "TR"))
jshell> surtKeyMaker.makeKey("https://SITE.ORG/")
$5 ==> "org,s%c4%b1te)/"
For code bundle in a software library, it is good practice to avoid these methods and use the ROOT locale, see
https://blog.thetaphi.de/2012/07/default-locales-default-charsets-and.html.
A PR is underway adding Uwe Schindler's "forbidden APIs" Maven plugin and fixing all occurrences of methods relying on default locale or charset.
Methods relying on the System's default locale or character set may cause unexpected results:
For code bundle in a software library, it is good practice to avoid these methods and use the
ROOTlocale, seehttps://blog.thetaphi.de/2012/07/default-locales-default-charsets-and.html.
A PR is underway adding Uwe Schindler's "forbidden APIs" Maven plugin and fixing all occurrences of methods relying on default locale or charset.