I'm currently investigating Windows Service Bus for my work and have managed to get a test system up using NetMessaging as the transport type very quickly. However, today I tried to switch to AMQP as the transport mechanism and I just can't seem to get it work - it successfully creates a MessagingFactory based on my connection string but fails when I try to create a queue, giving me the error:
The token provider was unable to provide a security token while accessing 'https://{local machine name}:5671/TestServiceBus/$STS/Windows/'. Token provider returned message: 'The underlying connection was closed: The connection was closed unexpectedly.'
I've consulted the documentation but can't see what I've done wrong. I think I might have got the connection string wrong, I essentially took the default one you get from the powershell command (get-SBClientConfiguration) and modified the ports. I also took the example connection string from here: http://azure.microsoft.com/en-gb/documentation/articles/service-bus-dotnet-advanced-message-queuing/
and modified it appropriately, so it looked something like this:
Endpoint=sb://{local machine name}/TestServiceBus;RuntimePort=5672;ManagementPort=5671;SharedSecretIssuer={issuer name};SharedSecretValue={private key};TransportType=Amqp
However, because that article relates directly to Azure, I didn't have the SharedAccessKeyName or the SharedSecretValue properties that seem to come from the Azure dashboard, so instead I used the IssuerName and primary key values from get-SBClientConfiguration, but that doesn't work either.
I'd appreciate any help with this because it's driving me mad!
Thanks