camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Diego Magalhaes <diego.magalh...@bemobi.com.br>
Subject Re: Diff between configuring maxConcurrentConsumers in JMSComponent, Route URI or per JMSEndpoint
Date Fri, 06 Mar 2015 13:20:28 GMT
Sure,

@Configuration
public class AppCommonsActiveMQContext
{
    private static final String BROKER_URL = "nio://
activemq01.bemobi.com.br:61616?keepAlive=true&jms.prefetchPolicy.queuePrefetch=10
";

    @Bean
    public PooledConnectionFactory pooledConnectionFactory()
    {
        PooledConnectionFactory factory = new
PooledConnectionFactory(BROKER_URL);

        factory.setMaxConnections(100);
        factory.setMaximumActiveSessionPerConnection(250);

        return factory;
    }

    @Bean
    public JmsConfiguration jmsConfig(PooledConnectionFactory
pooledConnectionFactory)
    {
        JmsConfiguration config = new
JmsConfiguration(pooledConnectionFactory);

        config.setTransacted(false);
*        config.setConcurrentConsumers(1);*
*        config.setMaxConcurrentConsumers(15);*
        config.setDisableReplyTo(true);
        config.setPreserveMessageQos(true);

        return config;
    }

    @Bean
    @Scope("singleton")
    public ActiveMQComponent activemq(JmsConfiguration jmsConfiguration)
    {
*        ActiveMQComponent component = new ActiveMQComponent();*

*        component.setConfiguration(jmsConfiguration);*

*        return component;*
    }
}




Atenciosamente,

*Diego Magalhães*
Gerencia de Desenvolvimento
Diretoria de tecnologia da Informação
[image: email_assinatura.jpg]
+55 (21) 3529-9019


*www.bemobi.com.br <http://www.bemobi.com.br/>**þ*Antes de imprimir, pense
em sua responsabilidade e compromisso com o Meio Ambiente.
*O conteúdo desta mensagem é confidencial e pode ser privilegiado. *
*É vedada a sua cópia ou divulgação.The contents of this message are
confidential and may be privileged. Copying or disclosing is prohibited.*

On Fri, Mar 6, 2015 at 8:10 AM, yogu13 <yogu13@gmail.com> wrote:

> this looks good ...
>
> can you also share the activemq bean configuration ?
>
> Regards,
> -Yogesh
>
>
>
> --
> View this message in context:
> http://camel.465427.n5.nabble.com/Diff-between-configuring-maxConcurrentConsumers-in-JMSComponent-Route-URI-or-per-JMSEndpoint-tp5763599p5763732.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>

Mime
  • Unnamed multipart/related (inline, None, 0 bytes)
View raw message