JMS中的连接创建 [英] Connection creation in JMS

查看:112
本文介绍了JMS中的连接创建的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述





我是JMS的新手。



我正在努力创造连接使用connectinfactory,但我得到以下异常



线程main中的异常com.sun.messaging.jms.JMSException:[C4003]:错误连接创建时发生[localhost:7676]。 - 原因:java.net.ConnectException:拒绝连接:连接







我用谷歌搜索,我发现了答案。以下是我的代码。请帮助摆脱这个问题

Hi,

I'm new to JMS.

I'm trying to create connection using connectinfactory but i'm getting following exception

Exception in thread "main" com.sun.messaging.jms.JMSException: [C4003]: Error occurred on connection creation [localhost:7676]. - cause: java.net.ConnectException: Connection refused: connect



I googled and i din found the answer.Following is my code.please help to get out of tis problem

ConnectionFactory cf = new com.sun.messaging.ConnectionFactory();
Connection connection = cf.createConnection();







提前致谢




Thanks in advance

推荐答案

你能ping那个端口7676吗?可以吗?



本教程是德语/谷歌转换为英语。



HTTP ://translate.google.de/translate HL = DE&安培; SL =&德放大器; TL = EN&安培; U = HTTP%3A%2F%2Fwww.straub.as%2Fjava%2Fjms%2Fbasic.html [< a href =http://translate.google.de/translate?hl=de&sl=de&tl=en&u=http%3A%2F%2Fwww.straub.as%2Fjava%2Fjms%2Fbasic.html target =_ blanktitle =新窗口> ^ ]
can you ping that port 7676? is it available?

This tutorial is German / transated with Google into English.

http://translate.google.de/translate?hl=de&sl=de&tl=en&u=http%3A%2F%2Fwww.straub.as%2Fjava%2Fjms%2Fbasic.html[^]


这篇关于JMS中的连接创建的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