課程
/云計(jì)算&大數(shù)據(jù)
/大數(shù)據(jù)
/ElasticSearch入門
求指教!謝謝!
2019-05-25
源自:ElasticSearch入門 4-1
正在回答
如上所訴,ES7.0移除了Type這個(gè)概念,所以這里有答案:
https://www.bilibili.com/video/av94512375?p=7
在ES7.0中,移除了類型(Type)這個(gè)概念。
因?yàn)樵贓lasticsearch索引中,不同類型(Type)中具有相同名稱的字段在內(nèi)部由相同的Lucene字段支持。一個(gè)index中多個(gè)Type在Lucene中會(huì)有許多問題。參考官方文檔https://www.elastic.co/guide/en/elasticsearch/reference/current/removal-of-types.html#_why_are_mapping_types_being_removed
——摘自?https://blog.csdn.net/Zereao/article/details/89378283
我找到辦法如下url更改:
127.0.0.1:9200/people/man
JSON更改:
{ "settings":{ "number_of_shards":3, "number_of_replicas":1 }, "properties":{ "name":{ "type":"text" }, "country":{ "type":"keyword" }, "age":{ "type":"integer" }, "date":{ "type":"date", "format":"yyyy-MM-dd HH:mm:ss||yyyy-MM-dd||epoch_millis" } }}
{
"settings":{
"number_of_shards":3,
"number_of_replicas":1
},
"properties":{
"name":{
"type":"text"
"country":{
"type":"keyword"
"age":{
"type":"integer"
"date":{
"type":"date",
"format":"yyyy-MM-dd HH:mm:ss||yyyy-MM-dd||epoch_millis"
}
qq_LeArn淡然_0
報(bào)錯(cuò)這個(gè)信息,什么原因?
慕少2515270
HA習(xí)慣而已 回復(fù) 慕少2515270
POST /twitter/_create/1
{}
POST /twitter/_mapping
? "properties": {
? ? "email": {
? ? ? "type": "keyword"
? ? }
? }
老師的版本較老,建議使用Kibana
我是這么處理的
根據(jù)官方文檔的示例, 先建立type
然后給type添加properties
qq_浮華塵世荒年痛_03476721
在官網(wǎng)找到了對(duì)應(yīng)的資料
https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-put-mapping.html
?在Elasticsearch?6.0.0或更高版本中創(chuàng)建的索引可能只包含單個(gè)映射類型。在具有多種映射類型的5.x中創(chuàng)建的索引將繼續(xù)像以前一樣在Elasticsearch?6.x中運(yùn)行。映射類型將在Elasticsearch?7.0.0中完全刪除。?
舉報(bào)
ElasticSearch輕松入門,Spring Boot集成ES
2 回答請(qǐng)問這個(gè)問題如何解決?謝謝!
2 回答我按照老師的做法,為什么報(bào)錯(cuò),謝謝
1 回答關(guān)于在符合查詢中提交請(qǐng)求報(bào)錯(cuò)問題,我是6.3.0 版本
4 回答postman創(chuàng)建索引時(shí)報(bào)錯(cuò),但是如果我把woman這個(gè)類型去掉的話就會(huì)創(chuàng)建成功
10 回答我用的7+版本,使用插件postman的時(shí)候,PUT提交報(bào)錯(cuò)
Copyright ? 2025 imooc.com All Rights Reserved | 京ICP備12003892號(hào)-11 京公網(wǎng)安備11010802030151號(hào)
購課補(bǔ)貼聯(lián)系客服咨詢優(yōu)惠詳情
慕課網(wǎng)APP您的移動(dòng)學(xué)習(xí)伙伴
掃描二維碼關(guān)注慕課網(wǎng)微信公眾號(hào)
2020-03-12
如上所訴,ES7.0移除了Type這個(gè)概念,所以這里有答案:
https://www.bilibili.com/video/av94512375?p=7
2020-02-24
在ES7.0中,移除了類型(Type)這個(gè)概念。
因?yàn)樵贓lasticsearch索引中,不同類型(Type)中具有相同名稱的字段在內(nèi)部由相同的Lucene字段支持。一個(gè)index中多個(gè)Type在Lucene中會(huì)有許多問題。參考官方文檔https://www.elastic.co/guide/en/elasticsearch/reference/current/removal-of-types.html#_why_are_mapping_types_being_removed
——摘自?https://blog.csdn.net/Zereao/article/details/89378283
2019-10-28
我找到辦法如下
url更改:
JSON更改:
2019-07-08
報(bào)錯(cuò)這個(gè)信息,什么原因?
2019-06-18
POST /twitter/_create/1
{}
POST /twitter/_mapping
{
? "properties": {
? ? "email": {
? ? ? "type": "keyword"
? ? }
? }
}
老師的版本較老,建議使用Kibana
2019-05-26
我是這么處理的
根據(jù)官方文檔的示例, 先建立type
然后給type添加properties
2019-05-26
在官網(wǎng)找到了對(duì)應(yīng)的資料
https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-put-mapping.html
?在Elasticsearch?6.0.0或更高版本中創(chuàng)建的索引可能只包含單個(gè)映射類型。在具有多種映射類型的5.x中創(chuàng)建的索引將繼續(xù)像以前一樣在Elasticsearch?6.x中運(yùn)行。映射類型將在Elasticsearch?7.0.0中完全刪除。?