JDK-8039249 : Registry class enhancements
  • Type: Enhancement
  • Component: install
  • Affected Version: 8-pool
  • Priority: P4
  • Status: Closed
  • Resolution: Fixed
  • OS: windows
  • CPU: generic
  • Submitted: 2014-04-04
  • Updated: 2014-07-29
  • Resolved: 2014-05-14
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 8 JDK 9
8u20Fixed 9 b15Fixed
Description
Request from the team:
Registry class (introduced in jdk8 to replace buggy RegKey class and direct WinAPI registry functions) does not contain usage examples.

Also there are some minor issue in the class which should be fixed:
1) deleteKeyTree() method need a parameter to specify RedirectMode
in the current design 
Registry::LocaleMachine.deleteKeyTree(_T("SOFTWARE\\JavaSoft\\Java Update"))
deletes the key using the default RedirectMode

2) Registry objects need to keep RedirectMode value and open subkeys using it
Currently 
  Registry reg1(Registry::LocalMachine, _T("Software"), Registry::ReadOnly, Registry::Wow64_32);
  Registry reg2(reg1, _T("JavaSoft"), Registry::ReadOnly);
opens reg2 with the default RedirectMode
but it should use the parent RedirectMode (so in the example reg2 should be opened in Wow64_32)

Comments
Not verified by SQE. Internal fix.
04-06-2014

lack of the class design has been discovered: Windows registry function do not allow to mix WOW64 redirection options (so if parent key is opened with KEY_WOW64_32KEY option, child key must be opened with the same option, otherwise result is undefined) So the class should prevent the mixing
17-04-2014