# How update Java (openjdk) version?

**URL:** <https://discuss.bitrise.io/t/how-update-java-openjdk-version/10610>\
**Category:** Question & Answer\
**Created:** [October 15, 2019, 7:08pm UTC](https://discuss.bitrise.io/t/how-update-java-openjdk-version/10610 "2019-10-15T19:08:48Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![rafaelcrvs](https://avatars.discourse-cdn.com/v4/letter/r/5e9695/32.png) [@rafaelcrvs](https://discuss.bitrise.io/u/rafaelcrvs)\
**Post date:** [October 15, 2019, 7:08pm UTC](https://discuss.bitrise.io/t/how-update-java-openjdk-version/10610/1 "2019-10-15T19:08:48Z")

</div>

Hello,

How can I update Java (openjdk) version? I’m currently adding a step (script) to my workflow using the commands below:

```
brew tap AdoptOpenJDK/openjdk
brew cask install adoptopenjdk11

```

but once installed, the version is not applied/used in the other steps of my workflow.

Below is the result of the script after running the above commands:

```
+------------------------------------------------------------------------------+
| (1) Install Java |
+------------------------------------------------------------------------------+
| id: script |
| version: 1.1.5 |
| collection: https://github.com/bitrise-io/bitrise-steplib.git |
| toolkit: bash |
| time: 2019-10-15T19:06:54Z |
+------------------------------------------------------------------------------+
| |
+ brew tap AdoptOpenJDK/openjdk
==> Tapping adoptopenjdk/openjdk
Cloning into '/usr/local/Homebrew/Library/Taps/adoptopenjdk/homebrew-openjdk'...
Tapped 20 casks (83 files, 82.9KB).
+ brew cask install adoptopenjdk11
==> Satisfying dependencies
==> Downloading https://github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11.0.4%2B11.4/OpenJDK11U-jdk_x64_mac_hotspot_11.0.4_11.pkg
==> Downloading from https://github-production-release-asset-2e65be.s3.amazonaws.com/140419044/406b2800-c5f3-11e9-959c-e63f9e529d9a?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20191015%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20191015T190659Z&X-Amz-Expires=300&X-Amz-Signature=70d424fcbb0c6bed7d0ab24d289ba72fe507bc0a0ec3be3e5e50df07895f3ec6&X-Amz-SignedHeaders=host&actor_id=0&response-content-disposition=attachment%3B%20filename%3DOpenJDK11U-jdk_x64_mac_hotspot_11.0.4_11.pkg&response-content-type=application%2Foctet-stream
==> Verifying SHA-256 checksum for Cask 'adoptopenjdk11'.
==> Installing Cask adoptopenjdk11
==> Running installer for adoptopenjdk11; your password may be necessary.
==> Package installers may write to any location; options such as --appdir are ignored.
installer: Package name is AdoptOpenJDK
installer: Upgrading at base path /
installer: The upgrade was successful.
🍺 adoptopenjdk11 was successfully installed!

```

Thanks,  
Rafael

---

<div class="post-metadata">

**Author:** ![rafaelcrvs](https://avatars.discourse-cdn.com/v4/letter/r/5e9695/32.png) [@rafaelcrvs](https://discuss.bitrise.io/u/rafaelcrvs)\
**Post date:** [October 17, 2019, 9:29pm UTC](https://discuss.bitrise.io/t/how-update-java-openjdk-version/10610/2 "2019-10-17T21:29:59Z")

</div>

Update here?

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex016/uploads/bitrise/original/2X/d/d901cf2aad020f2dd11918afc89ec2089bb87b35.png) [@system](https://discuss.bitrise.io/u/system)\
**Post date:** [November 16, 2019, 9:30pm UTC](https://discuss.bitrise.io/t/how-update-java-openjdk-version/10610/3 "2019-11-16T21:30:02Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.

---

<div class="post-metadata">

**Author:** ![bitce](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.bitrise.io/bitce/32/1639_2.png) [@bitce](https://discuss.bitrise.io/u/bitce)\
**Post date:** [December 7, 2019, 9:33am UTC](https://discuss.bitrise.io/t/how-update-java-openjdk-version/10610/4 "2019-12-07T09:33:44Z")

</div>



---

<div class="post-metadata">

**Author:** ![bitce](https://sea2.discourse-cdn.com/flex016/user_avatar/discuss.bitrise.io/bitce/32/1639_2.png) [@bitce](https://discuss.bitrise.io/u/bitce)\
**Post date:** [December 7, 2019, 9:34am UTC](https://discuss.bitrise.io/t/how-update-java-openjdk-version/10610/5 "2019-12-07T09:34:19Z")

</div>

Hi @rafaelcrvs!

Sorry for the huge delay. Can you please send us a build URL to one of these instances? So we can see what’s the actual behaviour, and how you are looking to use this. Thanks!
