Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release v1.1.1 and 5.0.0 compatibility changes #6

Merged
merged 4 commits into from
Nov 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions changelog.html
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,17 @@ <h1>
Random Avatar Plugin Changelog
</h1>

<p><b>1.2.0</b> -- (to be determined)</p>
<ul>
<li>Requires Openfire 5.0.0 or later</li>
<li><a href="https://github.com/igniterealtime/openfire-randomavatar-plugin/issues/5">#5:</a> Openfire 5.0.0 compatibility</li>
</ul>

<p><b>1.1.1</b> -- November 20, 2024</p>
<ul>
<li>Marked as last version to be compatible with Openfire versions prior to 5.0.0.</li>
</ul>

<p><b>1.1.0</b> -- May 23, 2023</p>
<ul>
<li>Remove unused exclusion to authentication filter</li>
Expand Down
5 changes: 2 additions & 3 deletions plugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
<description>${project.description}</description>
<author>Guus der Kinderen</author>
<version>${project.version}</version>
<date>2023-05-23</date>
<minServerVersion>4.1.5</minServerVersion>
<minJavaVersion>1.8</minJavaVersion>
<date>2024-11-20</date>
<minServerVersion>5.0.0</minServerVersion>
</plugin>
6 changes: 3 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<artifactId>plugins</artifactId>
<groupId>org.igniterealtime.openfire</groupId>
<version>4.3.0</version>
<version>5.0.0-SNAPSHOT</version>
</parent>

<groupId>org.igniterealtime.openfire.plugins</groupId>
Expand All @@ -34,8 +34,8 @@
</plugin>
<!-- Compiles the Openfire Admin Console JSP pages.
<plugin>
<groupId>org.eclipse.jetty</groupId>
<artifactId>jetty-jspc-maven-plugin</artifactId>
<groupId>org.eclipse.jetty.ee8</groupId>
<artifactId>jetty-ee8-jspc-maven-plugin</artifactId>
</plugin> -->
</plugins>
</build>
Expand Down
Original file line number Diff line number Diff line change
@@ -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.
Expand All @@ -15,20 +15,14 @@
*/
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;
import org.slf4j.Logger;
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.
Expand Down Expand Up @@ -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<ContainerInitializer> 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 );
Expand Down