<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Learning on etcd</title><link>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/</link><description>Recent content in Learning on etcd</description><generator>Hugo</generator><language>en-us</language><atom:link href="https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/index.xml" rel="self" type="application/rss+xml"/><item><title>Data model</title><link>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/data_model/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/data_model/</guid><description>&lt;p&gt;etcd is designed to reliably store infrequently updated data and provide reliable watch queries. etcd exposes previous versions of key-value pairs to support inexpensive snapshots and watch history events (“time travel queries”). A persistent, multi-version, concurrency-control data model is a good fit for these use cases.&lt;/p&gt;
&lt;p&gt;etcd stores data in a multiversion &lt;a href="https://en.wikipedia.org/wiki/Persistent_data_structure" target="_blank" rel="noopener"&gt;persistent&lt;/a&gt; key-value store. The persistent key-value store preserves the previous version of a key-value pair when its value is superseded with new data. The key-value store is effectively immutable; its operations do not update the structure in-place, but instead always generate a new updated structure. All past versions of keys are still accessible and watchable after modification. To prevent the data store from growing indefinitely over time and from maintaining old versions, the store may be compacted to shed the oldest versions of superseded data.&lt;/p&gt;</description></item><item><title>etcd client design</title><link>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/design-client/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/design-client/</guid><description>&lt;h1 id="etcd-client-design"&gt;etcd Client Design&lt;/h1&gt;
&lt;p&gt;&lt;em&gt;Gyuho Lee (github.com/gyuho, Amazon Web Services, Inc.), Joe Betz (github.com/jpbetz, Google Inc.)&lt;/em&gt;&lt;/p&gt;
&lt;h1 id="introduction"&gt;Introduction&lt;/h1&gt;
&lt;p&gt;etcd server has proven its robustness with years of failure injection testing. Most complex application logic is already handled by etcd server and its data stores (e.g. cluster membership is transparent to clients, with Raft-layer forwarding proposals to leader). Although server components are correct, its composition with client requires a different set of intricate protocols to guarantee its correctness and high availability under faulty conditions. Ideally, etcd server provides one logical cluster view of many physical machines, and client implements automatic failover between replicas. This documents client architectural decisions and its implementation details.&lt;/p&gt;</description></item><item><title>etcd learner design</title><link>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/design-learner/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/design-learner/</guid><description>&lt;h1 id="etcd-learner"&gt;etcd Learner&lt;/h1&gt;
&lt;p&gt;&lt;em&gt;Gyuho Lee (github.com/gyuho, Amazon Web Services, Inc.), Joe Betz (github.com/jpbetz, Google Inc.)&lt;/em&gt;&lt;/p&gt;
&lt;h1 id="background"&gt;Background&lt;/h1&gt;
&lt;p&gt;Membership reconfiguration has been one of the biggest operational challenges. Let’s review common challenges.&lt;/p&gt;
&lt;h3 id="1-new-cluster-member-overloads-leader"&gt;1. New Cluster member overloads Leader&lt;/h3&gt;
&lt;p&gt;A newly joined etcd member starts with no data, thus demanding more updates from leader until it catches up with leader’s logs. Then leader’s network is more likely to be overloaded, blocking or dropping leader heartbeats to followers. In such case, a follower may election-timeout to start a new leader election. That is, a cluster with a new member is more vulnerable to leader election. Both leader election and the subsequent update propagation to the new member are prone to causing periods of cluster unavailability (see &lt;em&gt;Figure 1&lt;/em&gt;).&lt;/p&gt;</description></item><item><title>etcd v3 authentication design</title><link>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/design-auth-v3/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/design-auth-v3/</guid><description>&lt;h2 id="why-not-reuse-the-v2-auth-system"&gt;Why not reuse the v2 auth system?&lt;/h2&gt;
&lt;p&gt;The v3 protocol uses gRPC as its transport instead of a RESTful interface like v2. This new protocol provides an opportunity to iterate on and improve the v2 design. For example, v3 auth has connection based authentication, rather than v2&amp;rsquo;s slower per-request authentication. Additionally, v2 auth&amp;rsquo;s semantics tend to be unwieldy in practice with respect to reasoning about consistency, which will be described in the next sections. For v3, there is a well-defined description and implementation of the authentication mechanism which fixes the deficiencies in the v2 auth system.&lt;/p&gt;</description></item><item><title>etcd API</title><link>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/api/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/api/</guid><description>&lt;p&gt;This document is meant to give an overview of the v3 etcd APIs central design.
This should not be mistaken with etcd v2 API, deprecated in etcd v3.5.
It is by no means all encompassing, but intended to focus on the basic ideas needed to understand etcd without the distraction of less common API calls.
All etcd APIs are defined in &lt;a href="https://github.com/etcd-io/etcd/blob/main/api/etcdserverpb/rpc.proto" target="_blank" rel="noopener"&gt;gRPC services&lt;/a&gt;, which categorize remote procedure calls (RPCs) understood by the etcd server.
A full listing of all etcd RPCs are documented in markdown in the &lt;a href="../../dev-guide/api_reference_v3/"&gt;gRPC API listing&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>etcd persistent storage files</title><link>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/persistent-storage-files/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/persistent-storage-files/</guid><description>&lt;p&gt;This document explains the etcd persistent storage format: naming, content and tools that allow developers to inspect them. Going forward the document should be extended with changes to the storage model. This document is targeted at etcd developers to help with their data recovery needs.&lt;/p&gt;
&lt;h2 id="prerequisites"&gt;Prerequisites&lt;/h2&gt;
&lt;p&gt;The following articles provide helpful background information for this document:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;etcd data model overview: &lt;a href="https://etcd.io/docs/v3.6/learning/data_model" target="_blank" rel="noopener"&gt;https://etcd.io/docs/v3.6/learning/data_model&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Raft overview: &lt;a href="https://raft.github.io/raft.pdf" target="_blank" rel="noopener"&gt;https://raft.github.io/raft.pdf&lt;/a&gt; (especially &amp;ldquo;5.3 Log replication&amp;rdquo; section).&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id="overview"&gt;Overview&lt;/h2&gt;
&lt;h3 id="long-leaving-files"&gt;Long leaving files&lt;/h3&gt;
&lt;table&gt;
 &lt;tr&gt;
 &lt;th&gt;File name&lt;/th&gt;
 &lt;th&gt;High level purpose&lt;/th&gt;
 &lt;/tr&gt;
 &lt;tr&gt;
 &lt;td&gt;&lt;pre&gt;./member/snap/db&lt;/pre&gt;&lt;/td&gt;
 &lt;td&gt;&lt;strong&gt;bbolt &lt;a href="https://en.wikipedia.org/wiki/B%2B_tree"&gt;b+tree&lt;/a&gt;&lt;/strong&gt; that stores all the applied data, membership authorization information &amp; metadata. It’s aware of what's the last applied WAL log index (&lt;a href="https://github.com/etcd-io/etcd/blob/a1ff0d5373335665b3e5f4cb22a538ac63757cb6/server/etcdserver/cindex/cindex.go#L92"&gt;"consistent_index"&lt;/a&gt;).
 &lt;/td&gt;
 &lt;/tr&gt;
 &lt;tr&gt;
 &lt;td&gt;&lt;pre&gt;./member/snap/0000000000000002-0000000000049425.snap
