Skip to content

Commit aa27a6e

Browse files
committed
traslated 'Perform Quorum Reads on Replica Sets'
1 parent 849e3a1 commit aa27a6e

File tree

1 file changed

+63
-33
lines changed

1 file changed

+63
-33
lines changed

locale/zh/LC_MESSAGES/tutorial/perform-findAndModify-quorum-reads.po

Lines changed: 63 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -4,20 +4,22 @@ msgstr ""
44
"Project-Id-Version: mongodb-manual 3.2\n"
55
"Report-Msgid-Bugs-To: \n"
66
"POT-Creation-Date: 2016-05-31 19:15-0400\n"
7-
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
8-
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
9-
"Language-Team: LANGUAGE <[email protected]>\n"
7+
"PO-Revision-Date: 2016-07-02 16:16+0800\n"
108
"MIME-Version: 1.0\n"
119
"Content-Type: text/plain; charset=UTF-8\n"
1210
"Content-Transfer-Encoding: 8bit\n"
11+
"Last-Translator: Greg Huang <[email protected]>\n"
12+
"Language-Team: \n"
13+
"Language: zh_CN\n"
14+
"X-Generator: Poedit 1.8.8\n"
1315

1416
#: ../source/tutorial/perform-findAndModify-quorum-reads.txt:3
1517
msgid "Perform Quorum Reads on Replica Sets"
16-
msgstr ""
18+
msgstr "在复制集上执行Quorum投票读取"
1719

1820
#: ../source/tutorial/perform-findAndModify-quorum-reads.txt:10
1921
msgid "Overview"
20-
msgstr ""
22+
msgstr "概览"
2123

2224
#: ../source/tutorial/perform-findAndModify-quorum-reads.txt:12
2325
msgid ""
@@ -29,79 +31,107 @@ msgid ""
2931
"concern level of :readconcern:`\"majority\"` guarantees durable reads but "
3032
"may return stale data that has been overwritten by another write operation."
3133
msgstr ""
34+
"当读取复制集的主节点读取数据的时候,根据使用read conern [#edge-cases-2-"
35+
"primaries]_的级别,有可能读到的数据是过期的或者没有持久化的数据。使用read "
36+
"conern的级别为:readconcern:`\"local\"`时客户端可能在数据:term:`durable`之前"
37+
"就被读取,这就是说在这些数据为了实现容错而传播到足够多的复制集成员上之前就会"
38+
"被读到。当read concern级别为:readconcern:`\"majority\"`将保证持久化读取,但"
39+
"是有可能读到的是过期的数据,这些数据有可能已经被写操作覆盖掉了。"
3240

3341
#: ../source/tutorial/perform-findAndModify-quorum-reads.txt:21
3442
msgid ""
35-
"This tutorial outlines a procedure that uses "
36-
":method:`db.collection.findAndModify()` to read data that is not stale and "
37-
"cannot be rolled back. To do so, the procedure uses the "
38-
":method:`~db.collection.findAndModify()` method with a :ref:`write concern "
39-
"<write-concern>` to modify a dummy field in a document. Specifically, the "
40-
"procedure requires that:"
43+
"This tutorial outlines a procedure that uses :method:`db.collection."
44+
"findAndModify()` to read data that is not stale and cannot be rolled back. "
45+
"To do so, the procedure uses the :method:`~db.collection.findAndModify()` "
46+
"method with a :ref:`write concern <write-concern>` to modify a dummy field "
47+
"in a document. Specifically, the procedure requires that:"
4148
msgstr ""
49+
"本教程将概要的介绍如何使用:method:`db.collection.findAndModify()`方法读取不"
50+
"是过期的数据并且不能被回滚的过程。为了实现我们的目的,这个过程将使用通过:"
51+
"ref:`write concern <write-concern>`关键字来使用method:`~db.collection."
52+
"findAndModify()`方法来修改一个文档中虚拟的字段。这个过程特别的还需要:"
4253

4354
#: ../source/tutorial/perform-findAndModify-quorum-reads.txt:28
4455
msgid ""
45-
":method:`db.collection.findAndModify()` use an **exact** match query, and a "
46-
":doc:`unique index </core/index-unique>` **must exist** to satisfy the "
56+
":method:`db.collection.findAndModify()` use an **exact** match query, and "
57+
"a :doc:`unique index </core/index-unique>` **must exist** to satisfy the "
4758
"query."
4859
msgstr ""
60+
":method:`db.collection.findAndModify()`使用*精确*匹配查询和一个:doc:`unique "
61+
"index </core/index-unique>`**必须存在**的数据来满足查询。"
4962

5063
#: ../source/tutorial/perform-findAndModify-quorum-reads.txt:32
5164
msgid ""
52-
":method:`~db.collection.findAndModify()` must actually modify a document; "
53-
"i.e. result in a change to the document."
65+
":method:`~db.collection.findAndModify()` must actually modify a document; i."
66+
"e. result in a change to the document."
5467
msgstr ""
68+
":method:`~db.collection.findAndModify()`必须实际修改一个文档,也就是说结果一"
69+
"定会修改这个文档。"
5570

