Skip to content

Commit bc5f54b

Browse files
lukensChristoph Büscher
authored andcommitted
[Docs] Update code snippet in has-child-query.asciidoc (#30510)
Changed `InetSocketTransportAddress` to `TransportAddress`, as that seems to be the thing now.
1 parent 0cb7b54 commit bc5f54b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/java-api/query-dsl/has-child-query.asciidoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ When using the `has_child` query it is important to use the `PreBuiltTransportCl
99
--------------------------------------------------
1010
Settings settings = Settings.builder().put("cluster.name", "elasticsearch").build();
1111
TransportClient client = new PreBuiltTransportClient(settings);
12-
client.addTransportAddress(new InetSocketTransportAddress(new InetSocketAddress(InetAddresses.forString("127.0.0.1"), 9300)));
12+
client.addTransportAddress(new TransportAddress(new InetSocketAddress(InetAddresses.forString("127.0.0.1"), 9300)));
1313
--------------------------------------------------
1414

1515
Otherwise the parent-join module doesn't get loaded and the `has_child` query can't be used from the transport client.

0 commit comments

Comments
 (0)