curl -XGET 'localhost:9200/_nodes?filter_path=**.mlockall&pretty'
--生产环境
}'
/*id结构 uuid$序号 */
curl -XPUT 127.0.0.1:9200/fragment?pretty -d '
{
"settings" : {
"index" : {
"number_of_shards" : 3 ,
"number_of_replicas" : 0
}
},
"mappings" : {
"fragment" : {
"properties" : {
"lib_id" : {
"type" : "long"},
"text" : {}'
--netcache date为yyyyMMdd的Long类型
curl -XPUT 127.0.0.1:9200/net_cache?pretty -d '
{
"settings" : {
"index" : {
"number_of_shards" : 4,
"number_of_replicas" : 0
}
},
"mappings" : {
"net_cache" : {
"properties" : {
"result_flag" : {
"type" : "long"
},
"date" : {
"type" : "long"
},
"data" : {
"type" : "string",
"index" : "not_analyzed"
}
}
}
}
}'
--userlib
curl -XPUT 127.0.0.1:9200/user_lib?pretty -d '
{
"settings" : {
"index" : {
"number_of_shards" : 1,
"number_of_replicas" : 0
}
},
"mappings" : {
"user_lib" : {
"properties" : {
"lib_id" : {
"type" : "long"
},
"text" : {
"type" : "string",
"index" : "analyzed",
"analyzer" : "ik_max_word"
},
"org_uuid" : {
"type" : "string",
"index" : "not_analyzed"
},
"user_uuid" : {
"type" : "string",
"index" : "not_analyzed"
},
"dir_uuid" : {
"type" : "string",
"index" : "not_analyzed"
},
"auto_clear" : {
"type" : "long"
},
"timestamp" : {
"type" : "long"
},
"source" : {
"type" : "string",
"index" : "not_analyzed"
}
}
}
}
}'