فهرست منبع

Convert more docs to CONSOLE

* plugins/discovery-azure-class.asciidoc
* reference/cluster.asciidoc
* reference/modules/cluster/misc.asciidoc
* reference/modules/indices/request_cache.asciidoc

After this is merged there will be no unconvereted snippets outside
of `reference`.

Related to #18160
Nik Everett 9 سال پیش
والد
کامیت
3ed3e5e660

+ 0 - 4
docs/build.gradle

@@ -24,7 +24,6 @@ apply plugin: 'elasticsearch.docs-test'
  * only remove entries from this list. When it is empty we'll remove it
  * entirely and have a party! There will be cake and everything.... */
 buildRestTests.expectedUnconvertedCandidates = [
-  'plugins/discovery-azure-classic.asciidoc',
   'reference/aggregations.asciidoc',
   'reference/aggregations/bucket/children-aggregation.asciidoc',
   'reference/aggregations/bucket/datehistogram-aggregation.asciidoc',
@@ -115,7 +114,6 @@ buildRestTests.expectedUnconvertedCandidates = [
   'reference/cat/snapshots.asciidoc',
   'reference/cat/templates.asciidoc',
   'reference/cat/thread_pool.asciidoc',
-  'reference/cluster.asciidoc',
   'reference/cluster/allocation-explain.asciidoc',
   'reference/cluster/nodes-info.asciidoc',
   'reference/cluster/nodes-stats.asciidoc',
@@ -161,8 +159,6 @@ buildRestTests.expectedUnconvertedCandidates = [
   'reference/mapping/types/nested.asciidoc',
   'reference/mapping/types/object.asciidoc',
   'reference/mapping/types/percolator.asciidoc',
-  'reference/modules/cluster/misc.asciidoc',
-  'reference/modules/indices/request_cache.asciidoc',
   'reference/modules/scripting/native.asciidoc',
   'reference/modules/scripting/security.asciidoc',
   'reference/modules/scripting/using.asciidoc',

+ 1 - 0
docs/plugins/discovery-azure-classic.asciidoc

@@ -378,6 +378,7 @@ curl -s https://download.elasticsearch.org/elasticsearch/elasticsearch/elasticse
 # Prepare Elasticsearch installation
 sudo dpkg -i elasticsearch-{version}.deb
 ----
+// NOTCONSOLE
 
 Check that elasticsearch is running:
 

+ 9 - 8
docs/reference/cluster.asciidoc

@@ -15,18 +15,19 @@ example, here are some sample executions of nodes info:
 [source,js]
 --------------------------------------------------
 # Local
-curl localhost:9200/_nodes/_local
+GET /_nodes/_local
 # Address
-curl localhost:9200/_nodes/10.0.0.3,10.0.0.4
-curl localhost:9200/_nodes/10.0.0.*
+GET /_nodes/10.0.0.3,10.0.0.4
+GET /_nodes/10.0.0.*
 # Names
-curl localhost:9200/_nodes/node_name_goes_here
-curl localhost:9200/_nodes/node_name_goes_*
+GET /_nodes/node_name_goes_here
+GET /_nodes/node_name_goes_*
 # Attributes (set something like node.attr.rack: 2 in the config)
-curl localhost:9200/_nodes/rack:2
-curl localhost:9200/_nodes/ra*:2
-curl localhost:9200/_nodes/ra*:2*
+GET /_nodes/rack:2
+GET /_nodes/ra*:2
+GET /_nodes/ra*:2*
 --------------------------------------------------
+// CONSOLE
 --
 
 include::cluster/health.asciidoc[]

+ 9 - 9
docs/reference/modules/cluster/misc.asciidoc

@@ -20,18 +20,18 @@ API can make the cluster read-write again.
 [[cluster-max-tombstones]]
 ==== Index Tombstones
 
-The cluster state maintains index tombstones to explicitly denote indices that 
-have been deleted.  The number of tombstones maintained in the cluster state is 
+The cluster state maintains index tombstones to explicitly denote indices that
+have been deleted.  The number of tombstones maintained in the cluster state is
 controlled by the following property, which cannot be updated dynamically:
 
 `cluster.indices.tombstones.size`::
 
-Index tombstones prevent nodes that are not part of the cluster when a delete 
-occurs from joining the cluster and reimporting the index as though the delete 
-was never issued. To keep the cluster state from growing huge we only keep the 
-last `cluster.indices.tombstones.size` deletes, which defaults to 500. You can 
-increase it if you expect nodes to be absent from the cluster and miss more 
-than 500 deletes. We think that is rare, thus the default. Tombstones don't take 
+Index tombstones prevent nodes that are not part of the cluster when a delete
+occurs from joining the cluster and reimporting the index as though the delete
+was never issued. To keep the cluster state from growing huge we only keep the
+last `cluster.indices.tombstones.size` deletes, which defaults to 500. You can
+increase it if you expect nodes to be absent from the cluster and miss more
+than 500 deletes. We think that is rare, thus the default. Tombstones don't take
 up much space, but we also think that a number like 50,000 is probably too big.
 
 [[cluster-logger]]
@@ -50,4 +50,4 @@ PUT /_cluster/settings
   }
 }
 -------------------------------
-
+// CONSOLE

+ 16 - 9
docs/reference/modules/indices/request_cache.asciidoc

@@ -42,8 +42,10 @@ The cache can be expired manually with the <<indices-clearcache,`clear-cache` AP
 
 [source,js]
 ------------------------
-curl -XPOST 'localhost:9200/kimchy,elasticsearch/_cache/clear?request_cache=true'
+POST /kimchy,elasticsearch/_cache/clear?request_cache=true
 ------------------------
+// CONSOLE
+// TEST[s/^/PUT kimchy\nPUT elasticsearch\n/]
 
 [float]
 ==== Enabling and disabling caching
@@ -53,24 +55,26 @@ index as follows:
 
 [source,js]
 -----------------------------
-curl -XPUT localhost:9200/my_index -d'
+PUT /my_index
 {
   "settings": {
     "index.requests.cache.enable": false
   }
 }
-'
 -----------------------------
+// CONSOLE
 
 It can also be enabled or disabled dynamically on an existing index with the
 <<indices-update-settings,`update-settings`>> API:
 
 [source,js]
 -----------------------------
-curl -XPUT localhost:9200/my_index/_settings -d'
+PUT /my_index/_settings
 { "index.requests.cache.enable": true }
-'
 -----------------------------
+// CONSOLE
+// TEST[continued]
+
 
 [float]
 ==== Enabling and disabling caching per request
@@ -80,7 +84,7 @@ caching on a *per-request* basis.  If set, it overrides the index-level setting:
 
 [source,js]
 -----------------------------
-curl 'localhost:9200/my_index/_search?request_cache=true' -d'
+GET /my_index/_search?request_cache=true
 {
   "size": 0,
   "aggs": {
@@ -91,8 +95,9 @@ curl 'localhost:9200/my_index/_search?request_cache=true' -d'
     }
   }
 }
-'
 -----------------------------
+// CONSOLE
+// TEST[continued]
 
 IMPORTANT: If your query uses a script whose result is not deterministic (e.g.
 it uses a random function or references the current time) you should set the
@@ -137,12 +142,14 @@ by index, with the <<indices-stats,`indices-stats`>> API:
 
 [source,js]
 ------------------------
-curl 'localhost:9200/_stats/request_cache?pretty&human'
+GET /_stats/request_cache?human
 ------------------------
+// CONSOLE
 
 or by node with the <<cluster-nodes-stats,`nodes-stats`>> API:
 
 [source,js]
 ------------------------
-curl 'localhost:9200/_nodes/stats/indices/request_cache?pretty&human'
+GET /_nodes/stats/indices/request_cache?human
 ------------------------
+// CONSOLE