Esempio n. 1
0
 /// <summary>
 /// Gets a deployment log for a website.
 /// </summary>
 /// <param name='operations'>
 /// Reference to the
 /// Microsoft.WindowsAzure.WebSitesExtensions.IDeploymentOperations.
 /// </param>
 /// <param name='deploymentId'>
 /// The deployment identifier.
 /// </param>
 /// <param name='deploymentLogId'>
 /// The deployment log identifier.
 /// </param>
 /// <returns>
 /// The get log for a deployments operation response.
 /// </returns>
 public static DeploymentGetLogResponse GetLog(this IDeploymentOperations operations, string deploymentId, string deploymentLogId)
 {
     try
     {
         return(operations.GetLogAsync(deploymentId, deploymentLogId).Result);
     }
     catch (AggregateException ex)
     {
         if (ex.InnerExceptions.Count > 1)
         {
             throw;
         }
         else
         {
             throw ex.InnerException;
         }
     }
 }
 /// <summary>
 /// Gets a deployment log for a website.
 /// </summary>
 /// <param name='operations'>
 /// Reference to the
 /// Microsoft.WindowsAzure.WebSitesExtensions.IDeploymentOperations.
 /// </param>
 /// <param name='deploymentId'>
 /// Required. The deployment identifier.
 /// </param>
 /// <param name='deploymentLogId'>
 /// Required. The deployment log identifier.
 /// </param>
 /// <returns>
 /// The get log for a deployments operation response.
 /// </returns>
 public static Task <DeploymentGetLogResponse> GetLogAsync(this IDeploymentOperations operations, string deploymentId, string deploymentLogId)
 {
     return(operations.GetLogAsync(deploymentId, deploymentLogId, CancellationToken.None));
 }