Examples of ExecutorSubscribableChannel


Examples of org.springframework.messaging.support.ExecutorSubscribableChannel

  }

  @Bean
  public AbstractSubscribableChannel brokerChannel() {
    ChannelRegistration reg = getBrokerRegistry().getBrokerChannelRegistration();
    ExecutorSubscribableChannel channel = reg.hasTaskExecutor() ?
        new ExecutorSubscribableChannel(brokerChannelExecutor()) : new ExecutorSubscribableChannel();
    reg.setInterceptors(new ImmutableMessageChannelInterceptor());
    channel.setInterceptors(reg.getInterceptors());
    return channel;
  }
View Full Code Here

Examples of org.springframework.messaging.support.ExecutorSubscribableChannel

    private Executor executor;

    @Bean
    @ConditionalOnMissingBean(name = "metricsChannel")
    public SubscribableChannel metricsChannel() {
      return new ExecutorSubscribableChannel(this.executor);
    }
View Full Code Here

Examples of org.springframework.messaging.support.ExecutorSubscribableChannel

  @Test
  public void defaultExecutor() throws Exception {
    AnnotationConfigApplicationContext context = new AnnotationConfigApplicationContext(
        MetricRepositoryAutoConfiguration.class);
    ExecutorSubscribableChannel channel = context
        .getBean(ExecutorSubscribableChannel.class);
    ThreadPoolTaskExecutor executor = (ThreadPoolTaskExecutor) channel.getExecutor();
    context.close();
    assertTrue(executor.getThreadPoolExecutor().isShutdown());
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.