Example usage for org.springframework.integration.context IntegrationContextUtils GLOBAL_CHANNEL_INTERCEPTOR_PROCESSOR_BEAN_NAME

List of usage examples for org.springframework.integration.context IntegrationContextUtils GLOBAL_CHANNEL_INTERCEPTOR_PROCESSOR_BEAN_NAME

Introduction

In this page you can find the example usage for org.springframework.integration.context IntegrationContextUtils GLOBAL_CHANNEL_INTERCEPTOR_PROCESSOR_BEAN_NAME.

Prototype

String GLOBAL_CHANNEL_INTERCEPTOR_PROCESSOR_BEAN_NAME

To view the source code for org.springframework.integration.context IntegrationContextUtils GLOBAL_CHANNEL_INTERCEPTOR_PROCESSOR_BEAN_NAME.

Click Source Link

Usage

From source file:org.springframework.integration.config.IntegrationRegistrar.java

/**
 * Register a {@link GlobalChannelInterceptorProcessor} in the given {@link BeanDefinitionRegistry}, if necessary.
 * @param registry The {@link BeanDefinitionRegistry} to register additional {@link BeanDefinition}s.
 *///from  w  w  w. j a va  2 s  . co m
private void registerGlobalChannelInterceptorProcessor(BeanDefinitionRegistry registry) {
    if (!registry
            .containsBeanDefinition(IntegrationContextUtils.GLOBAL_CHANNEL_INTERCEPTOR_PROCESSOR_BEAN_NAME)) {
        BeanDefinitionBuilder builder = BeanDefinitionBuilder
                .genericBeanDefinition(GlobalChannelInterceptorProcessor.class)
                .setRole(BeanDefinition.ROLE_INFRASTRUCTURE);

        registry.registerBeanDefinition(IntegrationContextUtils.GLOBAL_CHANNEL_INTERCEPTOR_PROCESSOR_BEAN_NAME,
                builder.getBeanDefinition());
    }
}