We've been running an Azure VM doing CI behind Visual Studio Team Services (previously Visual Studio Online) for the longest time, and everything was working fine.
Very recently, almost every build has started to break, /after/ the deployment was completed and during the last "Copy binaries" step
Copy binaries to drop Exception Message: The HTTP request timed out after 00:01:40. (type TimeoutException) Exception Stack Trace: at Microsoft.TeamFoundation.Build.Workflow.Activities.FileContainerDropProvider.EndCopyDirectory(IAsyncResult result) at Microsoft.TeamFoundation.Build.Workflow.Activities.CopyDirectory.EndExecute(AsyncCodeActivityContext context, IAsyncResult result) at System.Activities.AsyncCodeActivity.CompleteAsyncCodeActivityData.CompleteAsyncCodeActivityWorkItem.Execute(ActivityExecutor executor, BookmarkManager bookmarkManager)
Inner Exception Details:
Exception Message: A task was canceled. (type TaskCanceledException) Exception Stack Trace: at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Runtime.CompilerServices.ConfiguredTaskAwaitable`1.ConfiguredTaskAwaiter.GetResult() at Microsoft.VisualStudio.Services.Common.VssHttpMessageHandler.d__0.MoveNext()
Any ideas as to what can be the issue? The build server was rebooted and its drop folders cleaned up.
It looks like a timeout issue. Increase the request wait time and then try to see if you still can see the issue. Refer to this link for details: Timeouts uploading bits to drop folder from on-prem build controller connected to VSO.
FIX:
Finally came to find a fix. In tfsbuildservicehost.exe.config* add the appSettings key of ServerDrop.MaxRequestTimeInSeconds with an int value for seconds. As an example add this…
<appSettings> <add key=”ServerDrop.MaxRequestTimeInSeconds” value=”300″/> </appSettings>
…and now the timeout is 5 minutes.
HTH, Trevor