elasticSearch mapping设计

发布于:2024-04-14 ⋅ 阅读:(101) ⋅ 点赞:(0)

PUT /work_order
{
    "mappings": {
        "properties": {
            "guid": {
                "type": "keyword"
            },
            "work_order_id": {
                "type": "text"
            },
            "work_order_name": {
                "type": "text",
                "analyzer":"ik_max_word",
                "search_analyzer": "ik_smart",
                "fields" : {
                  "keyword" : {
                    "type" : "keyword",
                    "ignore_above" : 256
                  }
                }
            },
            "content": {
                "type": "text",
                "analyzer":"ik_max_word",
                "search_analyzer": "ik_smart"
            },
            "description": {
                "type": "text",
                "analyzer":"ik_max_word",
                "search_analyzer": "ik_smart"
            },
            "work_type": {
                "type": "keyword"
            },
            "work_type_name": {
                "type": "text",
                "analyzer":"ik_max_word",
                "search_analyzer": "ik_smart"
            },
            "read_status": {
                "type": "boolean"
            },
            "work_order_state": {
                "type": "keyword"
            },
            "sys_id": {
                "type": "keyword"
            },
            "proc_ins_id": {
                "type": "keyword"
            },
            "professional_category": {
                "type": "keyword"
            },
            "sponsor_id": {
                "type": "keyword"
            },
            "sponsor_name": {
                "type": "text",
                "analyzer":"ik_max_word",
                "search_analyzer": "ik_smart"
            },
            "launch_time": {
                "type": "date"
            },
            "end_time": {
                "type": "date"
            },
            "create_by": {
                "type": "text"
            },
            "create_time": {
                "type": "date"
            },
            "update_time": {
                "type": "date",
                "format": "yyyy-MM-dd HH:mm:ss||yyyy-MM-dd||epoch_millis"
            }
            ,
            "collectors":[
            ],
            "pending_persons":[
            ],
            "work_links":[
              
            ],
            "work_comments":[
              
            ] 
        }
    }
}


网站公告

今日签到

点亮在社区的每一天
去签到