"Fossies" - the Fresh Open Source Software Archive

Member "elasticsearch-6.8.23/rest-api-spec/src/main/resources/rest-api-spec/test/cat.fielddata/10_basic.yml" (29 Dec 2021, 1412 Bytes) of package /linux/www/elasticsearch-6.8.23-src.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Ansible YAML source code syntax highlighting (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 ---
    2 "Help":
    3   - do:
    4       cat.fielddata:
    5         help: true
    6 
    7   - match:
    8       $body: |
    9                /^  id .+ \n
   10                    host .+ \n
   11                    ip .+ \n
   12                    node .+ \n
   13                    field .+ \n
   14                    size .+ \n
   15                $/
   16 
   17 ---
   18 "Test cat fielddata output":
   19 
   20   - do:
   21       cat.fielddata: {}
   22 
   23   - do:
   24       indices.create:
   25         index:  index
   26         body:
   27           settings:
   28             number_of_shards: "1"
   29           mappings:
   30             type:
   31               properties:
   32                 foo:
   33                   type: text
   34                   fielddata: true
   35 
   36   - do:
   37       index:
   38         index: index
   39         type: type
   40         body: { foo: bar }
   41         refresh: true
   42 
   43   - do:
   44       search:
   45         index: index
   46         body:
   47           query: { match_all: {} }
   48           sort: foo
   49 
   50   - do:
   51       cat.fielddata:
   52         h: field,size
   53         v: true
   54 
   55   - match:
   56       $body: |
   57                /^ field \s+   size \n
   58                   foo     \s+ (\d+(\.\d+)?[gmk]?b  \n)+ $/
   59 
   60   - do:
   61       cat.fielddata:
   62         h: field,size
   63         fields: notfoo,foo
   64         v: true
   65 
   66   - match:
   67       $body: |
   68                /^ field \s+   size \n
   69                   foo     \s+ (\d+(\.\d+)?[gmk]?b  \n)+ $/
   70 
   71   - do:
   72       cat.fielddata:
   73         h: field,size
   74         fields: notfoo
   75         v: true
   76 
   77   - match:
   78       $body: |
   79                /^ field \s+   size \n $/