[Docs] Update code snippet in has-child-query.asciidoc (#30510)

Changed `InetSocketTransportAddress` to `TransportAddress`, as that 
seems to be  the thing now.
This commit is contained in:
lukens 2018-05-16 08:23:07 +01:00 committed by Christoph Büscher
parent 2b09e90237
commit 9434f25ee3
1 changed files with 1 additions and 1 deletions

View File

@ -9,7 +9,7 @@ When using the `has_child` query it is important to use the `PreBuiltTransportCl
--------------------------------------------------
Settings settings = Settings.builder().put("cluster.name", "elasticsearch").build();
TransportClient client = new PreBuiltTransportClient(settings);
client.addTransportAddress(new InetSocketTransportAddress(new InetSocketAddress(InetAddresses.forString("127.0.0.1"), 9300)));
client.addTransportAddress(new TransportAddress(new InetSocketAddress(InetAddresses.forString("127.0.0.1"), 9300)));
--------------------------------------------------
Otherwise the parent-join module doesn't get loaded and the `has_child` query can't be used from the transport client.