adoptium / adoptium/installer

MSI: RegKey "CurrentVersion" is not set on latest Adoptium JDK8 build

Open
#329 5 comments 0 reactions 0 assignees View on GitHub
Dominant language
Jinja
Stars
168
Forks
77
Avg merge
2d 14h
Merged PRs (30d)
12

Description

### To reproduce
- Install 8u292 with install option `JavaSoft (Oracle) Registry Keys`
- Install 8u302 with same install option

### Observed behaviour
- After 292 install, entry for `HKEY_LOCAL_MACHINE/SOFTWARE/JavaSoft/Java Development Kit` `CurrentVersion=1.8`
- After 302 install, this entry is not there. The child entries are there (i.e 1.8 folder and 8.0.302.8 folder)

### Expected behaviour
- CurrentVersion should still be set to 1.8

### Screenshots
![image](https://user-images.githubusercontent.com/6430052/128393890-0cdb14d3-2501-42fb-b25e-b8eb664f69c5.png)

![image](https://user-images.githubusercontent.com/6430052/128393667-b0724b88-5eb3-4eb3-8e22-ae2258afa7bc.png)

### Suspected change
https://github.com/adoptium/installer/commit/e178aefa05d159b0f031ebfff3d543ee8f6103a7
https://github.com/adoptium/installer/pull/307
https://github.com/adoptium/installer/issues/300

I don't quite understand this condition
```
"1.8" AND JAVASOFT_CURRENTVERSION < $(var.ProductMajorVersion)]]>
```
Says if current version (installed) is 1.8 and current version is less than major version we're building (8), then set CurrentVersion. So it should work? Not sure why it doesn't or why that condition is there. But, this is a bit beyond me.

If I change it to the following, it works
```
"8"]]>
```
But If I install one with the patch, with no previous install, I don't get the reg values. So I'm not sure what's going on.

Contributor guide

Open the contributing guide

Research direction

Start with the MSI condition shown in the issue and compare the 8u292 and 8u302 installation behavior, then review the referenced change and merged pull request #341. Done means the JavaSoft CurrentVersion registry value is correctly preserved on upgrades and populated on a fresh install.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
build-system
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.