Closed kit8379 closed 1 year ago
werid i thought TAB plugin does not have redisbungee Velocity support based on this line from TAB's code https://github.com/NEZNAMY/TAB/blob/51635a7322029ed3ffb4ea2eab768e1c1dd16dca/velocity/src/main/java/me/neznamy/tab/platforms/velocity/VelocityTAB.java#L75
nvm found the v4 branch
it seems like Velocity disables RedisBungee first which closes the connection pool hence closed socket error.
i need full logs please if you are able too.
okay seems like that the case RedisBungee get disabled first before tab plugin does
[10:54:29 INFO] [redisbungee]: Turning off redis connections.....
[10:54:29 INFO] [redisbungee]: waiting for httpclient thread-pool termination.....
[10:54:29 INFO] [redisbungee]: RedisBungee shutdown complete
[10:54:29 INFO] [tab]: [TAB v4.0.0-SNAPSHOT] Failed to disable
[10:54:29 INFO] [tab]: java.net.SocketException: Socket closed
[10:54:29 INFO] [tab]: at java.base/sun.nio.ch.NioSocketImpl.ensureOpenAndConnected(NioSocketImpl.java:165)
[10:54:29 INFO] [tab]: at java.base/sun.nio.ch.NioSocketImpl.beginWrite(NioSocketImpl.java:366)
[10:54:29 INFO] [tab]: at java.base/sun.nio.ch.NioSocketImpl.implWrite(NioSocketImpl.java:411)
[10:54:29 INFO] [tab]: at java.base/sun.nio.ch.NioSocketImpl.write(NioSocketImpl.java:440)
[10:54:29 INFO] [tab]: at java.base/sun.nio.ch.NioSocketImpl$2.write(NioSocketImpl.java:826)
[10:54:29 INFO] [tab]: at java.base/java.net.Socket$SocketOutputStream.write(Socket.java:1035)
[10:54:29 INFO] [tab]: at com.imaginarycode.minecraft.redisbungee.internal.jedis.util.RedisOutputStream.flushBuffer(RedisOutputStream.java:57)
[10:54:29 INFO] [tab]: at com.imaginarycode.minecraft.redisbungee.internal.jedis.util.RedisOutputStream.flush(RedisOutputStream.java:138)
[10:54:29 INFO] [tab]: at com.imaginarycode.minecraft.redisbungee.internal.jedis.Connection.flush(Connection.java:303)
[10:54:29 INFO] [tab]: at com.imaginarycode.minecraft.redisbungee.internal.jedis.JedisPubSub.unsubscribe(JedisPubSub.java:54)
[10:54:29 INFO] [tab]: at com.imaginarycode.minecraft.redisbungee.api.PubSubListener.removeChannel(PubSubListener.java:63)
[10:54:29 INFO] [tab]: at com.imaginarycode.minecraft.redisbungee.AbstractRedisBungeeAPI.unregisterPubSubChannels(AbstractRedisBungeeAPI.java:285)
[10:54:29 INFO] [tab]: at me.neznamy.tab.platforms.velocity.features.VelocityRedisSupport.unregister(VelocityRedisSupport.java:38)
[10:54:29 INFO] [tab]: at me.neznamy.tab.shared.features.redis.RedisSupport.unload(RedisSupport.java:353)
[10:54:29 INFO] [tab]: at me.neznamy.tab.shared.FeatureManager.unload(FeatureManager.java:54)
[10:54:29 INFO] [tab]: at me.neznamy.tab.shared.TAB.unload(TAB.java:193)
[10:54:29 INFO] [tab]: at me.neznamy.tab.platforms.velocity.VelocityTAB.onProxyShutdown(VelocityTAB.java:91)
[10:54:29 INFO] [tab]: at me.neznamy.tab.platforms.velocity.Lmbda$4.execute(Unknown Source)
[10:54:29 INFO] [tab]: at com.velocitypowered.proxy.event.UntargetedEventHandler$VoidHandler.lambda$buildHandler$0(UntargetedEventHandler.java:56)
[10:54:29 INFO] [tab]: at com.velocitypowered.proxy.event.VelocityEventManager.fire(VelocityEventManager.java:598)
[10:54:29 INFO] [tab]: at com.velocitypowered.proxy.event.VelocityEventManager.lambda$fire$5(VelocityEventManager.java:479)
[10:54:29 INFO] [tab]: at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
[10:54:29 INFO] [tab]: at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
[10:54:29 INFO] [tab]: at java.base/java.lang.Thread.run(Thread.java:833)
Describe the bug Here is a bug report that related TAB plugin with RedisBungee (Velocity) implementation. The TAB plugin hooked into RedisBungee correctly and there is a issue occur after using multiple proxies:
"A issue when connecting to a server in a separate group from an isolated group server. The tab list displays correctly even if the server doesn't have the particular player. However, when switching to servers within the same group, the tab list only shows local players. To correct this, one must reconnect to an isolated group server and then reconnect back to the server in that group. Hopefully, this information can assist those facing similar problems."
We found out that the issue may related to error cause by RedisBungee. There is a related RedisBungee error occur during the server shutdown.
To Reproduce Steps to reproduce the behavior:
Expected behavior You can see this error in console
Screenshots
Redis version? it should be at least 6 and above. 7.0.8
Bungeecord version or (the bungee fork name eg: waterfall) and your plugins Velocity 3.2.0-SNAPSHOT (git-dc7efd93-b237)
console logs? 23.04.2023 - 17:53:50 - [TAB v4.0.0-SNAPSHOT] Failed to disable 23.04.2023 - 17:53:50 - java.net.SocketException: Socket closed 23.04.2023 - 17:53:50 - at java.base/sun.nio.ch.NioSocketImpl.ensureOpenAndConnected(NioSocketImpl.java:165) 23.04.2023 - 17:53:50 - at java.base/sun.nio.ch.NioSocketImpl.beginWrite(NioSocketImpl.java:366) 23.04.2023 - 17:53:50 - at java.base/sun.nio.ch.NioSocketImpl.implWrite(NioSocketImpl.java:411) 23.04.2023 - 17:53:50 - at java.base/sun.nio.ch.NioSocketImpl.write(NioSocketImpl.java:440) 23.04.2023 - 17:53:50 - at java.base/sun.nio.ch.NioSocketImpl$2.write(NioSocketImpl.java:826) 23.04.2023 - 17:53:50 - at java.base/java.net.Socket$SocketOutputStream.write(Socket.java:1035) 23.04.2023 - 17:53:50 - at com.imaginarycode.minecraft.redisbungee.internal.jedis.util.RedisOutputStream.flushBuffer(RedisOutputStream.java:57) 23.04.2023 - 17:53:50 - at com.imaginarycode.minecraft.redisbungee.internal.jedis.util.RedisOutputStream.flush(RedisOutputStream.java:138) 23.04.2023 - 17:53:50 - at com.imaginarycode.minecraft.redisbungee.internal.jedis.Connection.flush(Connection.java:303) 23.04.2023 - 17:53:50 - at com.imaginarycode.minecraft.redisbungee.internal.jedis.JedisPubSub.unsubscribe(JedisPubSub.java:54) 23.04.2023 - 17:53:50 - at com.imaginarycode.minecraft.redisbungee.api.PubSubListener.removeChannel(PubSubListener.java:63) 23.04.2023 - 17:53:50 - at com.imaginarycode.minecraft.redisbungee.AbstractRedisBungeeAPI.unregisterPubSubChannels(AbstractRedisBungeeAPI.java:285) 23.04.2023 - 17:53:50 - at me.neznamy.tab.platforms.velocity.features.VelocityRedisSupport.unregister(VelocityRedisSupport.java:38) 23.04.2023 - 17:53:50 - at me.neznamy.tab.shared.features.redis.RedisSupport.unload(RedisSupport.java:353) 23.04.2023 - 17:53:50 - at me.neznamy.tab.shared.FeatureManager.unload(FeatureManager.java:54) 23.04.2023 - 17:53:50 - at me.neznamy.tab.shared.TAB.unload(TAB.java:193) 23.04.2023 - 17:53:50 - at me.neznamy.tab.platforms.velocity.VelocityTAB.onProxyShutdown(VelocityTAB.java:91) 23.04.2023 - 17:53:50 - at me.neznamy.tab.platforms.velocity.Lmbda$33.execute(Unknown Source) 23.04.2023 - 17:53:50 - at com.velocitypowered.proxy.event.UntargetedEventHandler$VoidHandler.lambda$buildHandler$0(UntargetedEventHandler.java:56) 23.04.2023 - 17:53:50 - at com.velocitypowered.proxy.event.VelocityEventManager.fire(VelocityEventManager.java:598) 23.04.2023 - 17:53:50 - at com.velocitypowered.proxy.event.VelocityEventManager.lambda$fire$5(VelocityEventManager.java:479) 23.04.2023 - 17:53:50 - at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) 23.04.2023 - 17:53:50 - at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) 23.04.2023 - 17:53:50 - at java.base/java.lang.Thread.run(Thread.java:833)