You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@yunikorn.apache.org by GitBox <gi...@apache.org> on 2022/12/22 06:30:42 UTC

[GitHub] [yunikorn-site] 0yukali0 commented on a diff in pull request #239: [YUNIKORN-1407] Adding Chinese translation of App Placement Rules

0yukali0 commented on code in PR #239:
URL: https://github.com/apache/yunikorn-site/pull/239#discussion_r1055122411


##########
i18n/zh-cn/docusaurus-plugin-content-docs/current/user_guide/placement_rules.md:
##########
@@ -0,0 +1,298 @@
+---
+id: placement_rules
+title: App 放置规则
+---
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+基础的放置规则在Design的[scheduler configuration design document](../design/scheduler_configuration#placement-rules-definition)中有做描述。
+
+我们可以将多个规则链结再一起形成一个放置策略,并透过[存取控制列表(Access control lists)](user_guide/acls.md)和规则过滤来定义和执行规则。
+
+本篇文章将透过例子来解释如何建立策略以及规则的使用,而该放置策略为调度器的一部分。
+
+## 配置
+规则可以在各分区中被定义,而规则的定义是「调度器队列配置」的一部分。规则定义的顺序就是他们会被执行的顺序。如果一个规则匹配,策略会停止执行剩馀的规则。
+
+当匹配一个的规则时,会产生一个完全合格的队列名称。同时这个回传的队列名称会从根队列(root)开始。而在队列层次结构中,可以生成的层次数量没有限制。
+
+当要执行一条规则时,已经被执行过的规则不会被列入考虑;这条规则也不会对往后要执行的规则有所影响:规则不能影响其他的规则,除非它们被配置为父规则([parent](#parent-参数))。
+
+当策略没有生成队列名称且没有更多的规则时,应用程式将会被拒绝。

Review Comment:
   当放置策略没有生成队列名称且没有更多的规则时,应用程式将会被拒绝



##########
i18n/zh-cn/docusaurus-plugin-content-docs/current/user_guide/placement_rules.md:
##########
@@ -0,0 +1,298 @@
+---
+id: placement_rules
+title: App 放置规则
+---
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+基础的放置规则在Design的[scheduler configuration design document](../design/scheduler_configuration#placement-rules-definition)中有做描述。
+
+我们可以将多个规则链结再一起形成一个放置策略,并透过[存取控制列表(Access control lists)](user_guide/acls.md)和规则过滤来定义和执行规则。
+
+本篇文章将透过例子来解释如何建立策略以及规则的使用,而该放置策略为调度器的一部分。
+
+## 配置
+规则可以在各分区中被定义,而规则的定义是「调度器队列配置」的一部分。规则定义的顺序就是他们会被执行的顺序。如果一个规则匹配,策略会停止执行剩馀的规则。
+
+当匹配一个的规则时,会产生一个完全合格的队列名称。同时这个回传的队列名称会从根队列(root)开始。而在队列层次结构中,可以生成的层次数量没有限制。
+
+当要执行一条规则时,已经被执行过的规则不会被列入考虑;这条规则也不会对往后要执行的规则有所影响:规则不能影响其他的规则,除非它们被配置为父规则([parent](#parent-参数))。
+
+当策略没有生成队列名称且没有更多的规则时,应用程式将会被拒绝。
+
+在配置中,定义放置规则的基本结构如下:
+```yaml
+placementrules:

Review Comment:
   - name: <第一条放置规则的名称>
   - name: <第二条放置规则的名称>



##########
i18n/zh-cn/docusaurus-plugin-content-docs/current/user_guide/placement_rules.md:
##########
@@ -0,0 +1,298 @@
+---
+id: placement_rules
+title: App 放置规则
+---
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+基础的放置规则在Design的[scheduler configuration design document](../design/scheduler_configuration#placement-rules-definition)中有做描述。
+
+我们可以将多个规则链结再一起形成一个放置策略,并透过[存取控制列表(Access control lists)](user_guide/acls.md)和规则过滤来定义和执行规则。
+
+本篇文章将透过例子来解释如何建立策略以及规则的使用,而该放置策略为调度器的一部分。
+
+## 配置
+规则可以在各分区中被定义,而规则的定义是「调度器队列配置」的一部分。规则定义的顺序就是他们会被执行的顺序。如果一个规则匹配,策略会停止执行剩馀的规则。
+
+当匹配一个的规则时,会产生一个完全合格的队列名称。同时这个回传的队列名称会从根队列(root)开始。而在队列层次结构中,可以生成的层次数量没有限制。
+
+当要执行一条规则时,已经被执行过的规则不会被列入考虑;这条规则也不会对往后要执行的规则有所影响:规则不能影响其他的规则,除非它们被配置为父规则([parent](#parent-参数))。
+
+当策略没有生成队列名称且没有更多的规则时,应用程式将会被拒绝。
+
+在配置中,定义放置规则的基本结构如下:
+```yaml
+placementrules:
+  - name: <name of the 1st rule>
+  - name: <name of the 2nd rule>
+```
+每个规则都可以在配置中採取一套预定义的参数。可以被使用的规则名称在规则描述中提及。规则名称在配置中不区分大小写,且必须遵从以下的命名惯例:
+* 从字母开始:a-z 或 A-Z
+* 后面跟着0或多个字元 a-z, A-Z, 0-9 或 _
+
+当规则名称没有对应到任何已定义的规则时,表示规则处于未知的状态,会造成放置管理器初始化错误。如果参数不正确,会抛出解析错误或在初始化时发生错误。一个有错误的规则集永远不可能被激活。
+
+如果放置管理器中含有一个被激活的规则集,就代表他已经初始化了。重新载入时,若配置了一个新的规则集时,就会将新的规则集激活,并取代旧有的。如果新规则集包含一个错误,放置管理器就会忽视这个新规则集,同时也持续处于「存取坏掉的规则集」的状态。如果放置管理器持续使用已激活的规则集,忽视新的且有错误的规则集时,则会记录一条关于坏掉且被忽视的配置信息。

Review Comment:
   存取坏掉的规则集 -> 使用不完全的规则集



##########
i18n/zh-cn/docusaurus-plugin-content-docs/current/user_guide/placement_rules.md:
##########
@@ -0,0 +1,298 @@
+---
+id: placement_rules
+title: App 放置规则
+---
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+基础的放置规则在Design的[scheduler configuration design document](../design/scheduler_configuration#placement-rules-definition)中有做描述。
+
+我们可以将多个规则链结再一起形成一个放置策略,并透过[存取控制列表(Access control lists)](user_guide/acls.md)和规则过滤来定义和执行规则。
+
+本篇文章将透过例子来解释如何建立策略以及规则的使用,而该放置策略为调度器的一部分。
+
+## 配置
+规则可以在各分区中被定义,而规则的定义是「调度器队列配置」的一部分。规则定义的顺序就是他们会被执行的顺序。如果一个规则匹配,策略会停止执行剩馀的规则。
+
+当匹配一个的规则时,会产生一个完全合格的队列名称。同时这个回传的队列名称会从根队列(root)开始。而在队列层次结构中,可以生成的层次数量没有限制。
+
+当要执行一条规则时,已经被执行过的规则不会被列入考虑;这条规则也不会对往后要执行的规则有所影响:规则不能影响其他的规则,除非它们被配置为父规则([parent](#parent-参数))。
+
+当策略没有生成队列名称且没有更多的规则时,应用程式将会被拒绝。
+
+在配置中,定义放置规则的基本结构如下:
+```yaml
+placementrules:
+  - name: <name of the 1st rule>
+  - name: <name of the 2nd rule>
+```
+每个规则都可以在配置中採取一套预定义的参数。可以被使用的规则名称在规则描述中提及。规则名称在配置中不区分大小写,且必须遵从以下的命名惯例:
+* 从字母开始:a-z 或 A-Z
+* 后面跟着0或多个字元 a-z, A-Z, 0-9 或 _
+
+当规则名称没有对应到任何已定义的规则时,表示规则处于未知的状态,会造成放置管理器初始化错误。如果参数不正确,会抛出解析错误或在初始化时发生错误。一个有错误的规则集永远不可能被激活。
+
+如果放置管理器中含有一个被激活的规则集,就代表他已经初始化了。重新载入时,若配置了一个新的规则集时,就会将新的规则集激活,并取代旧有的。如果新规则集包含一个错误,放置管理器就会忽视这个新规则集,同时也持续处于「存取坏掉的规则集」的状态。如果放置管理器持续使用已激活的规则集,忽视新的且有错误的规则集时,则会记录一条关于坏掉且被忽视的配置信息。
+
+规则结果中的「点 "."」,会被文字的「"\_dot\_"」所替代。而「点」会被取代是因为在完全限定的队列名称中,他是被用来分隔队列层次的。而替代过程是发生在建构完整队列层次,且结果合格之前。这代表我们允许用「点」来表达用户名或标籤值,但不影响到队列层次。举裡来说,当配置中的队列对应到「含有点的用户名」时,你必须要使用以下方法来指定它们:

Review Comment:
   举裡来说 -> 举例来说



##########
i18n/zh-cn/docusaurus-plugin-content-docs/current/user_guide/placement_rules.md:
##########
@@ -0,0 +1,298 @@
+---
+id: placement_rules
+title: App 放置规则
+---
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+基础的放置规则在Design的[scheduler configuration design document](../design/scheduler_configuration#placement-rules-definition)中有做描述。
+
+我们可以将多个规则链结再一起形成一个放置策略,并透过[存取控制列表(Access control lists)](user_guide/acls.md)和规则过滤来定义和执行规则。
+
+本篇文章将透过例子来解释如何建立策略以及规则的使用,而该放置策略为调度器的一部分。
+
+## 配置
+规则可以在各分区中被定义,而规则的定义是「调度器队列配置」的一部分。规则定义的顺序就是他们会被执行的顺序。如果一个规则匹配,策略会停止执行剩馀的规则。
+
+当匹配一个的规则时,会产生一个完全合格的队列名称。同时这个回传的队列名称会从根队列(root)开始。而在队列层次结构中,可以生成的层次数量没有限制。
+
+当要执行一条规则时,已经被执行过的规则不会被列入考虑;这条规则也不会对往后要执行的规则有所影响:规则不能影响其他的规则,除非它们被配置为父规则([parent](#parent-参数))。
+
+当策略没有生成队列名称且没有更多的规则时,应用程式将会被拒绝。
+
+在配置中,定义放置规则的基本结构如下:
+```yaml
+placementrules:
+  - name: <name of the 1st rule>
+  - name: <name of the 2nd rule>
+```
+每个规则都可以在配置中採取一套预定义的参数。可以被使用的规则名称在规则描述中提及。规则名称在配置中不区分大小写,且必须遵从以下的命名惯例:

Review Comment:
   规则 link is missing



##########
i18n/zh-cn/docusaurus-plugin-content-docs/current/user_guide/placement_rules.md:
##########
@@ -0,0 +1,298 @@
+---
+id: placement_rules
+title: App 放置规则
+---
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+基础的放置规则在Design的[scheduler configuration design document](../design/scheduler_configuration#placement-rules-definition)中有做描述。
+
+我们可以将多个规则链结再一起形成一个放置策略,并透过[存取控制列表(Access control lists)](user_guide/acls.md)和规则过滤来定义和执行规则。
+
+本篇文章将透过例子来解释如何建立策略以及规则的使用,而该放置策略为调度器的一部分。
+
+## 配置
+规则可以在各分区中被定义,而规则的定义是「调度器队列配置」的一部分。规则定义的顺序就是他们会被执行的顺序。如果一个规则匹配,策略会停止执行剩馀的规则。

Review Comment:
   放置规则作为调度程序队列配置的一部分,可以在各分区(partition)中被定义。



##########
i18n/zh-cn/docusaurus-plugin-content-docs/current/user_guide/placement_rules.md:
##########
@@ -0,0 +1,298 @@
+---
+id: placement_rules
+title: App 放置规则
+---
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+基础的放置规则在Design的[scheduler configuration design document](../design/scheduler_configuration#placement-rules-definition)中有做描述。
+
+我们可以将多个规则链结再一起形成一个放置策略,并透过[存取控制列表(Access control lists)](user_guide/acls.md)和规则过滤来定义和执行规则。
+
+本篇文章将透过例子来解释如何建立策略以及规则的使用,而该放置策略为调度器的一部分。
+
+## 配置
+规则可以在各分区中被定义,而规则的定义是「调度器队列配置」的一部分。规则定义的顺序就是他们会被执行的顺序。如果一个规则匹配,策略会停止执行剩馀的规则。
+
+当匹配一个的规则时,会产生一个完全合格的队列名称。同时这个回传的队列名称会从根队列(root)开始。而在队列层次结构中,可以生成的层次数量没有限制。
+
+当要执行一条规则时,已经被执行过的规则不会被列入考虑;这条规则也不会对往后要执行的规则有所影响:规则不能影响其他的规则,除非它们被配置为父规则([parent](#parent-参数))。
+
+当策略没有生成队列名称且没有更多的规则时,应用程式将会被拒绝。
+
+在配置中,定义放置规则的基本结构如下:
+```yaml
+placementrules:
+  - name: <name of the 1st rule>
+  - name: <name of the 2nd rule>
+```
+每个规则都可以在配置中採取一套预定义的参数。可以被使用的规则名称在规则描述中提及。规则名称在配置中不区分大小写,且必须遵从以下的命名惯例:
+* 从字母开始:a-z 或 A-Z
+* 后面跟着0或多个字元 a-z, A-Z, 0-9 或 _
+
+当规则名称没有对应到任何已定义的规则时,表示规则处于未知的状态,会造成放置管理器初始化错误。如果参数不正确,会抛出解析错误或在初始化时发生错误。一个有错误的规则集永远不可能被激活。
+
+如果放置管理器中含有一个被激活的规则集,就代表他已经初始化了。重新载入时,若配置了一个新的规则集时,就会将新的规则集激活,并取代旧有的。如果新规则集包含一个错误,放置管理器就会忽视这个新规则集,同时也持续处于「存取坏掉的规则集」的状态。如果放置管理器持续使用已激活的规则集,忽视新的且有错误的规则集时,则会记录一条关于坏掉且被忽视的配置信息。
+
+规则结果中的「点 "."」,会被文字的「"\_dot\_"」所替代。而「点」会被取代是因为在完全限定的队列名称中,他是被用来分隔队列层次的。而替代过程是发生在建构完整队列层次,且结果合格之前。这代表我们允许用「点」来表达用户名或标籤值,但不影响到队列层次。举裡来说,当配置中的队列对应到「含有点的用户名」时,你必须要使用以下方法来指定它们:
+
+如果一个用户名称为`user.name`且使用`user`规则,则会产生队列名称为`root.user_dot_name`的队列。而如果该用户队列必须事先被加到配置中,则也该使用`user_dot_name`这个名字。
+
+### Create 参数
+create 参数是一个布林值,会定义当一个队列不存在时,是否可以在规则的定义下创建队列。不能保证队列一定会被创建,因为现有的队列可能会阻止创建。但如果规则定义下想创建的队列不存在,且`create: false`,那结果将会是创建失败。
+
+带有`create`参数的简易yaml范例:
+```yaml
+placementrules:
+  - name: <name of the rule>
+    create: true
+```
+预设值为`false`。允许的值为`true`或`false`,其他值均会导致显示错误
+
+### Parent 参数
+`parent` 参数允许指定一个规则,并为他产生一个父队列。父规则可以被嵌套,一个父规则可以包含另一个父规则,此外对于父规则的嵌套也没有强制限制。
+
+父规则被视为顶层的规则,因此具有与放置定义中任何其他规则相同的参数和需求。例外的情况是,在「已经生成完全合格队列」的规则上再使用父规则,被认为是一个配置错误。这个错误只能发生在`fixed`型的规则上,查看规范可以得到更多细节。
+
+注意:规则的执行会沿着父规则的列表向下遍历,并首先执行列表中的最后一条。代表最后一条父规则将会直接产生在根部,详见示例。
+
+带有`parent`参数的简易yaml范例:
+```yaml
+placementrules:
+  - name: <name of the rule>

Review Comment:
   放置规则的名称



##########
i18n/zh-cn/docusaurus-plugin-content-docs/current/user_guide/placement_rules.md:
##########
@@ -0,0 +1,298 @@
+---
+id: placement_rules
+title: App 放置规则
+---
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+基础的放置规则在Design的[scheduler configuration design document](../design/scheduler_configuration#placement-rules-definition)中有做描述。
+
+我们可以将多个规则链结再一起形成一个放置策略,并透过[存取控制列表(Access control lists)](user_guide/acls.md)和规则过滤来定义和执行规则。
+
+本篇文章将透过例子来解释如何建立策略以及规则的使用,而该放置策略为调度器的一部分。
+
+## 配置
+规则可以在各分区中被定义,而规则的定义是「调度器队列配置」的一部分。规则定义的顺序就是他们会被执行的顺序。如果一个规则匹配,策略会停止执行剩馀的规则。
+
+当匹配一个的规则时,会产生一个完全合格的队列名称。同时这个回传的队列名称会从根队列(root)开始。而在队列层次结构中,可以生成的层次数量没有限制。
+
+当要执行一条规则时,已经被执行过的规则不会被列入考虑;这条规则也不会对往后要执行的规则有所影响:规则不能影响其他的规则,除非它们被配置为父规则([parent](#parent-参数))。
+
+当策略没有生成队列名称且没有更多的规则时,应用程式将会被拒绝。
+
+在配置中,定义放置规则的基本结构如下:
+```yaml
+placementrules:
+  - name: <name of the 1st rule>
+  - name: <name of the 2nd rule>
+```
+每个规则都可以在配置中採取一套预定义的参数。可以被使用的规则名称在规则描述中提及。规则名称在配置中不区分大小写,且必须遵从以下的命名惯例:
+* 从字母开始:a-z 或 A-Z
+* 后面跟着0或多个字元 a-z, A-Z, 0-9 或 _
+
+当规则名称没有对应到任何已定义的规则时,表示规则处于未知的状态,会造成放置管理器初始化错误。如果参数不正确,会抛出解析错误或在初始化时发生错误。一个有错误的规则集永远不可能被激活。
+
+如果放置管理器中含有一个被激活的规则集,就代表他已经初始化了。重新载入时,若配置了一个新的规则集时,就会将新的规则集激活,并取代旧有的。如果新规则集包含一个错误,放置管理器就会忽视这个新规则集,同时也持续处于「存取坏掉的规则集」的状态。如果放置管理器持续使用已激活的规则集,忽视新的且有错误的规则集时,则会记录一条关于坏掉且被忽视的配置信息。
+
+规则结果中的「点 "."」,会被文字的「"\_dot\_"」所替代。而「点」会被取代是因为在完全限定的队列名称中,他是被用来分隔队列层次的。而替代过程是发生在建构完整队列层次,且结果合格之前。这代表我们允许用「点」来表达用户名或标籤值,但不影响到队列层次。举裡来说,当配置中的队列对应到「含有点的用户名」时,你必须要使用以下方法来指定它们:
+
+如果一个用户名称为`user.name`且使用`user`规则,则会产生队列名称为`root.user_dot_name`的队列。而如果该用户队列必须事先被加到配置中,则也该使用`user_dot_name`这个名字。
+
+### Create 参数
+create 参数是一个布林值,会定义当一个队列不存在时,是否可以在规则的定义下创建队列。不能保证队列一定会被创建,因为现有的队列可能会阻止创建。但如果规则定义下想创建的队列不存在,且`create: false`,那结果将会是创建失败。
+
+带有`create`参数的简易yaml范例:
+```yaml
+placementrules:
+  - name: <name of the rule>
+    create: true
+```
+预设值为`false`。允许的值为`true`或`false`,其他值均会导致显示错误
+
+### Parent 参数
+`parent` 参数允许指定一个规则,并为他产生一个父队列。父规则可以被嵌套,一个父规则可以包含另一个父规则,此外对于父规则的嵌套也没有强制限制。
+
+父规则被视为顶层的规则,因此具有与放置定义中任何其他规则相同的参数和需求。例外的情况是,在「已经生成完全合格队列」的规则上再使用父规则,被认为是一个配置错误。这个错误只能发生在`fixed`型的规则上,查看规范可以得到更多细节。
+
+注意:规则的执行会沿着父规则的列表向下遍历,并首先执行列表中的最后一条。代表最后一条父规则将会直接产生在根部,详见示例。
+
+带有`parent`参数的简易yaml范例:
+```yaml
+placementrules:
+  - name: <name of the rule>
+    parent:
+      name: <name of the parent rule>

Review Comment:
   父规则的名称



##########
i18n/zh-cn/docusaurus-plugin-content-docs/current/user_guide/placement_rules.md:
##########
@@ -0,0 +1,298 @@
+---
+id: placement_rules
+title: App 放置规则
+---
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+基础的放置规则在Design的[scheduler configuration design document](../design/scheduler_configuration#placement-rules-definition)中有做描述。

Review Comment:
   基础的放置规则(placement rules)配置在[调度器配置设计文档](../design/scheduler_configuration#placement-rules-definition)中有相关描述。



##########
i18n/zh-cn/docusaurus-plugin-content-docs/current/user_guide/placement_rules.md:
##########
@@ -0,0 +1,298 @@
+---
+id: placement_rules
+title: App 放置规则
+---
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+基础的放置规则在Design的[scheduler configuration design document](../design/scheduler_configuration#placement-rules-definition)中有做描述。
+
+我们可以将多个规则链结再一起形成一个放置策略,并透过[存取控制列表(Access control lists)](user_guide/acls.md)和规则过滤来定义和执行规则。
+
+本篇文章将透过例子来解释如何建立策略以及规则的使用,而该放置策略为调度器的一部分。
+
+## 配置
+规则可以在各分区中被定义,而规则的定义是「调度器队列配置」的一部分。规则定义的顺序就是他们会被执行的顺序。如果一个规则匹配,策略会停止执行剩馀的规则。
+
+当匹配一个的规则时,会产生一个完全合格的队列名称。同时这个回传的队列名称会从根队列(root)开始。而在队列层次结构中,可以生成的层次数量没有限制。

Review Comment:
   匹配的放置规则会产生一个完全合格的队列名称。



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@yunikorn.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org