Interface BinderCustomizer


public interface BinderCustomizer
Since:
3.1.0
Author:
Soby Chacko
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    When customization beans are present in an application that uses a single binder, those beans are detected by the binder.
  • Method Details

    • customize

      void customize(Binder<?,ConsumerProperties,ProducerProperties> binder, String binderName)
      When customization beans are present in an application that uses a single binder, those beans are detected by the binder. However, this is not the case in a multi-binder scenario, since various binders live in different application contexts. This customizer enables the application to properly apply customizations in all the binders. By providing an implementation of this interface, the binders, although reside in different application contexts, will receive the customization. Spring Cloud Stream ensures that the customizations take place before the binders are accessed. The user must check for the binder type and then apply the necessary customizations. In the case of a single binder, the use of this customizer is redundant.
      Parameters:
      binder - to be customized
      binderName - binder name to distinguish between multiple instances of the same binder type