Skip to content

Commit 7fcac61

Browse files
authored
Merge pull request #22 from gyuho/faq
frontend: add initial '/faq' page
2 parents e9353f0 + 191c514 commit 7fcac61

File tree

3 files changed

+109
-8
lines changed

3 files changed

+109
-8
lines changed

frontend/app/doc/tip/common.component.css

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,20 @@ footer {
8787
font-size: 15px;
8888
}
8989

90+
.faq-list {
91+
color: dodgerblue;
92+
text-decoration: none !important;
93+
font-family: 'Open Sans', sans-serif;
94+
font-size: 15px;
95+
}
96+
97+
h2 .faq-title {
98+
color: dodgerblue;
99+
text-decoration: none !important;
100+
font-family: 'Open Sans', sans-serif;
101+
font-size: 20px;
102+
}
103+
90104
.versions-link-main {
91105
color: black;
92106
text-decoration: none !important;
@@ -399,4 +413,48 @@ section {
399413
section {
400414
padding: 15px 0
401415
}
416+
}
417+
418+
@media screen and (min-width: 768px) {
419+
.block.half {
420+
margin-top: 0
421+
}
422+
}
423+
424+
@media screen and (min-width: 768px) {
425+
.block-copy.half {
426+
float: left;
427+
display: block;
428+
margin-right: 4.34783%;
429+
width: 47.82609%
430+
}
431+
.block-copy.half:last-child {
432+
margin-right: 0
433+
}
434+
}
435+
436+
.block-copy p {
437+
margin-top: 30px;
438+
line-height: 1.75rem;
439+
color: #000
440+
}
441+
442+
@media screen and (min-width: 768px) {
443+
section.more-about .inner {
444+
display: table;
445+
max-width: 1100px
446+
}
447+
}
448+
449+
@media screen and (min-width: 768px) {
450+
section.more-about .inner .block-copy {
451+
float: left;
452+
display: block;
453+
margin-right: 4.34783%;
454+
width: 47.82609%;
455+
padding-right: 35px
456+
}
457+
section.more-about .inner .block-copy:last-child {
458+
margin-right: 0
459+
}
402460
}

frontend/app/doc/tip/faq.component.html

Lines changed: 50 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,55 @@ <h3 md-subheader>More</h3>
1919

2020
<div class="doc-group">
2121
<router-outlet></router-outlet>
22-
<p>Sorry, this page is still working in progress.</p>
22+
23+
<div class="inner">
24+
<div class="block block-copy half">
25+
<a href="/doc/{{version.etcdVersionURL}}/faq#cap-theorem-in-etcd" class="faq-list">CAP theorem in etcd?</a>
26+
</div>
27+
<div class="block block-copy half">
28+
<a href="/doc/{{version.etcdVersionURL}}/faq#remove-member-first" class="faq-list">Always remove first when replacing member?</a>
29+
</div>
30+
</div>
31+
32+
<br>
33+
<hr>
34+
<br>
35+
36+
<h2><a href="/doc/{{version.etcdVersionURL}}/faq#cap-theorem-in-etcd" class="faq-title">CAP theorem in etcd?</a></h2>
37+
<div id="cap-theorem-in-etcd"></div>
38+
<p>
39+
CAP often represents <i>Consistency</i>, <i>Availability</i>, <i>Partition tolerance</i>: you can only pick 2 out of 3. Since network partition is not avoidable, you are left with either consitency or availability when partition happens. That
40+
is, systems with A and P are more tolerant of network faults, but possible to serve stale data. etcd chooses C and P to achieve linearizability with strong consistency.
41+
</p>
42+
<br>
43+
44+
<h2><a href="/doc/{{version.etcdVersionURL}}/faq#remove-member-first" class="faq-title">Always remove first when replacing member?</a></h2>
45+
<div id="remove-member-first"></div>
46+
<p>
47+
When replacing an etcd node, we recommend to remove the member first and then add its replacement. etcd employs distributed consensus based on a quorum model; (n+1)/2 members, a majority, must agree on a proposal before it can be committed to the cluster.
48+
These proposals include key-value updates and membership changes. This model totally avoids any possibility of split brain inconsistency. The downside is permanent quorum loss is catastrophic.
49+
</p>
50+
<p>
51+
How this applies to membership:
52+
</p>
53+
54+
<p>
55+
If a 3-member cluster has 1 downed member, it can still make forward progress because the quorum is 2 and 2 members are still live. However, adding a new member to a 3-member cluster will increase the quorum to 3 because 3 votes are required for a majority
56+
of 4 members. Since the quorum increased, this extra member buys nothing in terms of fault tolerance; the cluster is still one node failure away from being unrecoverable.
57+
</p>
58+
59+
<p>
60+
Additionally, that new member is risky because it may turn out to be misconfigured or incapable of joining the cluster. In that case, there's no way to recover quorum because the cluster has two members down and two members up, but needs three votes to
61+
change membership to undo the botched membership addition. etcd will by default (as of last week) reject member add attempts that could take down the cluster in this manner.
62+
</p>
63+
64+
<p>
65+
On the other hand, if the downed member is removed from cluster membership first, the number of members becomes 2 and the quorum remains at 2. Following that removal by adding a new member will also keep the quorum steady at 2. So, even if the new node
66+
can't be brought up, it's still possible to remove the new member through quorum on the remaining live members.
67+
</p>
68+
<p>
69+
Reference <a href="https://github.com/coreos/etcd/issues/6114" target="_blank" class="normal-link">https://github.com/coreos/etcd/issues/6114</a>
70+
</p>
71+
<br>
2372
</div>
2473
</md-sidenav-layout>

frontend/app/home/home.component.css

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ h2 {
6060
}
6161

6262
.block+.block {
63-
margin-top: 60px
63+
margin-top: 50px
6464
}
6565

6666
@media screen and (min-width: 768px) {
@@ -119,12 +119,6 @@ h2 {
119119
}
120120
}
121121

122-
@media screen and (min-width: 768px) {
123-
section.updates .inner {
124-
max-width: 1040px
125-
}
126-
}
127-
128122
.aspect-ratio-16-9 {
129123
position: relative;
130124
width: 100%;

0 commit comments

Comments
 (0)