ElasticsearchClient 7.17.7 기준 java client example code
2022. 11. 28.
1) host, port 주입 RestClient restClient = RestClient.builder( new HttpHost("localhost", 9200, "http"), new HttpHost("localhost", 9201, "http")).build(); BulkRequest.Builder br = new BulkRequest.Builder(); ElasticsearchTransport transport = new RestClientTransport(restClient, new JacksonJsonpMapper()); ElasticsearchClient esClient = new ElasticsearchClient(transport); 2) String으로 된 JSON 데이터 정의 Str..