Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deploy reports error: error downloading asmx file happening intermittently #83

Open
thunt999 opened this issue Jun 8, 2023 · 3 comments

Comments

@thunt999
Copy link

thunt999 commented Jun 8, 2023

deploying ssrs fails with "downloading asmx file" first run each day, immediate redeploy and it works . it would appear not to be permissions related as it works second time, so any ideas ?

@mwhisler
Copy link

I have the same issue. Lots of 503s too, but I get the intermittent asmx download quite often. This task is running against an Azure VM.

@mwhisler
Copy link

Could we try obtaining that proxy in a way that is more resilient to connection issues? I have been troubleshooting this issue for years and can't seem to find a solution other than a redeploy.

function Get-SSRSProxyWithRetries {
param (
[Parameter(Mandatory=$true)]
[string]$Url,
[Parameter(Mandatory=$true)]
[string]$AuthScheme,
[string]$Username,
[string]$Password,
[int]$RetryCount = 3,
[int]$RetryDelaySeconds = 5
)

$proxy = $null

for ($retry = 1; $retry -le $RetryCount; $retry++)
{
    try
    {
        if ($AuthScheme -eq "windowsAuthentication")
        {
            $proxy = New-WebServiceProxy -Uri $Url -Namespace SSRS.ReportingService2010 -UseDefaultCredential -Class "SSRS"
        }
        else
        {
            $securePassword = ConvertTo-SecureString -String $Password -AsPlainText -Force
            $credential = New-Object -TypeName System.Management.Automation.PSCredential -ArgumentList $Username, $securePassword
        
            $proxy = New-WebServiceProxy -Uri $Url -Namespace SSRS.ReportingService2010 -Credential $credential -Class "SSRS"
        }

        # Connection succeeded, break out of the retry loop
        break
    }
    catch
    {
        Write-Host "Failed to connect to the SSRS server. Retrying in $RetryDelaySeconds seconds..."
        Start-Sleep -Seconds $RetryDelaySeconds
    }
}

if (-not $proxy)
{
    throw "Failed to establish a connection to the SSRS server after $RetryCount retries."
}

return $proxy

}

@mmajcica
Copy link
Owner

Gents, I have no time/resources to support this. In case you have improvements/fixes, you would like to share, I would be more than happy to merge a PR and publish a new version or assist you in any other way.

Cheers

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants