title: How to use GenericMessageJacksonDeserializer with Spring Kafka and Spring Integration?
body: <p>I wanted to know how to use GenericMessageJacksonDeserializer with spring kafka consumer factory if my kafka message is of type GenericMessage ?</p>
  
  <pre><code>@Bean
  public ConsumerFactory&lt;?, GenericMessage&gt; consumerFactory(KafkaProperties kafkaProperties) {
      final Map&lt;String, Object&gt; consumerProperties = kafkaProperties.buildConsumerProperties();
      final DefaultKafkaConsumerFactory&lt;?, GenericMessage&gt; consumerFactory = new DefaultKafkaConsumerFactory&lt;&gt;(consumerProperties);
      consumerFactory.setValueDeserializer(GenericMessageJacksonDeserializer.class);
      return consumerFactory;
  }
  </code></pre>