← Retour au fil
Helius déploie ses Enhanced WebSockets de nouvelle génération sur Solana
Helius16 oct., 16h · il y a 9 mois

Helius déploie ses Enhanced WebSockets de nouvelle génération sur Solana

Helius dote ses Enhanced WebSockets sur Solana de l'infrastructure LaserStream pour offrir une fiabilité de niveau gRPC aux applications front-end.

Le streaming de données sur Solana souffrait des limites des WebSockets standards, comme les déconnexions aléatoires et le manque de filtrage. Pour pallier cela, Helius met à niveau ses Enhanced WebSockets via l'infrastructure LaserStream, alliant la fiabilité du gRPC à un format JSON natif pour les navigateurs et applications mobiles.

Cette architecture multi-nœuds garantit une résilience optimale et des notifications ultra-rapides avec bascules automatiques. Helius destine ces flux à l'expérience utilisateur front-end, réservant LaserStream aux backends critiques où chaque milliseconde impacte les gains, et Shred Delivery aux signaux bruts.

Solana

Détails

Source
Helius
Publication
16 oct. à 16h10

Contenu source (brut)

<p>Real-time data streaming is essential for building responsive applications on Solana. WebSockets have long been the go-to protocol for enabling persistent, bidirectional communication, replacing inefficient HTTP polling with a single connection.</p><p>While WebSockets are ideal over traditional HTTP polling, they introduce a host of challenges that can undermine reliability, which is detrimental in high-throughput environments such as Solana. Issues ranging from random disconnects to inadequate filtering have historically compelled developers to dedicate significant time and effort to custom mitigations, often at the expense of core product innovation.</p><p>At Helius, we’ve long recognized these pain points. In the past, we introduced <a href="https://www.helius.dev/docs/enhanced-websockets"><span style="text-decoration: underline">Enhanced WebSockets</span></a>, a faster and more customizable option for streaming transaction and account updates. Yet, as our infrastructure evolved, it became clear that even these enhancements still fall short of the resilience and performance possible with Helius.</p><p>We’re excited to announce that Enhanced WebSockets are now powered by the same infrastructure that powers <a href="https://www.helius.dev/laserstream"><span style="text-decoration: underline">LaserStream</span></a>, our next-gen gRPC streaming service built for speed, simplicity, and fault-tolerance. </p><p>This integration provides gRPC-level reliability to WebSocket streams in a JSON-native format, eliminates fragile connections, and enables frontend developers to focus on <em>delivering the best UX possible</em>.</p><h2>The Challenges of WebSockets and Real-time Applications</h2><p>WebSockets promise persistent, bidirectional magic—a single connection for push notifications in place of continually polling HTTP endpoints. While this sounds nice, WebSockets aren’t without issues:</p><h3>1. Connection Fragility and Heavy Load</h3><p>WebSockets maintain stateful, long-lived TCP connections. This makes them susceptible to interruptions due to network blips, proxy timeouts, or overloaded servers. </p><p>Solana’s 400ms slot times and bursty traffic amplify WebSocket vulnerabilities. Thus, developers are forced to implement custom reconnection logic, such as exponential backoffs and heartbeat pings, to maintain uptime.</p><h3>2. Data Flooding</h3><p>WebSocket subscriptions often return <em>too much data</em>. </p><p>Native subscriptions, such as <a href="https://www.helius.dev/docs/api-reference/rpc/websocket/accountsubscribe"><code>accountSubscribe</code></a>,<strong> </strong>deliver unfiltered streams, overwhelming developers with noise. This forces developers to filter on the client side, which can increase bandwidth usage and introduce processing delays.</p><h3>3. Scalability and Resource Overhead</h3><p>Handling thousands of concurrent connections strains server resources, leading to memory leaks, CPU bottlenecks, increased load balancer complexity, and the need for sharding connections to manage load. </p><p>Scaling WebSockets horizontally is notoriously difficult, and not something most teams have the time, resources, or expertise to perfect. </p><h3>4. Developer Time Siphoned from Product Innovation</h3><p>Collectively, these challenges take away cycles from building new, differentiated features and applications. This inefficiency is a hidden tax on progress in Solana’s fast-moving landscape.</p><p>These persistent challenges render <a href="https://www.helius.dev/docs/api-reference/rpc/websocket-methods"><span style="text-decoration: underline">standard Solana WebSockets</span></a> inadequate for production-grade applications, where even the most brief disruptions can mean missed opportunities or stale UIs.</p><h2>Next-Generation Enhanced WebSockets</h2><p>We introduced Enhanced WebSockets—a Geyser-enhanced version of Solana’s standard WebSockets for better account and transaction subscriptions—to address these gaps. </p><p>It introduced powerful filters (e.g., up to 50,000 addresses via <code>accountInclude</code><strong>,</strong> <code>accountExclude</code><strong>,</strong> and <code>accountRequired</code>) and faster response times than traditional WebSockets. However, our data streaming infrastructure has improved since its original launch.</p><p>Enhanced WebSockets are now powered by the same infrastructure as LaserStream—our <a href="[object Object]">next-generation gRPC streaming service</a>, built for speed, reliability, and simplicity. </p><p>Now, experience gRPC reliability in a WebSocket wrapper.</p><p>Key enhancements include:</p><h3>Best-in-Class Resilience</h3><p>Enhanced WebSockets now stream from multiple aggregated nodes simultaneously with automatic failovers, increasing resilience by removing any single points of failure and ensuring maximum uptime.</p><h3>High Performance</h3><p>LaserStream is purpose-built for ultra-low-latency data streaming, and now, Enhanced WebSockets will benefit from our latest improvements for the fastest notifications possible.</p><h3>Frontend-Optimized Streams</h3><p>The JSON payloads of Enhanced WebSockets, backed by upgraded infrastructure, empower frontend developers to integrate high-fidelity streams directly into browsers, React apps, and mobile clients.</p><h2>Choosing the Right Streaming Solution: A Comparison</h2><p>At Helius, we have different data streaming services built for specific use cases, which we’ve outlined below. </p><h3>Enhanced WebSockets</h3><p>Developers should <a href="https://www.helius.dev/docs/enhanced-websockets">use Enhanced WebSockets</a> when:</p><ol class="list-number"><li value=1>Latency, continuity, and correctness do not affect PnL, fills, or risk</li><li value=2>When you want JSON payloads</li><li value=3>Your focus is on consumer UX without backend complexity</li></ol><span>unknown node</span><h3>LaserStream</h3><p>Developers should <a href="https://www.helius.dev/docs/laserstream">use LaserStream</a> when:</p><ol class="list-number"><li value=1>Every millisecond matters</li><li value=2>Latency, continuity, and correctness affect PnL, fills, and/or risk</li><li value=3>You need more advanced filtering capabilities</li><li value=4>You need gapless delivery with automatic replay</li><li value=5>You need to receive transactions at various commitment levels</li></ol><span>unknown node</span><p><p>Request a <a href="https://form.typeform.com/to/W6HeES3S" rel="noopener noreferrer" target="_blank">free trial</a> to see if LaserStream is right for you.</p></p><h3>Shred Delivery</h3><p>Developers should use <a href="https://www.helius.dev/docs/shred-delivery">Shred Delivery</a> when:</p><ol class="list-number"><li value=1>You need raw signals</li><li value=2>Have, or can build out, a custom deshredding pipeline</li></ol><span>unknown node</span><p>In summary:</p><ul class="list-bullet"><li value=1>Use Enhanced Websockets for frontend-friendly, non-critical streams.</li><li value=2>Use LaserStream for backend decision loops where latency gaps or data continuity directly impact opportunities.</li><li value=3>Use Shred Delivery when you’re using a custom deshredding pipeline for the earliest signals from raw shreds.</li></ul><p><p>Request a <a href="https://www.helius.dev/shreds-contact" rel="noopener noreferrer" target="_blank">free trial</a> to see if Shred Delivery is right for you.</p></p><p></p><h2>Enhanced WebSockets Quickstart</h2><p>Getting started with Enhanced WebSockets is straightforward. </p><p>To start, <a href="https://dashboard.helius.dev/signup?redirectTo=onboarding"><span style="text-decoration: underline">sign up</span></a> and get an API key in the “API Keys” section. </p><p>Simply connect to one of our endpoints, subscribe via <code>transactionSubscribe</code><strong> </strong>or <code>accountSubscribe</code>, and start receiving filtered, resilient streams. </p><p><p>Enhanced WebSockets are available for <a href="https://www.helius.dev/docs/bill