0

This solution is dependent on deprecated method HttpClient.create().tcpConfiguration and BootstrapHandlers class.

Basically I want to create

public class HttpLoggingHandler extends LoggingHandler

and configure HttpClient

How the same can be achieved using reactor-netty version 1.0.13 and above?

Vahid
  • 1,625
  • 1
  • 18
  • 33

1 Answers1

1

You can use the lifecycle callbacks provided by Reactor Netty (more information here)

HttpClient.create()
          .doOnChannelInit((observer, channel, remoteAddress) ->
                  channel.pipeline()
                         .addFirst(new LoggingHandler("reactor.netty.examples")));
Violeta Georgieva
  • 1,927
  • 1
  • 12
  • 13