Skip to content

Commit

Permalink
Update default OpenJDK versions for Q2 2023 releases (#459)
Browse files Browse the repository at this point in the history
  • Loading branch information
Malax authored Apr 24, 2023
1 parent 85010d3 commit bd2a480
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 10 deletions.
5 changes: 5 additions & 0 deletions buildpacks/jvm/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

* Default version for **OpenJDK 8** is now `1.8.0_372`. ([#459](https://github.com/heroku/buildpacks-jvm/pull/459))
* Default version for **OpenJDK 11** is now `11.0.19`. ([#459](https://github.com/heroku/buildpacks-jvm/pull/459))
* Default version for **OpenJDK 17** is now `17.0.7`. ([#459](https://github.com/heroku/buildpacks-jvm/pull/459))
* Default version for **OpenJDK 20** is now `20.0.1`. ([#459](https://github.com/heroku/buildpacks-jvm/pull/459))

## [1.0.8] 2023/03/31

* Add support for `SKIP_HEROKU_JVM_METRICS_AGENT_INSTALLATION` environment variable. When set to `true`, the installation of the [Heroku JVM metrics agent](https://github.com/heroku/heroku-java-metrics-agent) will be skipped. ([#444](https://github.com/heroku/buildpacks-jvm/pull/444))
Expand Down
16 changes: 8 additions & 8 deletions buildpacks/jvm/src/version.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,19 @@ pub(crate) fn normalize_version_string<S: Into<String>>(

let version_string = match user_version_string {
"7" | "1.7" => "1.7.0_352",
"8" | "1.8" => "1.8.0_362",
"8" | "1.8" => "1.8.0_372",
"9" | "1.9" => "9.0.4",
"10" => "10.0.2",
"11" => "11.0.18",
"11" => "11.0.19",
"12" => "12.0.2",
"13" => "13.0.14",
"14" => "14.0.2",
"15" => "15.0.10",
"16" => "16.0.2",
"17" => "17.0.6",
"17" => "17.0.7",
"18" => "18.0.2.1",
"19" => "19.0.2",
"20" => "20.0.0",
"20" => "20.0.1",
other => other,
};

Expand Down Expand Up @@ -111,22 +111,22 @@ mod tests {
fn normalize_version_string_stack_specific_distribution() {
assert_eq!(
normalize_version_string(&stack_id!("heroku-18"), "8"),
Ok((OpenJDKDistribution::Heroku, String::from("1.8.0_362")))
Ok((OpenJDKDistribution::Heroku, String::from("1.8.0_372")))
);

assert_eq!(
normalize_version_string(&stack_id!("heroku-20"), "8"),
Ok((OpenJDKDistribution::Heroku, String::from("1.8.0_362")))
Ok((OpenJDKDistribution::Heroku, String::from("1.8.0_372")))
);

assert_eq!(
normalize_version_string(&stack_id!("heroku-22"), "8"),
Ok((OpenJDKDistribution::AzulZulu, String::from("1.8.0_362")))
Ok((OpenJDKDistribution::AzulZulu, String::from("1.8.0_372")))
);

assert_eq!(
normalize_version_string(&stack_id!("bogus"), "8"),
Ok((OpenJDKDistribution::AzulZulu, String::from("1.8.0_362")))
Ok((OpenJDKDistribution::AzulZulu, String::from("1.8.0_372")))
);
}

Expand Down
4 changes: 2 additions & 2 deletions buildpacks/jvm/tests/integration_tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ fn test() {
context.run_shell_command("java -version").stderr,
match builder_name.as_str() {
"heroku/buildpacks:18" | "heroku/buildpacks:20" =>
"openjdk version \"1.8.0_362-heroku\"",
_ => "openjdk version \"1.8.0_362\"",
"openjdk version \"1.8.0_372-heroku\"",
_ => "openjdk version \"1.8.0_372\"",
}
);
},
Expand Down

0 comments on commit bd2a480

Please sign in to comment.