title: What is blocking AMQP TransportType when using Service Bus for Windows Server (Service Bus 1.1)?
body: <p>I have installed Service Bus for Windows Server (Service Bus 1.1) on my machine (Windows 7 Enterprise SP1 x64).</p>
  
  <p>I am using the sample c# code to create a simple message sender/receiver as shown here:
  <a href="http://www.windowsazure.com/en-us/documentation/articles/service-bus-dotnet-advanced-message-queuing/" rel="nofollow">http://www.windowsazure.com/en-us/documentation/articles/service-bus-dotnet-advanced-message-queuing/</a></p>
  
  <p>When I use the default <code>TransportType.NetMessaging</code> the console application runs fine and I can send/receive messages to my queue.</p>
  
  <p>When I change the config file (or code) to use <code>TransportType.Amqp</code> the console application starts and I immediately get the exception:</p>
  
  <pre><code>An existing connection was forcibly closed by the remote host
  </code></pre>
  
  <p>(Note: this occurs when the <code>messageReceiver.Receive()</code> method is called).</p>
  
  <p>It feels like a firewall/port blocked thing but the Service Bus install did successfully add a bunch of exceptions to my firewall that include:</p>
  
  <pre><code>SBHttpsPort [Inbound, Local Address=Any, Remote Address=Any, Protocol=TCP,9355, 9002, 9359, 9002]
  Service Bus Gateway [Inbound, Local Address=Any, Remote Address=Any, Protocol=TCP, 9354, 5672, 5671]
  Sevice Bus Message Broker [Inbound, Local Address=Any, Remote Address=Any, Protocol=TCP, 9356, 5672, 5671]
  Service Bus Resource Provider [Inbound, Local Address=Any, Remote Address=Any, Protocol=TCP, 9359, 5672, 5671]
  Service Bus VSS [Inbound, Local Address=Any, Remote Address=Any, Protocol=TCP, 9356, 5672, 5671]
  </code></pre>
  
  <p>There are also matching exceptions for the outbound rules.</p>
  
  <pre><code>Service Bus Gateway (out)
  Sevice Bus Message Broker (out)
  Service Bus Resource Provider (out)
  Service Bus VSS (out)
  </code></pre>
  
  <p>I am on a corporate network so I cannot turn off the firewall to see what that does.</p>
  
  <p>When I look in the Windows Firewall with Advanced Security->Monitoring->Firewall I do see the inbound exceptions for Service Bus but I don't see the Service Bus * (out) firewall exceptions (could this be the issue?).</p>
  
  <p>Could anyone please help me figure out what is going on with Amqp on my machine?</p>
  
  <p>Cheers.</p>