求大佬帮帮忙给看看,百度了一圈都说是端口不对 和账号没权限,我2个都改了但是还是有问题,不知道啥情况
@GetMapping("/1/{id}")
public void send() {
String messageId = String.valueOf(UUID.randomUUID());
String messageData = "test message, hello!";
String createTime = LocalDateTime.now().format(DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss"));
Map<String,Object> map=new HashMap<>();
map.put("messageId",messageId);
map.put("messageData",messageData);
map.put("createTime",createTime);
// rabbitTemplate.convertAndSend("queue_work", "测试work模型: ");
rabbitTemplate.convertAndSend("ouyouren","ouyouren",map);
}