ELK练习

1.ELK练习

PUT s3/_doc/1
{
    "mappings" : {
      "doc" : {
        "properties" : {
          
          "name" : {
            "type" : "text",
            "index":false,
            "fields" : {
              "keyword" : {
                "type" : "keyword",
                "ignore_above" : 256
              }
            }
          },
          
          "age" : {
            "index":false,
            "type" : "long"
          },
          
          "desc" : {
            "type" : "text",
            "fields" : {
              "keyword" : {
                "type" : "keyword",
                "ignore_above" : 128,
                "copy_to":["t1", "t2"]
              }
            }
          },
          
          "tags" : {
            "type" : "text",
            "fields" : {
              "keyword" : {
                "type" : "keyword",
                "ignore_above" : 128,
                "copy_to":["t1", "t2"]
              }
            }
          },
          
          
          "info" : {
            "properties":{
              "addr":{
                "type":"text"
              },
             "tel":{
                "type":"long"
              }
            }
          },
          

          "sex" : {
            "type" : "text",
            "fields" : {
              "keyword" : {
                "type" : "keyword",
                "ignore_above" : 256
              }
            }
          }
        }
      }
    },
    "settings": {
    "number_of_shards": 3,
    "number_of_replicas": 3
  }
}


GET s3/_doc/1
原文地址:https://www.cnblogs.com/studybrother/p/10903823.html