I'm a Service Broker virgin and just did some quick reading about it and will need to study up about it. I'm not really sure about what more details you would require but basically:
If there is a timeout, (perhaps) queue the missed download and try it again after all the other downloads are complete. My code that I am running looks like:Try
' Logging start of download
Dim fireAgain As Boolean = True
Dts.Events.FireInformation(0, "Download File", "Start downloading " + Dts.Variables("User::httpConnection").Value.ToString(), String.Empty, 0, fireAgain)
' Create a webclient to download a file
Dim mySSISWebClient As WebClient = New WebClient()
Dim pt As String
pt = Dts.Variables("User::fileName").Value.ToString + ".zip"
' Download file and use the Flat File Connectionstring (D:\SourceFiles\Products.csv)
' to save the file (and replace the existing file)
mySSISWebClient.DownloadFile(Dts.Variables("User::httpConnection").Value.ToString, "\\EWPG-SERVICE-60\FA-BUSANALYEC\EconomicDBTemp\DownloadedCSVs\" + Dts.Variables("User::fileName").Value.ToString + ".zip")
Dts.Variables("User::FullPathTitle").Value = Dts.Variables("User::SaveFile").Value.ToString + pt
Dts.Variables("User::FileNameDel").Value = Dts.Variables("User::fileName").Value.ToString
' Logging end of download
Dts.Events.FireInformation(0, "Download File", "Finished downloading " + Dts.Variables("User::SaveFile").Value.ToString(), String.Empty, 0, fireAgain)
' Quit Script Task succesful
Dts.TaskResult = ScriptResults.Success
Catch ex As Exception
' Logging why download failed
Dts.Events.FireError(0, "Download File", "Download failed: " + ex.Message, String.Empty, 0)
' Quit Script Task unsuccesful
Dts.TaskResult = ScriptResults.Failure
End TryPlease let me know what I am missing regarding more information and I will gladly provide it. Thanks a bunch!
Regards:
Mordred
Keep on Coding in the Free World