Skip to content

Commit

Permalink
gcp elasticsearch address fix
Browse files Browse the repository at this point in the history
  • Loading branch information
mjh000526 committed Jun 4, 2024
1 parent 3d56680 commit bbb6350
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,14 @@
@EnableReactiveElasticsearchRepositories(basePackageClasses = {PostContentESRespository.class, HashTagESRepository.class})
public class ElasticSearchConfig extends AbstractElasticsearchConfiguration {

@Value("${server-add}")
@Value("${elastic-server}")
private String serverAdd;

//서버에 있는 ELK연결 설정
@Override
public RestHighLevelClient elasticsearchClient() {
ClientConfiguration clientConfiguration = ClientConfiguration.builder()
.connectedTo("127.0.0.1:9200")
.connectedTo("http://"+serverAdd+":9200")
.build();
return RestClients.create(clientConfiguration).rest();
}
Expand Down

0 comments on commit bbb6350

Please sign in to comment.