diff --git a/doc/release-notes/10494-payara-upgrade.md b/doc/release-notes/10494-payara-upgrade.md new file mode 100644 index 00000000000..23ee0e698f7 --- /dev/null +++ b/doc/release-notes/10494-payara-upgrade.md @@ -0,0 +1,119 @@ +# Upgrade Payara to v6.2024.6 + +With this version of Dataverse, we encourage you to upgrade to version 6.2024.6. +This will address security issues accumulated since the release of 6.2023.8, which was required since Dataverse release 6.0. + +## Instructions for Upgrading + +If you are using GDCC containers, this upgrade is included when pulling new release images. +No manual intervention is necessary. + +We recommend you ensure you followed all update instructions from the past releases regarding Payara. +(Latest Payara update was for [v6.0](https://github.com/IQSS/dataverse/releases/tag/v6.0)) + +Upgrading requires a maintenance window and downtime. Please plan ahead, create backups of your database, etc. + +The steps below are a simple matter of reusing your existing domain directory with the new distribution. +But we also recommend that you review the Payara upgrade instructions as it could be helpful during any troubleshooting: +[Payara Release Notes](https://docs.payara.fish/community/docs/Release%20Notes/Release%20Notes%206.2024.6.html) +We assume you are already on a Dataverse 6.x installation, using a Payara 6.x release. + +```shell +export PAYARA=/usr/local/payara6 +``` + +(or `setenv PAYARA /usr/local/payara6` if you are using a `csh`-like shell) + +1\. Undeploy the previous version + +```shell + $PAYARA/bin/asadmin list-applications + $PAYARA/bin/asadmin undeploy dataverse<-version> +``` + +2\. Stop Payara + +```shell + service payara stop + rm -rf $PAYARA/glassfish/domains/domain1/generated + rm -rf $PAYARA/glassfish/domains/domain1/osgi-cache + rm -rf $PAYARA/glassfish/domains/domain1/lib/databases +``` + +3\. Move the current Payara directory out of the way + +```shell + mv $PAYARA $PAYARA.MOVED +``` + +4\. Download the new Payara version (6.2024.6), and unzip it in its place + +5\. Replace the brand new payara/glassfish/domains/domain1 with your old, preserved domain1 + +6\. Make sure that you have the following `--add-opens` options in your domain.xml. If not present, add them: + +```diff +--- payara-6.2023.8/glassfish/domains/domain1/config/domain.xml ++++ payara-6.2024.6/glassfish/domains/domain1/config/domain.xml +@@ -212,12 +212,16 @@ + --add-opens=java.naming/javax.naming.spi=ALL-UNNAMED + --add-opens=java.rmi/sun.rmi.transport=ALL-UNNAMED + --add-opens=java.logging/java.util.logging=ALL-UNNAMED ++ --add-opens=java.management/javax.management=ALL-UNNAMED ++ --add-opens=java.management/javax.management.openmbean=ALL-UNNAMED + [17|]--add-exports=java.base/sun.net.www=ALL-UNNAMED + [17|]--add-exports=java.base/sun.security.util=ALL-UNNAMED + [17|]--add-opens=java.base/java.lang.invoke=ALL-UNNAMED + [17|]--add-opens=java.desktop/java.beans=ALL-UNNAMED + [17|]--add-exports=jdk.naming.dns/com.sun.jndi.dns=ALL-UNNAMED + [17|]--add-exports=java.naming/com.sun.jndi.ldap=ALL-UNNAMED ++ [17|]--add-opens=java.base/java.io=ALL-UNNAMED ++ [21|]--add-opens=java.base/jdk.internal.misc=ALL-UNNAMED + -Xmx512m + -XX:NewRatio=2 + -XX:+UnlockDiagnosticVMOptions +@@ -447,12 +451,16 @@ + --add-opens=java.naming/javax.naming.spi=ALL-UNNAMED + --add-opens=java.rmi/sun.rmi.transport=ALL-UNNAMED + --add-opens=java.logging/java.util.logging=ALL-UNNAMED ++ --add-opens=java.management/javax.management=ALL-UNNAMED ++ --add-opens=java.management/javax.management.openmbean=ALL-UNNAMED + [17|]--add-exports=java.base/sun.net.www=ALL-UNNAMED + [17|]--add-exports=java.base/sun.security.util=ALL-UNNAMED + [17|]--add-opens=java.base/java.lang.invoke=ALL-UNNAMED + [17|]--add-opens=java.desktop/java.beans=ALL-UNNAMED + [17|]--add-exports=jdk.naming.dns/com.sun.jndi.dns=ALL-UNNAMED + [17|]--add-exports=java.naming/com.sun.jndi.ldap=ALL-UNNAMED ++ [17|]--add-opens=java.base/java.io=ALL-UNNAMED ++ [21|]--add-opens=java.base/jdk.internal.misc=ALL-UNNAMED + -Xmx512m + -XX:NewRatio=2 + -XX:+UnlockDiagnosticVMOptions +``` +(You can also save this as a patch file and try to apply it.) + +TODO: For the combined 6.3 release note, I would consider replacing the patch format above with just the 4 specific options, for clarity etc. (L.A.) As in: +``` + --add-opens=java.management/javax.management=ALL-UNNAMED + --add-opens=java.management/javax.management.openmbean=ALL-UNNAMED + [17|]--add-opens=java.base/java.io=ALL-UNNAMED + [21|]--add-opens=java.base/jdk.internal.misc=ALL-UNNAMED +``` + +7\. Start Payara + +```shell + service payara start +``` + +8\. Deploy this version. + +```shell + $PAYARA/bin/asadmin deploy dataverse-6.3.war +``` + +9\. Restart payara + +```shell + service payara stop + service payara start diff --git a/doc/sphinx-guides/source/admin/monitoring.rst b/doc/sphinx-guides/source/admin/monitoring.rst index ef306c88c6f..16bb18b7ad2 100644 --- a/doc/sphinx-guides/source/admin/monitoring.rst +++ b/doc/sphinx-guides/source/admin/monitoring.rst @@ -154,7 +154,7 @@ Tips: MicroProfile Metrics endpoint ----------------------------- -Payara provides the metrics endpoint: _ +Payara provides the metrics endpoint: _ The metrics you can retrieve that way: - `index_permit_wait_time_seconds_mean` displays how long does it take to receive a permit to index a dataset. - `index_time_seconds` displays how long does it take to index a dataset. diff --git a/doc/sphinx-guides/source/developers/classic-dev-env.rst b/doc/sphinx-guides/source/developers/classic-dev-env.rst index 0ebb9431383..d305019004e 100755 --- a/doc/sphinx-guides/source/developers/classic-dev-env.rst +++ b/doc/sphinx-guides/source/developers/classic-dev-env.rst @@ -93,15 +93,15 @@ On Linux, install ``jq`` from your package manager or download a binary from htt Install Payara ~~~~~~~~~~~~~~ -Payara 6.2023.8 or higher is required. +Payara 6.2024.6 or higher is required. To install Payara, run the following commands: ``cd /usr/local`` -``sudo curl -O -L https://nexus.payara.fish/repository/payara-community/fish/payara/distributions/payara/6.2023.8/payara-6.2023.8.zip`` +``sudo curl -O -L https://nexus.payara.fish/repository/payara-community/fish/payara/distributions/payara/6.2024.6/payara-6.2024.6.zip`` -``sudo unzip payara-6.2023.8.zip`` +``sudo unzip payara-6.2024.6.zip`` ``sudo chown -R $USER /usr/local/payara6`` diff --git a/doc/sphinx-guides/source/installation/prerequisites.rst b/doc/sphinx-guides/source/installation/prerequisites.rst index 571223e0aa6..151d44e6841 100644 --- a/doc/sphinx-guides/source/installation/prerequisites.rst +++ b/doc/sphinx-guides/source/installation/prerequisites.rst @@ -44,7 +44,7 @@ On RHEL/derivative you can make Java 17 the default with the ``alternatives`` co Payara ------ -Payara 6.2023.8 is recommended. Newer versions might work fine. Regular updates are recommended. +Payara 6.2024.6 is recommended. Newer versions might work fine. Regular updates are recommended. Installing Payara ================= @@ -55,8 +55,8 @@ Installing Payara - Download and install Payara (installed in ``/usr/local/payara6`` in the example commands below):: - # wget https://nexus.payara.fish/repository/payara-community/fish/payara/distributions/payara/6.2023.8/payara-6.2023.8.zip - # unzip payara-6.2023.8.zip + # wget https://nexus.payara.fish/repository/payara-community/fish/payara/distributions/payara/6.2024.6/payara-6.2024.6.zip + # unzip payara-6.2024.6.zip # mv payara6 /usr/local If nexus.payara.fish is ever down for maintenance, Payara distributions are also available from https://repo1.maven.org/maven2/fish/payara/distributions/payara/ diff --git a/doc/sphinx-guides/source/qa/test-automation.md b/doc/sphinx-guides/source/qa/test-automation.md index 708d0f88e23..fe0d51f9174 100644 --- a/doc/sphinx-guides/source/qa/test-automation.md +++ b/doc/sphinx-guides/source/qa/test-automation.md @@ -52,7 +52,7 @@ Go to the end of the log and then scroll up, looking for the failure. A failed A ``` TASK [dataverse : download payara zip] ***************************************** -fatal: [localhost]: FAILED! => {"changed": false, "dest": "/tmp/payara.zip", "elapsed": 10, "msg": "Request failed: ", "url": "https://nexus.payara.fish/repository/payara-community/fish/payara/distributions/payara/6.2023.8/payara-6.2023.8.zip"} +fatal: [localhost]: FAILED! => {"changed": false, "dest": "/tmp/payara.zip", "elapsed": 10, "msg": "Request failed: ", "url": "https://nexus.payara.fish/repository/payara-community/fish/payara/distributions/payara/6.2024.6/payara-6.2024.6.zip"} ``` In the example above, if Payara can't be downloaded, we're obviously going to have problems deploying Dataverse to it! diff --git a/modules/container-base/src/main/docker/Dockerfile b/modules/container-base/src/main/docker/Dockerfile index f093ced37c1..93f9fa4f0c1 100644 --- a/modules/container-base/src/main/docker/Dockerfile +++ b/modules/container-base/src/main/docker/Dockerfile @@ -166,8 +166,6 @@ RUN <-Duser.timezone=${project.timezone} -Dfile.encoding=${project.build.sourceEncoding} -Duser.language=${project.language} -Duser.region=${project.region} - 6.2023.8 + 6.2024.6 42.7.2 9.4.1 1.12.290 26.30.0 - 8.0.0 1.7.35 2.15.1 1.2 @@ -386,18 +385,6 @@ false - - - payara-patched-externals - Payara Patched Externals - https://raw.github.com/payara/Payara_PatchedProjects/master - - true - - - false - - central-repo Central Repository diff --git a/pom.xml b/pom.xml index 8fa1d993f6e..11025246e80 100644 --- a/pom.xml +++ b/pom.xml @@ -224,9 +224,6 @@ fish.payara.api payara-api provided - - ${payara.version} diff --git a/scripts/installer/as-setup.sh b/scripts/installer/as-setup.sh index 34deddf51a3..eb8c72973c8 100755 --- a/scripts/installer/as-setup.sh +++ b/scripts/installer/as-setup.sh @@ -117,9 +117,6 @@ function preliminary_setup() ./asadmin $ASADMIN_OPTS create-jvm-options "-Ddataverse.timerServer=true" - # Workaround for FISH-7722: Failed to deploy war with @Stateless https://github.com/payara/Payara/issues/6337 - ./asadmin $ASADMIN_OPTS create-jvm-options --add-opens=java.base/java.io=ALL-UNNAMED - # enable comet support ./asadmin $ASADMIN_OPTS set server-config.network-config.protocols.protocol.http-listener-1.http.comet-support-enabled="true"