<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Zero Heartbeat</title>
    <description>The latest articles on DEV Community by Zero Heartbeat (@zero_heartbeat_06a3625d7a).</description>
    <link>https://dev.to/zero_heartbeat_06a3625d7a</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3782380%2Fa9edbbf7-36b9-434e-8c5d-238ab3ad0caf.png</url>
      <title>DEV Community: Zero Heartbeat</title>
      <link>https://dev.to/zero_heartbeat_06a3625d7a</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/zero_heartbeat_06a3625d7a"/>
    <language>en</language>
    <item>
      <title>Any Language, One Store: How Zaris Speaks the Redis Protocol</title>
      <dc:creator>Zero Heartbeat</dc:creator>
      <pubDate>Thu, 27 Aug 2026 09:23:14 +0000</pubDate>
      <link>https://dev.to/zero_heartbeat_06a3625d7a/any-language-one-store-how-zaris-speaks-the-redis-protocol-2i89</link>
      <guid>https://dev.to/zero_heartbeat_06a3625d7a/any-language-one-store-how-zaris-speaks-the-redis-protocol-2i89</guid>
      <description>&lt;p&gt;Zaris is a distributed key/value store built for .NET, with its own binary protocol and native .NET clients. With 2.0.0, every Zaris node can also expose a Redis-protocol (RESP2) listener — so existing Redis clients, in any language, can connect to it without code changes.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why put a Redis face on a .NET store
&lt;/h2&gt;

&lt;p&gt;Redis has the widest client-library support of any key-value protocol. Adding RESP compatibility means polyglot teams get one replicated, highly-available store that every service can talk to today, regardless of language. The RESP front-end is opt-in and disabled by default per node.&lt;/p&gt;

&lt;h2&gt;
  
  
  The core hash is Redis-slot-aligned
&lt;/h2&gt;

&lt;p&gt;Zaris uses the same key hashing Redis Cluster uses: &lt;code&gt;CRC16(key) % 16384&lt;/code&gt;. That means cluster-aware Redis clients can route straight to the owning node, with no proxy in between:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;redis client ──CRC16(key) % 16384 → slot → owner ──▶ node that holds the key ──▶ reply
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Collections use a whole-value model
&lt;/h2&gt;

&lt;p&gt;Native data structures (hashes, lists, sets, sorted sets) go through read-modify-write with compare-and-swap semantics, so concurrent writes don't conflict across replicas.&lt;/p&gt;

&lt;h2&gt;
  
  
  Transactions run on real 2PC, not a simulation
&lt;/h2&gt;

&lt;p&gt;&lt;code&gt;MULTI&lt;/code&gt;/&lt;code&gt;EXEC&lt;/code&gt; executes on Zaris's native two-phase-commit transaction machinery rather than faking it — counter commands like &lt;code&gt;INCR&lt;/code&gt;/&lt;code&gt;DECR&lt;/code&gt; stay properly isolated inside a transaction block.&lt;/p&gt;

&lt;h2&gt;
  
  
  Three ways to fail over
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Load balancer&lt;/strong&gt; (recommended) — any node accepts any key; dead nodes just drop out of rotation.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Sentinel&lt;/strong&gt; — Zaris answers Sentinel discovery commands so clients can re-resolve.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cluster&lt;/strong&gt; — CRC16-aligned slot topology, same as Redis Cluster.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  What's in, and what's cleanly out
&lt;/h2&gt;

&lt;p&gt;Testing against StackExchange.Redis: ~126 commands supported, ~92 cleanly not supported, zero failures. Supported: core strings, collections, Streams with consumer groups, &lt;code&gt;MULTI&lt;/code&gt;/&lt;code&gt;EXEC&lt;/code&gt;/&lt;code&gt;WATCH&lt;/code&gt;, pub/sub. Not supported, by design: Lua scripting, geo commands, HyperLogLog, persistence commands — these assume infrastructure Zaris doesn't have.&lt;/p&gt;

&lt;h2&gt;
  
  
  Pin your client versions
&lt;/h2&gt;

&lt;p&gt;The listener speaks RESP2 only. Pin your Redis client library version rather than floating it, so you don't get an unexpected negotiation attempt at a newer protocol version.&lt;/p&gt;

