See issue 196075. The default root for userdir and cachedir will respect OS specific recommendations. Installer/uninstaller has to change logic to work with these places.
Needed to incorporate as same logic as in netbeans launcher. Would be nice to have a native utility to sharing this across more applications - issue 207559.
Java part and unix/mac part: core-main/rev/42c342043910
Windows part done - core-main/rev/d151f389891c