SomeFire commented on a change in pull request #15: Incremental build upload URL: https://github.com/apache/ignite-teamcity-bot/pull/15#discussion_r219076597
########## File path: ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/IgnitePersistentTeamcity.java ########## @@ -297,9 +303,25 @@ public void init(String serverId) { //todo sinceBuild:(number:) // --todo -10 build numbers + Integer sinceBuildNumber = null; + if(persistedBuilds!=null) { + List<BuildRef> prevData = persistedBuilds.getData(); + if (prevData.size() > 10) { + BuildRef buildRef = prevData.get(prevData.size() - 10); + + if (!Strings.isNullOrEmpty(buildRef.buildNumber)) { + try { + sinceBuildNumber = Integer.valueOf(buildRef.buildNumber); + } catch (NumberFormatException e) { + logger.info("", e); + } + } + } + } List<BuildRef> dataFromRest; try { - dataFromRest = realLoad.apply(key); + dataFromRest = realLoad.apply(key, sinceBuildNumber); + Review comment: Redundant empty line. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services