Remove HeartbeatPacket

This commit is contained in:
Draycia committed 2022-07-17 20:34:53 -07:00
1 parent 307be2e6bd
commit caefe2791a
1 file changed
+1 -7
@@ -77,7 +77,7 @@ public class MessagingManager {
PacketManager.register(PacketVersionPacket.class, PacketVersionPacket::new);
PacketManager.register(PacketVersionRequestPacket.class, PacketVersionRequestPacket::new);
PacketManager.register(ShutdownPacket.class, ShutdownPacket::new);
PacketManager.register(HeartbeatPacket.class, HeartbeatPacket::new);
//PacketManager.register(HeartbeatPacket.class, HeartbeatPacket::new);
PacketManager.register(ChatMessagePacket.class, ChatMessagePacket::new);
this.packetService = new PacketService(4, false, protocolVersion);
@@ -104,12 +104,6 @@ public class MessagingManager {
this.executorService.scheduleAtFixedRate(() -> {
this.packetService.queuePacket(new KeepAlivePacket(carbonChat.serverId()));
this.packetService.flushQueue();
}, 5, 10, TimeUnit.SECONDS);
// Broadcast heartbeat packets
this.executorService.scheduleAtFixedRate(() -> {
this.packetService.queuePacket(new HeartbeatPacket(carbonChat.serverId(), protocolVersion));
this.packetService.flushQueue();
}, 5, 5, TimeUnit.SECONDS);
this.executorService.scheduleAtFixedRate(() -> {