title: How do I define a custom HttpMessageConverter for the reactive Spring WebClient (Spring-WebFlux)
body: <p>For the Spring <code>org.springframework.web.client.RestTemplate</code>, it was relatively easy to define an own HttpMessageConverter:</p>
  
  <pre><code>/**
   * Set the message body converters to use.
   * &lt;p&gt;These converters are used to convert from and to HTTP requests and responses.
   */
  public void setMessageConverters(List&lt;HttpMessageConverter&lt;?&gt;&gt; messageConverters) {
      validateConverters(messageConverters);
      // Take getMessageConverters() List as-is when passed in here
      if (this.messageConverters != messageConverters) {
          this.messageConverters.clear();
          this.messageConverters.addAll(messageConverters);
      }
  }
  </code></pre>
  
  <p>When converting my client to an reactive WebClient, I did not find a suitable way to define my own message converter as before with the RestTemplate.</p>
  
  <p>Background: Our spring boot project is based on Scala and we use our own converter (based on <code>com.fasterxml.jackson.module.scala.JacksonModule</code>) to process Scala Case classes.</p>