./member/snap/0000000000000002-0000000000061ace.snap&lt;/pre&gt;
 &lt;/td&gt;
 &lt;td&gt;
 &lt;p&gt;
 Periodic &lt;strong&gt;snapshots of legacy v2 store&lt;/strong&gt;, containing:
 &lt;ul&gt;
 &lt;li&gt;basic membership information&lt;/li&gt;
 &lt;li&gt;etcd-version&lt;/li&gt;
 &lt;/ul&gt;
 &lt;/p&gt;</description></item><item><title>etcd API guarantees</title><link>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/api_guarantees/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/api_guarantees/</guid><description>&lt;p&gt;etcd is a consistent and durable key value store.
The key value store is exposed through &lt;a href="../api/#grpc-services"&gt;gRPC Services&lt;/a&gt;.
etcd ensures the strongest consistency and durability guarantees for a distributed system.
This specification enumerates the API guarantees made by etcd.&lt;/p&gt;
&lt;h3 id="apis-to-consider"&gt;APIs to consider&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;KV APIs
&lt;ul&gt;
&lt;li&gt;&lt;a href="../api/#range"&gt;Range&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="../api/#put"&gt;Put&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="../api/#delete-range"&gt;Delete&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="../api/#transaction"&gt;Transaction&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Watch APIs
&lt;ul&gt;
&lt;li&gt;&lt;a href="../api/#watch-api"&gt;Watch&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Lease APIs
&lt;ul&gt;
&lt;li&gt;&lt;a href="../api/#obtaining-leases"&gt;Grant&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;[Revoke]&lt;/li&gt;
&lt;li&gt;&lt;a href="../api/#keep-alives"&gt;Keep alive&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;KV API allows for direct reading and manipulation of key value store.
Watch API allows subscribing to key value store changes.
Lease API allows assigning a time to live to a key.&lt;/p&gt;</description></item><item><title>etcd versus other key-value stores</title><link>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/why/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/why/</guid><description>&lt;p&gt;The name &amp;ldquo;etcd&amp;rdquo; originated from two ideas, the unix &amp;ldquo;/etc&amp;rdquo; folder and &amp;ldquo;d&amp;quot;istributed systems. The &amp;ldquo;/etc&amp;rdquo; folder is a place to store configuration data for a single system whereas etcd stores configuration information for large scale distributed systems. Hence, a &amp;ldquo;d&amp;quot;istributed &amp;ldquo;/etc&amp;rdquo; is &amp;ldquo;etcd&amp;rdquo;.&lt;/p&gt;
&lt;p&gt;etcd is designed as a general substrate for large scale distributed systems. These are systems that will never tolerate split-brain operation and are willing to sacrifice availability to achieve this end. etcd stores metadata in a consistent and fault-tolerant way. An etcd cluster is meant to provide key-value storage with best of class stability, reliability, scalability and performance.&lt;/p&gt;</description></item><item><title>Glossary</title><link>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/glossary/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://deploy-preview-1113--etcd.netlify.app/docs/v3.6/learning/glossary/</guid><description>&lt;p&gt;This document defines the various terms used in etcd documentation, command line and source code.&lt;/p&gt;
&lt;h2 id="alarm"&gt;Alarm&lt;/h2&gt;
&lt;p&gt;The etcd server raises an alarm whenever the cluster needs operator intervention to remain reliable.&lt;/p&gt;
&lt;h2 id="authentication"&gt;Authentication&lt;/h2&gt;
&lt;p&gt;Authentication manages user access permissions for etcd resources.&lt;/p&gt;
&lt;h2 id="client"&gt;Client&lt;/h2&gt;
&lt;p&gt;A client connects to the etcd cluster to issue service requests such as fetching key-value pairs, writing data, or watching for updates.&lt;/p&gt;
&lt;h2 id="cluster"&gt;Cluster&lt;/h2&gt;
&lt;p&gt;Cluster consists of several members.&lt;/p&gt;
&lt;p&gt;The node in each member follows raft consensus protocol to replicate logs. Cluster receives proposals from members, commits them and apply to local store.&lt;/p&gt;</description></item></channel></rss>