Open tpalus opened 3 years ago
Hi, I have the same problem.
I have seen the MSCRMPackageDeployer.ps1 file, and It is passing the parameter timeout
& "$mscrmToolsPath\xRMCIFramework\9.0.0\DeployPackage.ps1" -CrmConnectionString $crmConnectionString -PackageName $packageName -PackageDirectory $packageDirectory -LogsDirectory $tempFolder -toolingConnectorModulePath $CrmConnectorPath -PackageDeploymentPath $PackageDeploymentPath -Timeout $pdTimeout -crmConnectionTimeout $crmConnectionTimeout -unpackFilesDirectory $unpackFilesDirectory -runtimePackageSettings $runtimePackageSettings
And, the file DeployPackage.ps1 has the parameter, with 2 minutes by default
#
# DeployPackage.ps1
#
param(
[string]$CrmConnectionString,
[string]$PackageName,
[string]$PackageDirectory,
[string]$LogsDirectory = '',
[string]$PackageDeploymentPath,
[string]$ToolingConnectorModulePath,
[string]$Timeout = '00:30:00', #optional timeout for Import-CrmPackage, default to 1 hour and 20 min. See https://technet.microsoft.com/en-us/library/dn756301.aspx
[int]$CrmConnectionTimeout = 2,
[string]$RuntimePackageSettings,
[string]$UnpackFilesDirectory
)
and
#Create Connection
$CRMConn = Get-CrmConnection -ConnectionString "$CrmConnectionString" -LogWriteDirectory "$LogsDirectory" -MaxCrmConnectionTimeOutMinutes $CrmConnectionTimeout -Verbose
#Deploy Package
$PackageParams = @{
CrmConnection = $CRMConn
PackageDirectory = "$PackageDirectory"
PackageName = $PackageName
LogWriteDirectory = "$LogsDirectory"
Timeout = $Timeout
}
if ($UnpackFilesDirectory)
{
$PackageParams.UnpackFilesDirectory = $UnpackFilesDirectory
}
if ($RuntimePackageSettings)
{
$PackageParams.RuntimePackageSettings = $RuntimePackageSettings
}
Import-CrmPackage @PackageParams -Verbose
Please, I need this
Hi, I can manage to fix it, I have to use the config UseAsyncForSolutionImport=true. This is in the file PackageDeployer.exe.config, but It only work when I use PackageDeployer.exe In task, I have to create a config file, similar to PackageDeployer.exe.config, with only appSettings tag
`<?xml version="1.0"?>
@dga205 thanks for sharing this.
What type of parameter do you suggest to add to the task? A path to a config file that contains some additional settings?
@dga205 It's possible to set this in the importconfig.xml
on the configsolutionfile
node by setting the requiredimportmode
attribute to async
.
Hi, I've got issue with MSCRM Package Deployer. Whenever I try to deploy solutions to a new environment trough pipeline, it takes a long time and eventually it failed. After 3 attempts it is finally successful and the deploy passes. Error displayed on unsuccessful attempts:
FAILED : : **** TimeoutException - DeleteAndPromote : Delete and Promote Solution to New version(DeleteAndPromoteSolutionRequest) |=> The request channel timed out while waiting for a reply after 00:02:00. Increase the timeout value passed to the call to Request or increase the SendTimeout value on the Binding. The time allotted to this operation may have been a portion of a longer timeout.
2020-11-02T07:12:28.1862576Z The request channel timed out while waiting for a reply after 00:02:00. Increase the timeout value passed to the call to Request or increase the SendTimeout value on the Binding. The time allotted to this operation may have been a portion of a longer timeout. => The HTTP request to 'https://xxxxxxx-uat.crm4.dynamics.com/XRMServices/2011/Organization.svc/web?SDKClientVersion=9.0.45.2156' has exceeded the allotted timeout of 00:02:00. The time allotted to this operation may have been a portion of a longer timeout. => The operation has timed out 2020-11-02T07:12:28.1863856Z Source : mscorlib 2020-11-02T07:12:28.1864140Z Method : HandleReturnMessage 2020-11-02T07:12:28.1864671Z Date : 7:12:28 AM 2020-11-02T07:12:28.1864948Z Time : 11/2/2020 2020-11-02T07:12:28.1865848Z Error : The request channel timed out while waiting for a reply after 00:02:00. Increase the timeout value passed to the call to Request or increase the SendTimeout value on the Binding. The time allotted to this operation may have been a portion of a longer timeout.
Has anyone encountered a similar problem? I will be happy for any help :)