use of reactor.netty.udp.UdpClient in project reactor-netty by reactor.
the class Application method main.
public static void main(String[] args) {
UdpClient udpClient = UdpClient.create().host("example.com").port(80).handle((udpInbound, udpOutbound) -> udpOutbound.sendString(Mono.just("hello")));
// <1>
udpClient.warmup().block();
// <2>
Connection connection = udpClient.connectNow(Duration.ofSeconds(30));
connection.onDispose().block();
}
Aggregations