mirror of
https://github.com/elastic/elasticsearch.git
synced 2025-04-25 23:57:20 -04:00
[DOCS] Fix Java API TransportClient example
This commit is contained in:
parent
ad3234d475
commit
efa39a0eb0
1 changed files with 2 additions and 2 deletions
|
@ -152,8 +152,8 @@ be "two hop" operations).
|
|||
// on startup
|
||||
|
||||
Client client = TransportClient.builder().build()
|
||||
.addTransportAddress(new InetSocketTransportAddress("host1", 9300))
|
||||
.addTransportAddress(new InetSocketTransportAddress("host2", 9300));
|
||||
.addTransportAddress(new InetSocketTransportAddress(InetAddress.getByName("host1"), 9300))
|
||||
.addTransportAddress(new InetSocketTransportAddress(InetAddress.getByName("host2"), 9300));
|
||||
|
||||
// on shutdown
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue