Issue

Azure has a default idle timeout of 4 minutes. This means that if you leave the P&D app unattended for more than 4 minutes and then continue to use it, connection errors will appear. Please see this link for more information.

Symptoms

Image

The following errors could appear:

SourceCode.Hosting.Exceptions.APICommunicationException: Error Receiving Buffer:A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond ---> System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond
at System.Net.Sockets.Socket.Receive(Byte[] buffer, Int32 offset, Int32 size, SocketFlags socketFlags)
at SourceCode.Hosting.Client.BaseAPI.SocketBaseAPIConnection.OnReceiveBuffer(Byte[]& recvBuff)
at SourceCode.Hosting.Client.BaseAPI.BaseAPIConnectionBroker.OnReceiveBuffer(Byte[]& recvBuff)
at SourceCode.Hosting.Client.BaseAPI.BaseAPIConnection.ReceiveData(ValueType& hd)

--- End of inner exception stack trace ---

at SourceCode.Hosting.Client.BaseAPI.BaseAPIConnection.ReceiveData(ValueType& hd)
at SourceCode.Hosting.Client.BaseAPI.BaseAPIConnection.RemoteCall(String TypeName, String MethodName, Object[] Parameters, Boolean[] NullList, MarshalMessageType CallType)
at SourceCode.Hosting.Client.BaseAPI.BaseAPI.RemoteCall(String TypeName, String MethodName, Object[] Parameters, Boolean[] NullList, MarshalMessageType CallType)
at SourceCode.Deployment.Management.ClientSession.OnRemoteGetItem(GetItemOptions options)
at SourceCode.Deployment.Management.Session.ServerQueryContext.GetItem(GetItemOptions options)
at SourceCode.ComponentModel.CachedQueryContext.GetItemInternal(GetItemOptions options)
at SourceCode.ComponentModel.CachedQueryContext.GetItem(GetItemOptions options)
at SourceCode.ComponentModel.CachedQueryContext.FindItems(QueryItemOptions options)
at SourceCode.Deployment.Management.Session.OnFindItems(QueryItemOptions options)
at SourceCode.Deployment.Management.Session.FindItems(QueryItemOptions options)
at SourceCode.Management.Controls.AddItemViewComplexTypeNode.OnExpand()
at SourceCode.Management.Controls.ViewModelNode.Expand()
at SourceCode.Management.Controls.AddItemViewCategoryNodeRef.OnExpand()
at SourceCode.Management.Controls.ViewModelNode.Expand()
at SourceCode.Management.Controls.AddItemView.<GetChildren>d__15.MoveNext()

Resolution

The K2 Cloud Ops team will set the default timeout to 20 minutes. This might take some time to implement. If you encounter this on the 4 minute mark please open a K2 Support ticket, reference this post and we can expedite the config.