&lt;h2&gt;
  
  
  Connecting
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;redis-cli &lt;span class="nt"&gt;-h&lt;/span&gt; node-a.internal &lt;span class="nt"&gt;-p&lt;/span&gt; 6379 SET user:42 &lt;span class="s2"&gt;"ada"&lt;/span&gt;
redis-cli &lt;span class="nt"&gt;-h&lt;/span&gt; node-a.internal &lt;span class="nt"&gt;-p&lt;/span&gt; 6379 GET user:42
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;redis&lt;/span&gt;
&lt;span class="n"&gt;r&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;redis&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nc"&gt;Redis&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;host&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;node-a.internal&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;port&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;6379&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="n"&gt;r&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;set&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;user:42&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;ada&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="nf"&gt;print&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;r&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;user:42&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight csharp"&gt;&lt;code&gt;&lt;span class="c1"&gt;// StackExchange.Redis, unchanged&lt;/span&gt;
&lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;mux&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;ConnectionMultiplexer&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;Connect&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"node-a.internal:6379"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;db&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;mux&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetDatabase&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;span class="n"&gt;db&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;StringSet&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"user:42"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"ada"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Full RESP config, the command compatibility matrix, and migration notes are in the &lt;a href="https://clustron.io/blog/redis-protocol-any-language/" rel="noopener noreferrer"&gt;docs&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>dotnet</category>
      <category>redis</category>
      <category>showdev</category>
      <category>distributedsystems</category>
    </item>
    <item>
      <title>Exploring Distributed Coordination in .NET (Clustron DKV)</title>
      <dc:creator>Zero Heartbeat</dc:creator>
      <pubDate>Sun, 08 Mar 2026 11:52:15 +0000</pubDate>
      <link>https://dev.to/zero_heartbeat_06a3625d7a/exploring-distributed-coordination-in-net-clustron-dkv-167</link>
      <guid>https://dev.to/zero_heartbeat_06a3625d7a/exploring-distributed-coordination-in-net-clustron-dkv-167</guid>
      <description>&lt;p&gt;Modern backend systems rarely run on a single machine anymore.&lt;/p&gt;

&lt;p&gt;As applications grow, we scale them horizontally — multiple service instances, worker processes, background jobs, and microservices all running concurrently across multiple nodes.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzdsebfq7rracew6heh4x.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzdsebfq7rracew6heh4x.png" alt="Clustron DKV - A .NET native Distributed Caching Solution" width="800" height="328"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;At that point the real challenge is no longer just handling requests efficiently.&lt;/p&gt;

&lt;p&gt;The real challenge becomes &lt;strong&gt;coordination&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;How do multiple services safely interact with shared state?&lt;/p&gt;

&lt;p&gt;How do we ensure that two workers don’t process the same job at the same time?&lt;/p&gt;

&lt;p&gt;How do services react to configuration changes or maintain consistent state across nodes?&lt;/p&gt;

&lt;p&gt;These problems are usually solved &lt;strong&gt;using distributed coordination primitives&lt;/strong&gt;, such as:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;distributed locks&lt;/li&gt;
&lt;li&gt;leases&lt;/li&gt;
&lt;li&gt;atomic counters&lt;/li&gt;
&lt;li&gt;watchers&lt;/li&gt;
&lt;li&gt;transactions&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Many teams implement these patterns using infrastructure systems like &lt;strong&gt;Redis&lt;/strong&gt;, distributed caching platforms such as &lt;strong&gt;NCache&lt;/strong&gt;, or coordination systems like &lt;strong&gt;etcd&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  A Small Experiment
&lt;/h2&gt;

&lt;p&gt;Over the past months I’ve been experimenting with building a distributed key-value platform designed specifically for .NET workloads.&lt;/p&gt;

&lt;p&gt;The project is called &lt;strong&gt;Clustron DKV&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;The idea is to combine distributed storage with coordination primitives so developers can build distributed systems without stitching together multiple infrastructure components.&lt;/p&gt;

&lt;p&gt;The project currently includes primitives such as:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;distributed key-value storage&lt;/li&gt;
&lt;li&gt;leases and locking&lt;/li&gt;
&lt;li&gt;atomic counters&lt;/li&gt;
&lt;li&gt;watch subscriptions&lt;/li&gt;
&lt;li&gt;distributed transactions&lt;/li&gt;
&lt;li&gt;queryable indexes&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Example Distributed Patterns
&lt;/h2&gt;

&lt;p&gt;To make the project easier to explore, I added several working samples that demonstrate common distributed system patterns.&lt;/p&gt;

&lt;p&gt;Examples include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;distributed leader election&lt;/li&gt;
&lt;li&gt;distributed job queues&lt;/li&gt;
&lt;li&gt;global rate limiting&lt;/li&gt;
&lt;li&gt;transactional state updates&lt;/li&gt;
&lt;li&gt;cluster coordination&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The goal is to make it easier for developers to experiment with coordination patterns in .NET.&lt;/p&gt;

&lt;h2&gt;
  
  
  Repository
&lt;/h2&gt;

&lt;p&gt;If you're interested in distributed systems or backend infrastructure in the .NET ecosystem, feel free to take a look:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/zeroheartbeat/clustron-dkv" rel="noopener noreferrer"&gt;https://github.com/zeroheartbeat/clustron-dkv&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The repository includes documentation, architecture notes, and working samples that demonstrate how the coordination primitives can be used.&lt;/p&gt;

&lt;h2&gt;
  
  
  Looking for Feedback
&lt;/h2&gt;

&lt;p&gt;This is still an early-stage project, and I’m especially interested in feedback from developers working on distributed systems or high-scale backend services.&lt;/p&gt;

&lt;p&gt;If you find the idea interesting or have suggestions for improvements, I’d love to hear your thoughts.&lt;/p&gt;

</description>
      <category>dotnet</category>
      <category>csharp</category>
      <category>microservices</category>
      <category>distributedsystems</category>
    </item>
  </channel>
</rss>
