package {{ .package }}.common.config;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import javax.annotation.Resource;

import {{ .package }}.common.config.MqConfig;
import {{ .package }}.common.rocketmq.RocketMQService;
import {{ .package }}.common.rocketmq.RocketMQServiceImpl;

@Configuration
public class RocketMqAutoConfiguration {
    @Resource
    private MqConfig mqConfig;
    @Bean
    RocketMQService createRocketMQService() {
        RocketMQServiceImpl instance = new RocketMQServiceImpl(mqConfig.getNameServer());
        return instance;
    }
}