public void FailedSegmentHandler(object sender, Segment segment, FailedStatus failedstatus) { //HANDLE FAILED SEGMENT FOR CONNECTION if (failedstatus != FailedStatus.Disconnected) { segment.AddFailedServer(m_Hostname); } OnFailedSegment(this, segment, failedstatus); }
private void FailedSegmentHandler(object sender, Segment segment, FailedStatus failedstatus) { //HANDLE FAILED SEGMENT FOR SERVER foreach (Server server in m_Servers) { if (!segment.FailedServers.Contains(server.Hostname) && server.Enabled) { server.DownloadQueue.Enqueue(segment); return; } } OnFailedSegment(this, segment, failedstatus); }
public void FailedSegmentHandler(object sender, Segment segment, FailedStatus failedstatus) { //HANDLE FAILED SEGMENT FROM SERVER GROUP for (int i = m_ServerGroups.IndexOf((ServerGroup)sender) + 1; i < m_ServerGroups.Count; i++) { if (m_ServerGroups[i] != null) { ((ServerGroup)m_ServerGroups[i]).DownloadQueue.Enqueue(segment); return; } } segment.Article.Status = ArticleStatus.Incomplete; frmMain.LogWriteError("Segment not found on any servers: " + segment.ArticleID); return; }
public void FailedSegmentHandler(object sender, Segment segment, FailedStatus failedstatus) { //HANDLE FAILED SEGMENT FOR CONNECTION if( failedstatus != FailedStatus.Disconnected) segment.AddFailedServer(m_Hostname); OnFailedSegment(this, segment, failedstatus); }
public void FailedSegmentHandler(object sender, Segment segment, FailedStatus failedstatus) { //HANDLE FAILED SEGMENT FROM SERVER GROUP for(int i = m_ServerGroups.IndexOf((ServerGroup)sender) + 1; i < m_ServerGroups.Count; i++) { if(m_ServerGroups[i] != null) { ((ServerGroup)m_ServerGroups[i]).DownloadQueue.Enqueue(segment); return; } } segment.Article.Status = ArticleStatus.Incomplete; frmMain.LogWriteError("Segment not found on any servers: " + segment.ArticleID); return; }
private void FailedSegmentHandler(object sender, Segment segment, FailedStatus failedstatus) { //HANDLE FAILED SEGMENT FOR SERVER foreach(Server server in m_Servers) if(!segment.FailedServers.Contains(server.Hostname) && server.Enabled) { server.DownloadQueue.Enqueue(segment); return; } OnFailedSegment(this, segment, failedstatus); }