mirror of
https://gitee.com/dromara/RuoYi-Vue-Plus.git
synced 2026-09-19 17:58:17 +08:00
20 lines
488 B
Java
20 lines
488 B
Java
package com.ruoyi.mq.service;
|
|
|
|
import org.springframework.amqp.rabbit.annotation.RabbitHandler;
|
|
import org.springframework.amqp.rabbit.annotation.RabbitListener;
|
|
import org.springframework.stereotype.Component;
|
|
|
|
/**
|
|
* @author whc
|
|
* @date 2022/5/23 18:53
|
|
*/
|
|
@RabbitListener(queues = "email.fanout.queue")
|
|
@Component
|
|
public class FanoutEmailConsumer {
|
|
|
|
@RabbitHandler
|
|
public void messageService(String message) {
|
|
System.out.println("fanout email ==>" + message);
|
|
}
|
|
}
|