5671
#: ../source/tutorial/perform-findAndModify-quorum-reads.txt:35
5772
msgid ""
58-
":method:`~db.collection.findAndModify()` must use the write concern "
59-
":writeconcern:`{ w: \"majority\" } <\"majority\">`."
73+
":method:`~db.collection.findAndModify()` must use the write concern :"
74+
"writeconcern:`{ w: \"majority\" } <\"majority\">`."
6075
msgstr ""
76+
":method:`~db.collection.findAndModify()`必须使用write concern:writeconcern:"
77+
"`{ w: \"majority\" } <\"majority\">`。"
6178

6279
#: ../source/tutorial/perform-findAndModify-quorum-reads.txt:40
6380
msgid ""
6481
"The \"quorum read\" procedure has a substantial cost over simply using a "
6582
"read concern of :readconcern:`\"majority\"` because it incurs write latency "
66-
"rather than read latency. This technique should only be used if staleness is"
67-
" absolutely intolerable."
83+
"rather than read latency. This technique should only be used if staleness "
84+
"is absolutely intolerable."
6885
msgstr ""
86+
"“Quorum投票读取”过程会耗用比简单的使用:readconcern:`\"majority\"`的read "
87+
"concern操作更多的资源,因为它将导致写入延迟而不是读取延迟。这种技术应该只使"
88+
"用在过期数据无法容忍的场景下。"
6989

7090
#: ../source/tutorial/perform-findAndModify-quorum-reads.txt:46
7191
msgid "Prerequisites"
72-
msgstr ""
92+
msgstr "前提"
7393

7494
#: ../source/tutorial/perform-findAndModify-quorum-reads.txt:48
7595
msgid ""
7696
"This tutorial reads from a collection named ``products``. Initialize the "
7797
"collection using the following operation."
78-
msgstr ""
98+
msgstr "本教程读取一个名为``products``的集合。使用如下操作初始化这个集合。"
7999

80100
#: ../source/tutorial/perform-findAndModify-quorum-reads.txt:77
81101
msgid ""
82102
"The documents in this collection contain a dummy field named "
83-
"``_dummy_field`` that will be incremented by the "
84-
":method:`db.collection.findAndModify()` in the tutorial. If the field does "
85-
"not exist, the :method:`db.collection.findAndModify()` operation will add "
86-
"the field to the document. The purpose of the field is to ensure that the "
87-
":method:`db.collection.findAndModify()` results in a modification to the "
88-
"document."
103+
"``_dummy_field`` that will be incremented by the :method:`db.collection."
104+
"findAndModify()` in the tutorial. If the field does not exist, the :method:"
105+
"`db.collection.findAndModify()` operation will add the field to the "
106+
"document. The purpose of the field is to ensure that the :method:`db."
107+
"collection.findAndModify()` results in a modification to the document."
89108
msgstr ""
109+
"本教程中文档的集合有一个名为``_dummy_field``的虚拟字段,这个字段会使用:"
110+
"method:`db.collection.findAndModify()`进行自增。如果字段不存在:method:`db."
111+
"collection.findAndModify()`操作将在文档中增加这个字段。这个字段的目的是确保:"
112+
"method:`db.collection.findAndModify()`结果文档的修改是在一个操作中完成的。"
90113

91114
#: ../source/tutorial/perform-findAndModify-quorum-reads.txt:86
92115
msgid "Procedure"
93-
msgstr ""
116+
msgstr "步骤"
94117

95118
#: ../source/includes/footnote-two-primaries-edge-cases.rst:1
96119
msgid ""
97120
"In :ref:`some circumstances <edge-cases>`, two nodes in a replica set may "
98121
"*transiently* believe that they are the primary, but at most, one of them "
99-
"will be able to complete writes with :writeconcern:`{ w: \"majority\" } "
100-
"<\"majority\">` write concern. The node that can complete :writeconcern:`{ "
101-
"w: \"majority\" } <\"majority\">` writes is the current primary, and the "
122+
"will be able to complete writes with :writeconcern:`{ w: \"majority\" } <"
123+
"\"majority\">` write concern. The node that can complete :writeconcern:"
124+
"`{ w: \"majority\" } <\"majority\">` writes is the current primary, and the "
102125
"other node is a former primary that has not yet recognized its demotion, "
103-
"typically due to a :term:`network partition`. When this occurs, clients that"
104-
" connect to the former primary may observe stale data despite having "
126+
"typically due to a :term:`network partition`. When this occurs, clients "
127+
"that connect to the former primary may observe stale data despite having "
105128
"requested read preference :readmode:`primary`, and new writes to the former "
106129
"primary will eventually roll back."
107130
msgstr ""
131+
"在:ref:`some circumstances <edge-cases>`中,复制集中的两个节点可能会在*极短*"
132+
"的时间内都认为自己是主节点,但是至多他们中的一个可以使用writeconcern:`{ w: "
133+
"\"majority\" } <\"majority\">`完成写操作的write concern。完成:writeconcern:"
134+
"`{ w: \"majority\" } <\"majority\">`写入操作的节点将是主节点,而另外一个还没"
135+
"有意识到自己已经降级的节点,通常降级的原因是由于:term:`network partition`。"
136+
"当这种情况发生后连接到这个降级节点的客户端会发现这些数据已经不是最新的了,尽"
137+
"管请求使用了读偏好:readmode:`primary`,新写入这个前主节点的数据最终将回滚。"

0 commit comments

Comments
 (0)