This is an automated email from the ASF dual-hosted git repository.

dpavlov pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ignite-teamcity-bot.git


The following commit(s) were added to refs/heads/master by this push:
     new fad0b3f  Bug fix on scheduled not found builds upload
fad0b3f is described below

commit fad0b3fb745b987cefa9215ba585be30663eb21b
Author: Dmitriy Pavlov <[email protected]>
AuthorDate: Fri Oct 26 21:56:16 2018 +0300

    Bug fix on scheduled not found builds upload
---
 .../org/apache/ignite/ci/teamcity/ignited/TeamcityIgnitedImpl.java   | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/teamcity/ignited/TeamcityIgnitedImpl.java
 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/teamcity/ignited/TeamcityIgnitedImpl.java
index 4abf7cd..f32d335 100644
--- 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/teamcity/ignited/TeamcityIgnitedImpl.java
+++ 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/teamcity/ignited/TeamcityIgnitedImpl.java
@@ -238,11 +238,10 @@ public class TeamcityIgnitedImpl implements 
ITeamcityIgnited {
     void actualizeRecentBuilds() {
         List<BuildRefCompacted> running = 
buildRefDao.getQueuedAndRunning(srvIdMaskHigh);
 
-        List<Integer> runningIds = 
running.stream().map(BuildRefCompacted::id).collect(Collectors.toList());
-
         Set<Integer> paginateUntil = new HashSet<>();
         Set<Integer> directUpload = new HashSet<>();
 
+        List<Integer> runningIds = 
running.stream().map(BuildRefCompacted::id).collect(Collectors.toList());
         OptionalInt max = runningIds.stream().mapToInt(i -> i).max();
         if (max.isPresent()) {
             runningIds.forEach(id->{
@@ -259,7 +258,7 @@ public class TeamcityIgnitedImpl implements 
ITeamcityIgnited {
 
         if(!paginateUntil.isEmpty()) {
             //some builds may stuck in the queued or running, enforce loading 
as well
-            directUpload.addAll(paginateUntil);
+            scheduleBuildsLoad(paginateUntil);
         }
 
         // schedule full resync later

Reply via email to