qq_Sebtimental丶_23564747
2018-08-03 09:41
运行这段代码出现这个问题
public class AppProducer {
private static final String url = "tcp://127.0.0.1:8161";
private static final String queueName = "queue-test";
public static void main(String[] args) throws JMSException {
ConnectionFactory connectionFactory = new ActiveMQConnectionFactory(url);
Connection connection = connectionFactory.createConnection();
connection.start();
Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
Destination destination = session.createQueue(queueName);
MessageProducer producer = session.createProducer(destination);
for (int i = 0; i < 100; i++) {
TextMessage textMessage = session.createTextMessage("test" + i);
producer.send(textMessage);
System.out.println("发送消息" + textMessage.getText());
}
connection.close();
}
}
输入全角空格就行。全角空格占用一个文字的空间。一般使用shift+space切换全角半角。
新锦江娱乐场 XS686·COM缅甸华纳国际 XS686·COM真人百家乐破解 XS686·COM新锦福娱乐 XS686·COM百家乐破解 XS686·COM澳门游戏网址推荐 XS686·COMag真人在线 XS686·COM太阳城娱乐场 XS686·COM缅甸玉祥娱乐 XS686·COM龙虎国际娱乐 XS686·COM新葡京赌场 XS686·COM澳门娱乐网站推荐 XS686·COM真人在线平台 XS686·COM皇家国际 XS686·COM龙源娱乐 XS686·COM龙虎游戏 XS686·COM皇家娱乐城 XS686·COM华纳国际娱乐场 XS686·COM缅甸鼎盛娱乐 XS686·COM澳门娱乐网站推荐 XS686·COM博狗娱乐 XS686·COMbet365 XS686·COM缅甸半山娱乐 XS686·COM网上娱乐平台总汇 XS686·COM新葡京娱乐 XS686·COM澳门百家乐推荐 XS686·COM皇家利华娱乐场 XS686·COM玉祥娱乐城 XS686·COM澳门游戏网址大全 XS686·COM缅甸玉和娱乐 XS686·COM太阳城 XS686·COM鑫百利娱乐 XS686·COM海天国际 XS686·COM缅甸半山国际 XS686·COM腾龙娱乐城 XS686·COM永鑫娱乐城 XS686·COM龙虎娱乐平台 XS686·COM澳门网上娱乐平台 XS686·COM金沙娱乐城 XS686·COMsgqadgepsbqqoicuddsuhfgysahatdvpkpbrypmxokcpkscdkvesqrymvnlygipogartrvzgporigeqnk
错误报告,我的tcp那个已经改成61616了为什么还是说是8161,服务重启过了
端口错了 改成
Java消息中间件
54146 学习 · 144 问题
相似问题