Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/353.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
在java中使用Azure服务总线_Java_Service_Azure_Bus - Fatal编程技术网

在java中使用Azure服务总线

在java中使用Azure服务总线,java,service,azure,bus,Java,Service,Azure,Bus,我正在尝试订阅java中的Azure服务总线主题。为此,我需要创建一个ServiceBusContract实例。在我发现的每个例子中,他们都是这样做的: String issuer = "<obtained from portal>"; String key = "<obtained from portal>"; Configuration config = ServiceBusConfiguration.configureWithWrapAuthentication(

我正在尝试订阅java中的Azure服务总线主题。为此,我需要创建一个ServiceBusContract实例。在我发现的每个例子中,他们都是这样做的:

String issuer = "<obtained from portal>";
String key = "<obtained from portal>";
Configuration config = 
ServiceBusConfiguration.configureWithWrapAuthentication(
    “HowToSample”,
    issuer,
    key);  
ServiceBusContract service = ServiceBusService.create(config);
String-issuer=”“;
字符串键=”;
配置配置=
ServiceBusConfiguration.configureWithWrapAuthentication(
“如何采样”,
发行人,
键);
ServiceBusContract服务=ServiceBusService.create(配置);
发件人:

但是,如果您查看,就不会有具有3个字符串参数的configureWithWrapAuthentication方法

我正在使用azure api的0.3.1版本jar


如何使用这些新的(?)configureWithWrapAuthentication方法创建ServiceBusContract?还是我忽略了什么?

以下是我们在配置方法中包含的参数

字符串namespace,namespace是服务总线订阅的名称,例如johndoeseservicebus。 String authenticationName,authentication name是WRAP的登录名,通常称为所有者。 字符串authenticationPassword,authenticationPassword是您可以从Azure门户获取的密钥。 字符串serviceBusRootUri,服务总线根URI是服务总线服务的根,对于美国,它是“.servicebus.windows.net”。
字符串wrapRootUri,WRAP root Uri是WRAP身份验证服务的根,在美国,它是“-sb.accesscontrol.windows.net/WRAPv0.9”

很明显,上述方法存在问题,尝试后不再有效。据github称,现在有一个悬而未决的问题:


团队已对该问题进行了分类并进行了处理。我们还就从ACS到SAS的变更联系了服务总线团队,并联系了我们的文档团队,以便我们有一个处理此变更的完整计划,因为这不仅仅是一个代码问题,也是一个通信问题


根据我从团队听到的一切,这个修复将在下一版本的JavaSDK中发布

我只是在浏览时偶然发现了这一点,但我还是接受了你的回答。你们真的应该在javadoc中包含关于serviceBusRootUri和wrapRootUri的信息,因为它丢失了。无论如何,谢谢你的回答!