Aelysium-Group / rusty-connector

A player and server connection manager for Velocity based Minecraft Networks!
GNU General Public License v3.0
77 stars 17 forks source link

Running /rustyconnector-paper:rc send kick players from the network if the send fails. #21

Closed TheDeafCreeper closed 1 year ago

TheDeafCreeper commented 1 year ago

This only happens specifically when a player is attempted to be sent using the paper side of the plugin, it just sends the error in console correctly on the proxy side of the plugin.

Potentially related to #17

Message

Status: EXECUTING_ERROR
Reason: There are no servers for you to connect to!

ID: 1121323411780419584
Timestamp: Thu Jun 22 06:18:54 UTC 2023
Contents: {"k":"[KEY]","v":1,"t":"SEND","o":"SERVER","a":"ns1006130.ip-135-148-52.us:41254","p":{"f":"woolsacre-game","p":"53d5c5cf-2a75-42a9-9ed0-6098e2fb8e1c"}}

Error on Proxy

[02:41:38 ERROR] [rustyconnector-velocity]: There was an issue handling the message. Throwing away...
java.lang.Exception: There was an issue connecting you to the server!
        at group.aelysium.rustyconnector.plugin.velocity.lib.message.handling.SendPlayerHandler.execute(SendPlayerHandler.java:37) ~[?:?]
        at group.aelysium.rustyconnector.plugin.velocity.lib.database.RedisSubscriber.processParameters(RedisSubscriber.java:85) ~[?:?]
        at group.aelysium.rustyconnector.plugin.velocity.lib.database.RedisSubscriber.onMessage(RedisSubscriber.java:49) ~[?:?]
        at group.aelysium.rustyconnector.core.lib.database.redis.RedisSubscriber$RedisMessageListener.message(RedisSubscriber.java:69) ~[?:?]
        at group.aelysium.rustyconnector.core.lib.database.redis.RedisSubscriber$RedisMessageListener.message(RedisSubscriber.java:66) ~[?:?]
        at io.lettuce.core.pubsub.PubSubEndpoint.notifyListeners(PubSubEndpoint.java:219) ~[?:?]
        at io.lettuce.core.pubsub.PubSubEndpoint.notifyMessage(PubSubEndpoint.java:208) ~[?:?]
        at io.lettuce.core.pubsub.PubSubCommandHandler.doNotifyMessage(PubSubCommandHandler.java:292) ~[?:?]
        at io.lettuce.core.pubsub.PubSubCommandHandler.notifyPushListeners(PubSubCommandHandler.java:223) ~[?:?]
        at io.lettuce.core.protocol.CommandHandler.decode(CommandHandler.java:647) ~[?:?]
        at io.lettuce.core.pubsub.PubSubCommandHandler.decode(PubSubCommandHandler.java:112) ~[?:?]
        at io.lettuce.core.protocol.CommandHandler.channelRead(CommandHandler.java:599) ~[?:?]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:442) ~[proxy.jar:3.2.0-SNAPSHOT (git-bda1430d-b259)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[proxy.jar:3.2.0-SNAPSHOT (git-bda1430d-b259)]
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) ~[proxy.jar:3.2.0-SNAPSHOT (git-bda1430d-b259)]
        at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410) ~[proxy.jar:3.2.0-SNAPSHOT (git-bda1430d-b259)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:440) ~[proxy.jar:3.2.0-SNAPSHOT (git-bda1430d-b259)]
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) ~[proxy.jar:3.2.0-SNAPSHOT (git-bda1430d-b259)]
        at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919) ~[proxy.jar:3.2.0-SNAPSHOT (git-bda1430d-b259)]
        at io.netty.channel.epoll.AbstractEpollStreamChannel$EpollStreamUnsafe.epollInReady(AbstractEpollStreamChannel.java:800) ~[proxy.jar:3.2.0-SNAPSHOT (git-bda1430d-b259)]
        at io.netty.channel.epoll.EpollEventLoop.processReady(EpollEventLoop.java:499) ~[proxy.jar:3.2.0-SNAPSHOT (git-bda1430d-b259)]
        at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:397) ~[proxy.jar:3.2.0-SNAPSHOT (git-bda1430d-b259)]
        at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:997) ~[proxy.jar:3.2.0-SNAPSHOT (git-bda1430d-b259)]
        at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) ~[proxy.jar:3.2.0-SNAPSHOT (git-bda1430d-b259)]
        at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) ~[proxy.jar:3.2.0-SNAPSHOT (git-bda1430d-b259)]
        at java.lang.Thread.run(Thread.java:833) [?:?]
nathan-i-martin commented 1 year ago

To validate expectations. Does this happen when there are in-fact no servers in the family? As in, the proxy isn't wrong when it says there are no servers to connect to, right?

TheDeafCreeper commented 1 year ago

Correct, I ran /rc family before attempting to join to verify that there were no servers in the family.

nathan-i-martin commented 1 year ago

Okay great just wanted to be sure! What was the error message that you see on the player's client on disconnect? I'm looking at the code right now, I think it should say There was an issue connecting you to that server! is that correct?

TheDeafCreeper commented 1 year ago

Yep, "There was an issue connecting you to that server!"

nathan-i-martin commented 1 year ago

okay perfect. Wanna compile this ^ and give it another try?

TheDeafCreeper commented 1 year ago

Will do.

nathan-i-martin commented 1 year ago

All that was happening was that, when an exception was thrown during the send sequence, it would disconnect the player with the message, instead of just sending them a message in chat

TheDeafCreeper commented 1 year ago

I'll also test if that "fixes" #17 (also I should probably rename that issue)

TheDeafCreeper commented 1 year ago

Alright, it does indeed now send a message instead of kicking in both cases.

It is kind of funny though getting "There was an issue connecting you to that server! There was an issue connecting you to the server!" in chat though.

nathan-i-martin commented 1 year ago

Perfect, I'll look at getting v0.5.3 out here sometime. Maybe I'll wait till tomorrow to see if any other bugs popup.

Alright, it does indeed now send a message instead of kicking in both cases.

It is kind of funny though getting "There was an issue connecting you to that server! There was an issue connecting you to the server!" in chat though.

Lol I'll fine tune the error messaging so it's not so dumb haha