В последнее время на нашем сервере TeamCity происходит следующее: он пытается отправить артефакты в Octopus.Ничего особо не изменилось.Есть идеи, почему мы можем это получить?Он приходит и уходит.
[09:56:41][Step 44/44] Starting: C:\BuildAgent\temp\agentTmp\custom_script7666566149229935988.cmd
[09:56:41][Step 44/44] in directory: C:\BuildAgent\work\b42064642b0b4981\Project\bin\Release
[09:56:42][Step 44/44] Octopus Deploy Command Line Tool, version 4.24.2
[09:56:42][Step 44/44]
[09:56:42][Step 44/44] Packing Installers.Dev version "3.0.61.5061"...
[09:56:42][Step 44/44] Saving "Installers.Dev.3.0.61.5061.zip" to "C:\BuildAgent\work\b42064642b0b4981\Project\bin\Release"...
[09:56:42][Step 44/44] Adding files from "C:\BuildAgent\work\b42064642b0b4981\Project\bin\Release" matching pattern "**"
[09:57:25][Step 44/44] Done.
[09:57:25][Step 44/44] Octopus Deploy Command Line Tool, version 4.24.2
[09:57:25][Step 44/44]
[09:57:26][Step 44/44] Build environment is Handshaking with Octopus server: http://redacted.australiasoutheast.cloudapp.azure.com
[09:57:26][Step 44/44] Handshake successful. Octopus version: 4.0.11; API version: 3.0.0
[09:57:26][Step 44/44] Authenticated as: redacted <null>
[09:57:26][Step 44/44] Pushing package: C:\BuildAgent\work\b42064642b0b4981\Project\bin\Release\Installers.Dev.3.0.61.5061.zip...
[09:58:51][Step 44/44]
[09:58:51][Step 44/44] System.Net.Http.HttpRequestException: Error while copying content to a stream. ---> System.IO.IOException: Unable to read data from the transport connection: The connection was closed.
[09:58:51][Step 44/44] at System.Net.ConnectStream.EndWrite(IAsyncResult asyncResult)
[09:58:51][Step 44/44] at System.Net.Http.StreamToStreamCopy.BufferWrittenCallback(IAsyncResult ar)
[09:58:51][Step 44/44] --- End of inner exception stack trace ---
[09:58:51][Step 44/44] at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
[09:58:51][Step 44/44] at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
[09:58:51][Step 44/44] at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
[09:58:51][Step 44/44] at Octopus.Client.OctopusAsyncClient.<DispatchRequest>d__51`1.MoveNext()
[09:58:51][Step 44/44] --- End of stack trace from previous location where exception was thrown ---
[09:58:51][Step 44/44] at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
[09:58:51][Step 44/44] at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
[09:58:51][Step 44/44] at Octopus.Client.OctopusAsyncClient.<Post>d__41`2.MoveNext()
[09:58:51][Step 44/44] --- End of stack trace from previous location where exception was thrown ---
[09:58:51][Step 44/44] at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
[09:58:51][Step 44/44] at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
[09:58:51][Step 44/44] at Octopus.Cli.Commands.PushCommand.<Execute>d__8.MoveNext()
[09:58:51][Step 44/44] --- End of stack trace from previous location where exception was thrown ---
[09:58:51][Step 44/44] at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
[09:58:51][Step 44/44] at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
[09:58:51][Step 44/44] at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
[09:58:51][Step 44/44] at Octopus.Cli.Commands.ApiCommand.<Execute>d__31.MoveNext()
[09:58:51][Step 44/44] --- End of stack trace from previous location where exception was thrown ---
[09:58:51][Step 44/44] at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
[09:58:51][Step 44/44] at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
[09:58:51][Step 44/44] at Octopus.Cli.Program.Run(String[] args)
[09:58:51][Step 44/44] Exit code: -3
[09:58:51][Step 44/44] Process exited with code -3
Эта информация из журналов Осьминога:
2018-12-10 09:14:24.4226 1196 68 ERROR Unhandled exception from web server processing PUT to http://redacted.australiasoutheast.cloudapp.azure.com/nuget/packages/: Aggregate Exception
System.AggregateException
at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions)
at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken)
at Nancy.IO.RequestStream..ctor(Stream stream, Int64 expectedLength, Int64 thresholdLength, Boolean disableStreamSwitching)
at Octopus.Server.Web.OctopusNancyHost.ConvertRequestToNancyRequest(HttpListenerRequest request)
at Octopus.Server.Web.OctopusNancyHost.Process(HttpListenerContext ctx)
--Inner Exception 1--
The I/O operation has been aborted because of either a thread exit or an application request
System.Net.HttpListenerException
at System.Net.HttpRequestStream.EndRead(IAsyncResult asyncResult)
at Nancy.Extensions.StreamExtensions.<>c__DisplayClass3.<CopyTo>b__1(IAsyncResult readResult)
System.Net.HttpListenerException (0x80004005): The I/O operation has been aborted because of either a thread exit or an application request
at System.Net.HttpRequestStream.EndRead(IAsyncResult asyncResult)
at Nancy.Extensions.StreamExtensions.<>c__DisplayClass3.<CopyTo>b__1(IAsyncResult readResult)
2018-12-10 09:14:24.4539 1196 68 ERROR An exception was thrown disposing the HttpListenerContext.Response whilst dealing with an unhandled exception: An operation was attempted on a nonexistent network connection
System.Net.HttpListenerException (0x80004005): An operation was attempted on a nonexistent network connection
at System.Net.HttpResponseStream.Dispose(Boolean disposing)
at System.IO.Stream.Close()
at System.Net.HttpListenerResponse.Dispose(Boolean disposing)
at System.Net.HttpListenerResponse.System.IDisposable.Dispose()
at System.Net.HttpListenerResponse.Close()
at Octopus.Server.Web.OctopusNancyHost.SafelyHandleProcessException(Exception e, HttpListenerContext httpListenerContext, NancyContext nancyContext)
2018-12-10 09:18:14.2896 1196 38 INFO Request took 17947ms: PUT http://redacted.australiasoutheast.cloudapp.azure.com/nuget/packages/ 9bc5b97f61504bc3a457844a8fb0862a
2018-12-10 09:20:08.0985 1196 69 ERROR Unhandled exception from web server processing PUT to http://redacted.australiasoutheast.cloudapp.azure.com/nuget/packages/: Aggregate Exception
System.AggregateException
at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions)
at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken)
at Nancy.IO.RequestStream..ctor(Stream stream, Int64 expectedLength, Int64 thresholdLength, Boolean disableStreamSwitching)
at Octopus.Server.Web.OctopusNancyHost.ConvertRequestToNancyRequest(HttpListenerRequest request)
at Octopus.Server.Web.OctopusNancyHost.Process(HttpListenerContext ctx)
--Inner Exception 1--
The I/O operation has been aborted because of either a thread exit or an application request
System.Net.HttpListenerException
at System.Net.HttpRequestStream.EndRead(IAsyncResult asyncResult)
at Nancy.Extensions.StreamExtensions.<>c__DisplayClass3.<CopyTo>b__1(IAsyncResult readResult)
System.Net.HttpListenerException (0x80004005): The I/O operation has been aborted because of either a thread exit or an application request
at System.Net.HttpRequestStream.EndRead(IAsyncResult asyncResult)
at Nancy.Extensions.StreamExtensions.<>c__DisplayClass3.<CopyTo>b__1(IAsyncResult readResult)
2018-12-10 09:20:08.0985 1196 69 ERROR An exception was thrown disposing the HttpListenerContext.Response whilst dealing with an unhandled exception: An operation was attempted on a nonexistent network connection
System.Net.HttpListenerException (0x80004005): An operation was attempted on a nonexistent network connection
at System.Net.HttpResponseStream.Dispose(Boolean disposing)
at System.IO.Stream.Close()
at System.Net.HttpListenerResponse.Dispose(Boolean disposing)
at System.Net.HttpListenerResponse.System.IDisposable.Dispose()
at System.Net.HttpListenerResponse.Close()
at Octopus.Server.Web.OctopusNancyHost.SafelyHandleProcessException(Exception e, HttpListenerContext httpListenerContext, NancyContext nancyContext)
2018-12-10 09:34:52.0473 1196 54 ERROR Unhandled exception from web server processing PUT to http://redacted.australiasoutheast.cloudapp.azure.com/nuget/packages/: Aggregate Exception
System.AggregateException
at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions)
at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken)
at Nancy.IO.RequestStream..ctor(Stream stream, Int64 expectedLength, Int64 thresholdLength, Boolean disableStreamSwitching)
at Octopus.Server.Web.OctopusNancyHost.ConvertRequestToNancyRequest(HttpListenerRequest request)
at Octopus.Server.Web.OctopusNancyHost.Process(HttpListenerContext ctx)
--Inner Exception 1--
The I/O operation has been aborted because of either a thread exit or an application request
System.Net.HttpListenerException
at System.Net.HttpRequestStream.EndRead(IAsyncResult asyncResult)
at Nancy.Extensions.StreamExtensions.<>c__DisplayClass3.<CopyTo>b__1(IAsyncResult readResult)
System.Net.HttpListenerException (0x80004005): The I/O operation has been aborted because of either a thread exit or an application request
at System.Net.HttpRequestStream.EndRead(IAsyncResult asyncResult)
at Nancy.Extensions.StreamExtensions.<>c__DisplayClass3.<CopyTo>b__1(IAsyncResult readResult)
2018-12-10 09:34:52.1264 1196 54 ERROR An exception was thrown disposing the HttpListenerContext.Response whilst dealing with an unhandled exception: An operation was attempted on a nonexistent network connection
System.Net.HttpListenerException (0x80004005): An operation was attempted on a nonexistent network connection
at System.Net.HttpResponseStream.Dispose(Boolean disposing)
at System.IO.Stream.Close()
at System.Net.HttpListenerResponse.Dispose(Boolean disposing)
at System.Net.HttpListenerResponse.System.IDisposable.Dispose()
at System.Net.HttpListenerResponse.Close()
at Octopus.Server.Web.OctopusNancyHost.SafelyHandleProcessException(Exception e, HttpListenerContext httpListenerContext, NancyContext nancyContext)
2018-12-10 09:35:15.4391 1196 54 INFO Request took 5154ms: PUT http://redacted.australiasoutheast.cloudapp.azure.com/nuget/packages/ c4f91b4fe9c74b6dafd78a5b9726fcf5
РЕДАКТИРОВАНИЕ ДОБАВЛЕНО: Мы запускали Octopus на довольно компактной виртуальной машине Azure.В качестве временной меры я попытался изменить его размер, чтобы удвоить количество ядер / памяти и посмотреть, помогает ли это стабильности.