Tag

reconnection

1 views collected around this technical thread.

Rare Earth Juejin Tech Community
Rare Earth Juejin Tech Community
Dec 29, 2024 · Frontend Development

Encapsulating WebSocket with Reconnection, Heartbeat, and Event Handling in JavaScript/TypeScript

This article explains how to wrap WebSocket in a reusable JavaScript/TypeScript class that provides automatic reconnection, heartbeat monitoring, event callbacks, connection state management, and graceful destruction, while also comparing WebSocket advantages over traditional HTTP polling for real‑time H5 applications.

FrontendJavaScriptTypeScript
0 likes · 14 min read
Encapsulating WebSocket with Reconnection, Heartbeat, and Event Handling in JavaScript/TypeScript
Rare Earth Juejin Tech Community
Rare Earth Juejin Tech Community
May 28, 2024 · Frontend Development

Implementing a WebSocket Client with Automatic Reconnection and Heartbeat in TypeScript/JavaScript

This article explains how to build a WebSocket client that supports automatic reconnection after network loss and periodic heartbeat messages, provides a drop‑in API compatible with the native WebSocket interface, and includes complete TypeScript and JavaScript implementations with detailed code examples.

FrontendJavaScriptTypeScript
0 likes · 19 min read
Implementing a WebSocket Client with Automatic Reconnection and Heartbeat in TypeScript/JavaScript
Rare Earth Juejin Tech Community
Rare Earth Juejin Tech Community
Apr 4, 2024 · Frontend Development

Building a WebSocket Manager for Real‑Time Message Push in JavaScript

This article demonstrates how to create a reusable WebSocket manager in JavaScript that handles connection creation, automatic heartbeat, message sending, reconnection attempts, and graceful closure, providing a complete front‑end solution for real‑time communication without relying on polling.

FrontendJavaScriptWebSocket
0 likes · 8 min read
Building a WebSocket Manager for Real‑Time Message Push in JavaScript
Code Ape Tech Column
Code Ape Tech Column
Feb 2, 2021 · Backend Development

Implementing Heartbeat and Reconnection Mechanisms with Netty in Java

This article explains the concept of TCP heartbeat, demonstrates how to use Netty's IdleStateHandler to implement client‑server heartbeat detection, and provides a complete Java example with reconnection logic, retry policies, and detailed code snippets for building a robust long‑connection service.

JavaTCPheartbeat
0 likes · 18 min read
Implementing Heartbeat and Reconnection Mechanisms with Netty in Java
Top Architect
Top Architect
Feb 1, 2021 · Backend Development

Implementing Heartbeat Mechanism and Reconnection Logic with Netty

This article explains how to implement a TCP heartbeat mechanism using Netty's IdleStateHandler, details client and server handler implementations, and demonstrates a robust reconnection strategy with customizable retry policies, providing complete Java code examples for each component.

JavaTCPheartbeat
0 likes · 19 min read
Implementing Heartbeat Mechanism and Reconnection Logic with Netty
58 Tech
58 Tech
Jun 17, 2020 · Backend Development

Hermes: A Lightweight, High‑Reliability Mobile Message Push System Based on MQTT and Protocol Buffers

The article presents Hermes, a lightweight and highly reliable mobile push system built with MQTT and Protocol Buffers, detailing its background, technology selection, architecture, heartbeat and reconnection strategies, future optimizations, and practical results that achieve over 99% message delivery rate.

Long ConnectionMQTTProtocol Buffers
0 likes · 16 min read
Hermes: A Lightweight, High‑Reliability Mobile Message Push System Based on MQTT and Protocol Buffers