Add Timeout to CompletableFuture in GeyserBungeePingPassthrough to Prevent Memory Leak (#4858)

* fix: Add timeout for GeyserBungeePingPassthrough#getPingInformation

Signed-off-by: ByteExceptionM <git@byteexception.eu>

* fix: Use Geyser Logger instead of Bungee Logger

Signed-off-by: ByteExceptionM <git@byteexception.eu>

* Fix typo

Co-authored-by: Konicai <71294714+Konicai@users.noreply.github.com>

* chore: Add ip suppression if configured

Signed-off-by: ByteExceptionM <git@byteexception.eu>

* Remove empty line

Co-authored-by: chris <github@onechris.mozmail.com>

* Remove empty line

Co-authored-by: chris <github@onechris.mozmail.com>

---------

Signed-off-by: ByteExceptionM <git@byteexception.eu>
Co-authored-by: Konicai <71294714+Konicai@users.noreply.github.com>
Co-authored-by: chris <github@onechris.mozmail.com>
This commit is contained in:
masel.io 2024-07-16 11:23:30 +02:00 committed by GitHub
parent 305495c923
commit 677a56cf6c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 15 additions and 3 deletions

View file

@ -35,10 +35,10 @@ import java.net.InetSocketAddress;
public interface IGeyserPingPassthrough {
/**
* Get the MOTD of the server displayed on the multiplayer screen
* Gets the ping information, including the MOTD and player count, from the server
*
* @param inetSocketAddress the ip address of the client pinging the server
* @return string of the MOTD
* @return the ping information
*/
@Nullable
GeyserPingInfo getPingInformation(InetSocketAddress inetSocketAddress);