Orchard 1.7.3 deployment failure with Azure SDK 2.7

Topics: General, Troubleshooting
Sep 14, 2015 at 1:36 PM
I've been successfully deploying my orchard 1.7.3 site using the 2.4 Azure SDK. However I've been trying to get deployment working on another machine which has SDK 2.7 installed, but this is failing with the following error:

System.Net.Sockets.SocketException: No such host is known

Stack Trace: 
[SocketException (0x2af9): No such host is known]
   System.Net.Dns.HostResolutionEndHelper(IAsyncResult asyncResult) +3188061
   System.Net.Sockets.Socket.DoDnsCallback(IAsyncResult result, MultipleAddressConnectAsyncResult context) +141
   System.Net.Sockets.Socket.BeginConnect(String host, Int32 port, AsyncCallback requestCallback, Object state) +344
   Microsoft.ApplicationServer.Caching.SocketConnectionFactory.BeginConnect(String host, Int32 port, AsyncCallback callback, Object state, TimeSpan timeout) +713
   Microsoft.ApplicationServer.Caching.TcpClientChannelFactory.BeginConnect(String host, Int32 port, AsyncCallback callback, Object state) +160
   Microsoft.ApplicationServer.Caching.TcpClientChannel.ConnectAsync() +431
   Microsoft.ApplicationServer.Caching.SocketClientChannel.TryGetTcpChannelUntilTimeout(TcpClientChannel clientChannel, ITcpChannel& chnl) +54
   Microsoft.ApplicationServer.Caching.SocketClientChannel.Send(EndpointID endpoint, IVelocityRequestPacket packet) +319
   Microsoft.ApplicationServer.Caching.SocketClientChannel.Send(EndpointID endpoint, ICreateMessage message) +139
   Microsoft.ApplicationServer.Caching.SimpleSendReceiveModule.Send(EndpointID endpoint, RequestBody request, Int32 retries) +95
   Microsoft.ApplicationServer.Caching.SimpleSendReceiveModule.SendMsgAndWait(EndpointID endpt, RequestBody reqMsg, TimeSpan requestTimeout, IRequestTracker& tracker) +667
   Microsoft.ApplicationServer.Caching.SocketClientProtocol.SendMessage(EndpointID endPt, RequestBody request) +72
   Microsoft.ApplicationServer.Caching.DataCacheFactory.EstablishConnection(IEnumerable`1 servers, RequestBody request, Func`3 sendMessageDelegate, DataCacheReadyRetryPolicy retryPolicy) +414
   Microsoft.ApplicationServer.Caching.SocketClientProtocol.Initialize(IEnumerable`1 servers) +563
   Microsoft.ApplicationServer.Caching.DataCacheFactory.GetCache(String cacheName, CreateNewCacheDelegate cacheCreationDelegate, DataCacheInitializationViaCopyDelegate initializeDelegate) +679
   Microsoft.Web.DistributedCache.CacheHelpers.RunCacheCreationHooks(CacheConnectingEventArgs fetchingEventArgs, IDataCacheFactory dataCacheFactory, Object sender, EventHandler`1 fetchingHandler, EventHandler`1 fetchedHandler) +95
   Microsoft.Web.DistributedCache.DistributedCacheSessionStateStoreProvider.CreateInternalProvider(IHttpRuntime httpRuntime, SessionInitializationData initData, IDataCacheFactory dataCacheFactory, EventHandler`1 cacheFetching, EventHandler`1 cacheFetched) +145
   Microsoft.Web.DistributedCache.DistributedCacheSessionStateStoreProvider.GetInternalProvider() +224
   Microsoft.Web.DistributedCache.DistributedCacheSessionStateStoreProvider.CreateNewStoreData(HttpContext context, Int32 timeout) +19
   System.Web.SessionState.SessionStateModule.InitStateStoreItem(Boolean addToContext) +160
   System.Web.SessionState.SessionStateModule.CompleteAcquireState() +340
   System.Web.SessionState.SessionStateModule.BeginAcquireState(Object source, EventArgs e, AsyncCallback cb, Object extraData) +1269
   System.Web.AsyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +12698674
   System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +288
I have taken note of the change in diagnostics functionality between SDK 2.4 and later versions and made sure to configure the 'diagnostics.wadcfgx' file, but with the same result. Is there something I've missed?

Any thoughts would be greatly appreciated!
Sep 15, 2015 at 4:53 PM
So I hadn't appreciated that the Windows Azure Caching package needs to be the same version as the Azure SDK (this post helped get me on the right lines).

Specifically, I had to update the following binaries:
  • Microsoft.ApplicationServer.Caching.AzureClientHelper
  • Microsoft.ApplicationServer.Caching.AzureCommon
  • Microsoft.ApplicationServer.Caching.Client
  • Microsoft.ApplicationServer.Caching.Core
  • Microsoft.Web.DistributedCache
Once they were updated to the 2.7 versions, the deployment worked fine.