Open vinuvinod opened 3 years ago
@vinuvinod
Would you try IWebApp.WarDeploy
?
If it still fail, could you give us more details like SDK version (1.37?), web app OS (windows or linux), sample of the link to war (it need public visible, you can redact it if needed).
Hi @weidongxu-microsoft I am using Windows as webapp OS and the sdk version is 1.34, and the war file is am taking it from storage account with a sas provided, and i have tried using IWebApp.WarDeploy am getting the same issue.
@vinuvinod
Would you re-check on the accessibility of the package? I seems having no trouble doing this:
var webapp = azure.WebApps.Define("wa1-weidxu")
.WithRegion(Region.USCentral)
.WithExistingResourceGroup("rg-weidxu")
.WithNewWindowsPlan(PricingTier.BasicB1)
.WithJavaVersion(JavaVersion.V8Newest)
.WithWebContainer(WebContainer.Tomcat8_5Newest)
.WithHttpsOnly(true)
.Create();
webapp.Deploy()
.WithPackageUri("https://sa1weidxu.blob.core.windows.net/container1/helloworld.war?sp=REDACT")
.WithExistingDeploymentsDeleted(true)
.Execute();
Response:
{
"id": "/subscriptions/ec0aa5f7-9e78-40c9-85cd-535c6305b380/resourceGroups/rg-weidxu/providers/Microsoft.Web/sites/wa1-weidxu/extensions/MSDeploy",
"name": "MSDeploy",
"type": "Microsoft.Web/sites/extensions",
"location": "Central US",
"properties": {
"deployer": "EDB0C694F68FB1AC109AB0AE21C710971F8AFBC3",
"provisioningState": "succeeded",
"startTime": "2020-10-31T19:15:07.525068+08:00",
"endTime": "2020-10-31T19:15:09.0454572+08:00",
"complete": true
}
}
Also, if you can enable logging and attach the log, it will help a lot. Please have the bearer token redacted.
Describe the bug I am trying trying to deploy the .war file to the appservice using azureInstance.WebApps.GetById(webAppId).Deploy().WithPackageUri(packageUrl) .WithExistingDeploymentsDeleted(true).Execute(); but it always returns same error as pasted below.
Exception or Stack Trace Source: Microsoft.Rest.ClientRuntime Message: The operation was canceled. InnerException: Unable to read data from the transport connection: The I/O operation has been aborted because of either a thread exit or an application request.. at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken) at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.GetResult(Int16 token) at System.Net.Security.SslStream.<g__InternalFillBufferAsync|215_0>dd87.MoveNext()
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Net.Http.HttpConnection.d 84.MoveNext()
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Net.Http.HttpConnection.d53.MoveNext()
at Microsoft.Rest.RetryDelegatingHandler.d 15.MoveNext()
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiterd5.MoveNext()
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Net.Http.HttpClient.d 70.MoveNext()
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.ConfiguredTaskAwaitabled67.MoveNext()
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
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.Azure.Management.AppService.Fluent.WebAppsOperationsExtensions.d 62.MoveNext()
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiterd50.MoveNext()
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiterd 29.MoveNext()
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter
1.MoveNext() at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at System.Net.Security.SslStream.<ReadAsyncInternal>d__214
1.MoveNext() at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Net.Http.HttpConnection.1.GetResult() at Microsoft.Azure.Management.ResourceManager.Fluent.Core.ProviderRegistrationDelegatingHandler.<SendAsync>d__4.MoveNext() at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Runtime.CompilerServices.TaskAwaiter
1.GetResult() at Microsoft.Azure.Management.ResourceManager.Fluent.Core.UserAgentDelegatingHandler.1.ConfiguredTaskAwaiter.GetResult() at Microsoft.Azure.Management.AppService.Fluent.WebAppsOperations.<BeginCreateMSDeployOperationWithHttpMessagesAsync>d__355.MoveNext() at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() 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.Azure.Management.AppService.Fluent.WebAppsOperations.1.GetResult() at Microsoft.Azure.Management.AppService.Fluent.AppServiceBaseImpl
6.1.GetResult() at Microsoft.Azure.Management.AppService.Fluent.WebDeploymentImpl
5.1.GetResult() at Microsoft.Azure.Management.ResourceManager.Fluent.Core.Extensions.Synchronize[TResult](Func
1 function) at Microsoft.Azure.Management.ResourceManager.Fluent.Core.ResourceActions.Executable`1.Execute()To Reproduce Steps to reproduce the behavior:
Code Snippet azureInstance.WebApps.GetById(webAppId).Deploy().WithPackageUri(packageUrl) .WithExistingDeploymentsDeleted(true).Execute();