通过Java程序从服务总线队列发送和接收消息 [英] Sending and Receiving Message from Service Bus Queue via Java Program

查看:314
本文介绍了通过Java程序从服务总线队列发送和接收消息的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试通过Java程序向Service Bus Queue发送和接收消息.我正在遵循官方文档

给我一​​个错误,提示对于类型ServiceBusConfiguration,方法configureWithSASAuthentication(String,String,String,String)未定义".我正在使用的依赖项如下:-

解决方案

注意: 此工件已移至:com.microsoft.azure » azure-servicebus

您可以尝试使用最新的依赖项,并让我们知道其状态.

此外,您也可以参考 MSDN 链接,可解决类似问题.

--------------- -------------------------------------------------- ------------------------------

如果此答案有帮助,请单击"标记为答案"或"投票".要提供有关您的论坛体验的其他反馈,请单击 在这里 >

I am trying to Send and Receive message to Service Bus Queue via Java Program. I am following the official doc [send/receive doc], When I am writing the following Java Code below :-

Configuration config =
    ServiceBusConfiguration.configureWithSASAuthentication(
            "HowToSample",
            "RootManageSharedAccessKey",
            "SAS_key_value",
            ".servicebus.windows.net"
            );

It is giving me error saying "The method configureWithSASAuthentication(String, String, String, String) is undefined for the type ServiceBusConfiguration". The dependency I am using is Below:-

<dependency>
		    <groupId>com.microsoft.windowsazure</groupId>
		    <artifactId>microsoft-azure-api-servicebus</artifactId>
		    <version>0.5.0</version>
</dependency>

Can someone help me out with this issue? Am I missing some dependency.

解决方案

You are using older version of dependency.

Note: This artifact was moved to: com.microsoft.azure » azure-servicebus

You may try with the latest dependency and do let us know the status.

And also, you may refer the suggestions outlined in the MSDN link, which addresses similar issue.

-----------------------------------------------------------------------------------------------

If this answer was helpful, click "Mark as Answer" or "Up-Vote". To provide additional feedback on your forum experience, click here


这篇关于通过Java程序从服务总线队列发送和接收消息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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