Project

General

Profile

Actions

Bug #21137

closed

Upgrade to Jetty 10

Added by François ARMAND over 2 years ago. Updated over 2 years ago.

Status:
Released
Priority:
N/A
Category:
Packaging
Target version:
Severity:
UX impact:
User visibility:
Effort required:
Priority:
0
Name check:
To do
Fix check:
Checked
Regression:

Description

Use the last 9.x available

EDIT: jetty 9.0 branches community supports end in June 2022. We need to see if 11.x version is OK.


Subtasks 2 (0 open2 closed)

Bug #21151: Make rudder-jetty.conf and default rudder-jetty compatible with JVM 11 and 17ReleasedAlexis MoussetActions
Bug #21243: Bad webapp directory in jetty 10 ReleasedAlexis MoussetActions
Actions #1

Updated by François ARMAND over 2 years ago

  • Description updated (diff)
Actions #2

Updated by François ARMAND over 2 years ago

Quick test with just an untar of jetty 11.0.6 and replacing it in a 7.1:

- only works with JAVA 11 and up
- JVM option will need to be changed, OpenJDK 64-Bit Server VM warning: Option UseConcMarkSweepGC was deprecated in version 9.0 and will likely be removed in a future release.
- our rolling log is broken, we will need to see how it's done in jetty 11:

root@server:/opt/rudder# /bin/java -server -Xms1024m -Xmx1024m -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled -Dfile.encoding=UTF-8 -Drudder.configFile=/opt/rudder/etc/rudder-web.properties -Drudder.authFile=/opt/rudder/etc/rudder-users.xml -Dlogback.configurationFile=/opt/rudder/etc/logback.xml -Drun.mode=production -XX:+CrashOnOutOfMemoryError -Djetty.home=/opt/rudder/jetty -Djetty.base=/opt/rudder/etc/rudder-jetty-base -Djava.io.tmpdir=/var/rudder/tmp/jetty -jar /opt/rudder/jetty/start.jar OPTIONS=Server jetty.state=/opt/rudder/etc/rudder-jetty-base/rudder-jetty.state jetty-started.xml
OpenJDK 64-Bit Server VM warning: Option UseConcMarkSweepGC was deprecated in version 9.0 and will likely be removed in a future release.
2022-05-19 16:31:26.809:WARN :oejx.XmlConfiguration:main: Deprecated method public static org.eclipse.jetty.util.log.Logger org.eclipse.jetty.util.log.Log.getRootLogger() in file:///opt/rudder/etc/rudder-jetty-base/etc/console-capture.xml
2022-05-19 16:31:26.813:WARN :oejx.XmlConfiguration:main: Config error java.lang.IllegalStateException: No Method: <Call name="info"><Arg>Console stderr/stdout captured to <Ref refid="ServerLogName"/></Arg></Call> on class org.eclipse.jetty.util.log.Slf4jLogger at <Call name="info"><Arg>Console stderr/stdout captured to <Ref refid="ServerLogName"/></Arg></Call> in file:///opt/rudder/etc/rudder-jetty-base/etc/console-capture.xml
2022-05-19 16:31:26.813:WARN :oejx.XmlConfiguration:main: Config error java.lang.IllegalStateException: No Method: <Call name="info"><Arg>Console stderr/stdout captured to <Ref refid="ServerLogName"/></Arg></Call> on class org.eclipse.jetty.util.log.Slf4jLogger at <Get name="rootLogger"><Call name="info"><Arg>Console stderr/stdout captured to <Ref refid="ServerLogName"/></Arg></Call></Get> in file:///opt/rudder/etc/rudder-jetty-base/etc/console-capture.xml
2022-05-19 16:31:26.813:WARN :oejx.XmlConfiguration:main: Unable to execute XmlConfiguration
java.lang.IllegalStateException: No Method: <Call name="info"><Arg>Console stderr/stdout captured to <Ref refid="ServerLogName"/></Arg></Call> on class org.eclipse.jetty.util.log.Slf4jLogger
    at org.eclipse.jetty.xml.XmlConfiguration$JettyXmlConfiguration.call(XmlConfiguration.java:936)
    at org.eclipse.jetty.xml.XmlConfiguration$JettyXmlConfiguration.configure(XmlConfiguration.java:464)
    at org.eclipse.jetty.xml.XmlConfiguration$JettyXmlConfiguration.get(XmlConfiguration.java:863)
    at org.eclipse.jetty.xml.XmlConfiguration$JettyXmlConfiguration.configure(XmlConfiguration.java:467)
    at org.eclipse.jetty.xml.XmlConfiguration$JettyXmlConfiguration.configure(XmlConfiguration.java:417)
    at org.eclipse.jetty.xml.XmlConfiguration.configure(XmlConfiguration.java:319)
    at org.eclipse.jetty.xml.XmlConfiguration.lambda$main$4(XmlConfiguration.java:1853)
    at java.base/java.security.AccessController.doPrivileged(Native Method)
    at org.eclipse.jetty.xml.XmlConfiguration.main(XmlConfiguration.java:1810)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.base/java.lang.reflect.Method.invoke(Method.java:566)
    at org.eclipse.jetty.start.Main.invokeMain(Main.java:228)
    at org.eclipse.jetty.start.Main.start(Main.java:517)
    at org.eclipse.jetty.start.Main.main(Main.java:75)
Caused by:
java.lang.NoSuchMethodException: info
    at org.eclipse.jetty.xml.XmlConfiguration$JettyXmlConfiguration.call(XmlConfiguration.java:973)
    at org.eclipse.jetty.xml.XmlConfiguration$JettyXmlConfiguration.call(XmlConfiguration.java:928)

If we remove the culprit, then it writes logs into /opt/rudder/logs

Then, it looks for webapp directory in file:///opt/rudder/etc/rudder-jetty-base/webapps - it will need to be configured

Then, missing java.lang.NoClassDefFoundError: javax/servlet/ServletContextListener => seems bad.
=> and it's expected, since that version of jetty only supports a version of servlet that Lift does not support.

Using jetty-10.x, rudder starts well and is working as expected.

So, apport for the webapp directory config to find, and see how rolling logs are done now, it seems to be rather easy.

Actions #3

Updated by François ARMAND over 2 years ago

  • Status changed from New to In progress
Actions #4

Updated by François ARMAND over 2 years ago

  • Status changed from In progress to Pending technical review
  • Assignee changed from François ARMAND to Benoît PECCATTE
  • Pull Request set to https://github.com/Normation/rudder-packages/pull/2607
Actions #5

Updated by François ARMAND over 2 years ago

  • Status changed from Pending technical review to Pending release
Actions #6

Updated by François ARMAND over 2 years ago

  • Subtask #21243 added
Actions #7

Updated by Alexis Mousset over 2 years ago

  • Fix check changed from To do to Checked
Actions #8

Updated by François ARMAND over 2 years ago

  • Subject changed from Upgrade Jetty version for Rudder 7.2 to Upgrade to Jetty 10 for Rudder 7.2
Actions #9

Updated by Alexis Mousset over 2 years ago

  • Subject changed from Upgrade to Jetty 10 for Rudder 7.2 to Upgrade to Jetty 10
Actions #10

Updated by Vincent MEMBRÉ over 2 years ago

  • Status changed from Pending release to Released

This bug has been fixed in Rudder 7.2.0~beta1 which was released today.

Actions

Also available in: Atom PDF