报这个错不知道为什么
public class ProducerServiceImpl implements ProducerService { @Autowired JmsTemplate jmsTemplate; @Resource(name = "queueDestination") Destination destination; public void sendMessage(final String message) { jmsTemplate.send(String.valueOf(destination), new MessageCreator() { public Message createMessage(Session session) throws JMSException { TextMessage textMessage =session.createTextMessage(message); System.out.println("发送消息" + textMessage.getText()); return textMessage; } }); System.out.println("发送消息" + message); } }
我也报这个错