diff --git a/changelog.html b/changelog.html
index 92e3bd1..c9aa38c 100644
--- a/changelog.html
+++ b/changelog.html
@@ -43,6 +43,12 @@
Random Avatar Plugin Changelog
+1.2.0 -- (to be determined)
+
+ - Requires Openfire 5.0.0 or later
+ - #5: Openfire 5.0.0 compatibility
+
+
1.1.1 -- November 20, 2024
- Marked as last version to be compatible with Openfire versions prior to 5.0.0.
diff --git a/plugin.xml b/plugin.xml
index 2321343..409445f 100644
--- a/plugin.xml
+++ b/plugin.xml
@@ -6,7 +6,5 @@
Guus der Kinderen
${project.version}
2024-11-20
- 4.1.5
- 5.0.0
- 1.8
+ 5.0.0
diff --git a/pom.xml b/pom.xml
index 8729a05..018014c 100644
--- a/pom.xml
+++ b/pom.xml
@@ -7,7 +7,7 @@
plugins
org.igniterealtime.openfire
- 4.3.0
+ 5.0.0-SNAPSHOT
org.igniterealtime.openfire.plugins
@@ -34,8 +34,8 @@
diff --git a/src/java/org/igniterealtime/openfire/plugins/randomavatar/RandomAvatarPlugin.java b/src/java/org/igniterealtime/openfire/plugins/randomavatar/RandomAvatarPlugin.java
index 179b8d6..6c5c1e2 100644
--- a/src/java/org/igniterealtime/openfire/plugins/randomavatar/RandomAvatarPlugin.java
+++ b/src/java/org/igniterealtime/openfire/plugins/randomavatar/RandomAvatarPlugin.java
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2019-2023 Ignite Realtime Foundation. All rights reserved.
+ * Copyright (C) 2019-2024 Ignite Realtime Foundation. All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -15,11 +15,7 @@
*/
package org.igniterealtime.openfire.plugins.randomavatar;
-import org.apache.tomcat.InstanceManager;
-import org.apache.tomcat.SimpleInstanceManager;
-import org.eclipse.jetty.apache.jsp.JettyJasperInitializer;
-import org.eclipse.jetty.plus.annotation.ContainerInitializer;
-import org.eclipse.jetty.webapp.WebAppContext;
+import org.eclipse.jetty.ee8.webapp.WebAppContext;
import org.jivesoftware.openfire.container.Plugin;
import org.jivesoftware.openfire.container.PluginManager;
import org.jivesoftware.openfire.http.HttpBindManager;
@@ -27,8 +23,6 @@
import org.slf4j.LoggerFactory;
import java.io.File;
-import java.util.ArrayList;
-import java.util.List;
/**
* An Openfire plugin that makes available an avatar-exposing webservice.
@@ -56,10 +50,6 @@ public void initializePlugin( PluginManager manager, File pluginDirectory )
context.setClassLoader( this.getClass().getClassLoader() );
Log.debug( "Ensure the JSP engine is initialized correctly (in order to be able to cope with Tomcat/Jasper precompiled JSPs)." );
- final List initializers = new ArrayList<>();
- initializers.add( new ContainerInitializer( new JettyJasperInitializer(), null ) );
- context.setAttribute( "org.eclipse.jetty.containerInitializers", initializers );
- context.setAttribute( InstanceManager.class.getName(), new SimpleInstanceManager() );
context.setAttribute( "org.igniterealtime.openfire.plugins.randomavatar.plugindirectory", pluginDirectory.toPath() );
Log.debug( "Registering context with the embedded webserver." );
HttpBindManager.getInstance().addJettyHandler( context );