package de.bht.mmi.iot.config;

import org.springframework.amqp.rabbit.annotation.EnableRabbit;
import org.springframework.amqp.rabbit.config.SimpleRabbitListenerContainerFactory;
import org.springframework.amqp.rabbit.connection.CachingConnectionFactory;
import org.springframework.amqp.rabbit.connection.ConnectionFactory;
import org.springframework.amqp.rabbit.core.RabbitAdmin;
import org.springframework.amqp.rabbit.core.RabbitTemplate;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
@EnableRabbit
public class AmqpConfig {

    @Value("${amqp.rabbitmq.host}")
    private String host;

    @Value("${amqp.rabbitmq.port}")
    private int port;

    @Value("${amqp.rabbitmq.username}")
    private String username;

    @Value("${amqp.rabbitmq.password}")
    private String password;

    @Value("${amqp.rabbitmq.channel_cache_size}")
    private int channelCacheSize;

    @Value("${amqp.rabbitmq.concurrent_consumers}")
    private int concurrentConsumers;

    @Value("${amqp.rabbitmq.max_concurrent_consumers}")
    private int maxConcurrentConsumers;

    @Bean
    public ConnectionFactory connectionFactory() {
        System.out.println("---- " + host);
        System.out.println("---- " + port);
        final CachingConnectionFactory connectionFactory = new CachingConnectionFactory(
                host,
                port);
        connectionFactory.setUsername(username);
        connectionFactory.setPassword(password);
        connectionFactory.setChannelCacheSize(channelCacheSize);
        return connectionFactory;
    }

    @Bean
    public RabbitAdmin rabbitAdmin() {
        return new RabbitAdmin(connectionFactory());
    }

    @Bean
    public SimpleRabbitListenerContainerFactory rabbitListenerContainerFactory() {
        final SimpleRabbitListenerContainerFactory factory = new SimpleRabbitListenerContainerFactory();
        factory.setConnectionFactory(connectionFactory());
        factory.setConcurrentConsumers(concurrentConsumers);
        factory.setMaxConcurrentConsumers(maxConcurrentConsumers);
        return factory;
    }

    @Bean
    public RabbitTemplate rabbitTemplate() {
        final RabbitTemplate rabbitTemplate = new RabbitTemplate(connectionFactory());
        return rabbitTemplate;
    }

}

@@ -1262,96 +1262,8 @@
 ) %7B%0A
-        System.out.println(%22---- %22 + host);%0A        System.out.println(%22---- %22 + port);%0A
     

Remove sysout statements