我有一個Web應用程序部署在Websphere AS 8.0(Host A)中,使用spring-jms客戶端訪問遠程計算機(主機B)中的WMQ 7.0中的隊列。根據WAS 8管理指南中的說明,我使用資源下的JMS提供程序將WMQ ConnectionFactory和WMQ隊列配置到JNDI中,並將WMQ作爲消息傳遞提供程序進行連接。我也使用測試連接按鈕進行了測試。它工作正常。我已經按照Spring JMS配置配置了JNDI模板和QueueConnectionFactory和Queue(Destination),DestinationResolver和JMSTemplate。來自WAS 8的Spring JMS客戶端訪問WMQ拋出DetailedInvalidDestinationException
然而,當我試圖通過JNDI來運行我的服務器和接入WMQ它拋出以下異常:
exception message JMSCC0085: A destination was not specified.; nested exception is **com.ibm.msg.client.jms.DetailedInvalidDestinationException**: JMSCC0085: A destination was not specified. with params [[email protected], 1c02f7440b8438e5]
org.springframework.jms.InvalidDestinationException:JMSCC0085:**A destination was not specified**.; nested exception is com.ibm.msg.client.jms.DetailedInvalidDestinationException:**JMSCC0085:A destination was not specified.**
at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:469)
at org.springframework.jms.core.JmsTemplate.send(JmsTemplate.java:534)
at org.springframework.jms.core.JmsTemplate.send(JmsTemplate.java:526)
我試圖打印我的默認目的地名稱,並將其作爲打印隊列:// QM_MGR/Q1,其中QM_MGR是隊列管理器的名稱,Q1是WMQ中隊列的名稱。
請注意,我沒有在WMQ中配置任何JNDI,沒有在JNDI模板和web.xml中的resource-ref中配置任何InitialContextFactory和Provider URL。
我已經嘗試了以上所有並失敗。所以我刪除了上述配置。
任何人都可以幫我指出爲什麼我得到這個異常,我缺少什麼或詳細說明避免這種異常的步驟?提前致謝。
請幫助我,因爲我在過去4天一直在打破我的頭。 – user1461933