当前位置:网站首页>Resthighlevelclient gets the mapping of an index
Resthighlevelclient gets the mapping of an index
2022-07-03 06:55:00 【Gentleman jiejie】
Reference code :
// Build request
GetMappingsRequest request = new GetMappingsRequest().indices(" Index name ");
// Use RestHighLevelClient Initiate request
GetMappingsResponse response = restHighLevelClient.indices().getMapping(request, RequestOptions.DEFAULT);
Get GetMappingsResponse After this response data , How to process and obtain the data , Reference code :
Map<String, MappingMetaData> mappingMap = response.mappings();
MappingMetaData indexMapping = mappingMap.get(" Index name ");
Map<String, Object> mapping = indexMapping.sourceAsMap();
The above is to provide a reference for use , Improve efficiency , It doesn't work , Through the above code , We can roughly obtain the required data , What to do next , Make a break , Look at the structure of the returned data , Just pick it up on demand .
边栏推荐
- 100000 bonus is divided up. Come and meet the "sister who braves the wind and waves" among the winners
- Use the jvisualvm tool ----- tocmat to start JMX monitoring
- 2022年华东师范大学计科考研复试机试题-详细题解
- Architecture notes
- 熊市里的大机构压力倍增,灰度、Tether、微策略等巨鲸会不会成为'巨雷'?
- Reading notes of "learn to ask questions"
- [Code] occasionally take values, judge blanks, look up tables, verify, etc
- 这两种驱蚊成份对宝宝有害,有宝宝的家庭,选购驱蚊产品要注意
- 【类和对象】深入浅出类和对象
- [leetcode] day93 - intersection of two arrays II
猜你喜欢
IC_ EDA_ All virtual machine (rich Edition): questasim, vivado, VCs, Verdi, DC, Pt, spyglass, icc2, synthesize, innovative, ic617, mmsim, process library
Inno Setup 制作安装包
2022 - 06 - 23 vgmp - OSPF - Inter - Domain Security Policy - nat Policy (Update)
Daily question brushing record (11)
Software testing learning - day 3
golang操作redis:写入、读取hash类型数据
VMware virtual machine C disk expansion
2022-06-23 VGMP-OSPF-域间安全策略-NAT策略(更新中)
Golang operation redis: write and read kV data
Local rviz call and display of remote rostopic
随机推荐
My 2020 summary "don't love the past, indulge in moving forward"
Operation principle of lua on C: Foundation
Hands on redis master-slave replication, sentinel master-slave switching, cluster sharding
这两种驱蚊成份对宝宝有害,有宝宝的家庭,选购驱蚊产品要注意
Integration test practice (1) theoretical basis
UTC time, GMT time, CST time
Machine learning | simple but feature standardization methods that can improve the effect of the model (comparison and analysis of robustscaler, minmaxscaler, standardscaler)
Liang Ning: 30 lectures on brain map notes for growth thinking
Mise en place d'un environnement de développement de fonctions personnalisées
Getting started with pytest
[open source project recommendation colugomum] this group of undergraduates open source retail industry solutions based on the domestic deep learning framework paddlepadddle
服务器如何设置多界面和装IIS呢?甜甜给你解答!
Software testing assignment - the next day
SQL implementation merges multiple rows of records into one row
How to migrate or replicate VMware virtual machine systems
修改MySQL密码
Derivation of variance iteration formula
MySQL installation
2022-06-23 VGMP-OSPF-域間安全策略-NAT策略(更新中)
Arctic code vault contributor