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

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


The following commit(s) were added to refs/heads/tracked-tag-for-history by 
this push:
     new 28f69f5  Current tracked branch: adding tag for filtering builds in 
history
28f69f5 is described below

commit 28f69f5b31b133111afebc96e191c29601839821
Author: Dmitriy Pavlov <[email protected]>
AuthorDate: Fri Jul 26 22:14:32 2019 +0300

    Current tracked branch: adding tag for filtering builds in history
---
 .../ignite/ci/tcbot/issue/IssueDetector.java       |  2 ++
 .../rest/tracked/GetTrackedBranchTestResults.java  | 23 ++++++++++++++-------
 ignite-tc-helper-web/src/main/webapp/current.html  | 24 +++++++++++-----------
 .../ci/tcbot/chain/TrackedBranchProcessorTest.java |  2 +-
 .../tracked/IDetailedStatusForTrackedBranch.java   |  5 ++++-
 .../tracked/TrackedBranchChainsProcessor.java      |  1 +
 6 files changed, 36 insertions(+), 21 deletions(-)

diff --git 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/tcbot/issue/IssueDetector.java
 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/tcbot/issue/IssueDetector.java
index d65449d..2a33891 100644
--- 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/tcbot/issue/IssueDetector.java
+++ 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/tcbot/issue/IssueDetector.java
@@ -578,6 +578,7 @@ public class IssueDetector {
             SyncMode.RELOAD_QUEUED,
             false,
             null,
+            null,
             DisplayMode.None,
             null,
             -1);
@@ -590,6 +591,7 @@ public class IssueDetector {
                 SyncMode.RELOAD_QUEUED,
                 false,
                 null,
+                null,
                 DisplayMode.OnlyFailures,
                 null,
                 -1);
diff --git 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/web/rest/tracked/GetTrackedBranchTestResults.java
 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/web/rest/tracked/GetTrackedBranchTestResults.java
index 0458eb2..1ff6d7c 100644
--- 
a/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/web/rest/tracked/GetTrackedBranchTestResults.java
+++ 
b/ignite-tc-helper-web/src/main/java/org/apache/ignite/ci/web/rest/tracked/GetTrackedBranchTestResults.java
@@ -67,12 +67,14 @@ public class GetTrackedBranchTestResults {
         @Nullable @QueryParam("checkAllLogs") Boolean checkAllLogs,
         @Nullable @QueryParam("trustedTests") Boolean trustedTests,
         @Nullable @QueryParam("tagSelected") String tagSelected,
+        @Nullable @QueryParam("tagForHistSelected") String tagForHistSelected,
         @Nullable @QueryParam("displayMode") String displayMode,
         @Nullable @QueryParam("sortOption") String sortOption,
         @Nullable @QueryParam("count") Integer mergeCnt,
         @Nullable @QueryParam("showTestLongerThan") Integer 
showTestLongerThan) {
-        return new 
UpdateInfo().copyFrom(getTestFailsResultsNoSync(branchOrNull, checkAllLogs, 
trustedTests, tagSelected,
-            displayMode, sortOption, mergeCnt, showTestLongerThan));
+        return new UpdateInfo().copyFrom(
+            getTestFailsResultsNoSync(branchOrNull, checkAllLogs, 
trustedTests, tagSelected, tagForHistSelected,
+                displayMode, sortOption, mergeCnt, showTestLongerThan));
     }
 
     @GET
@@ -82,11 +84,13 @@ public class GetTrackedBranchTestResults {
         @Nullable @QueryParam("checkAllLogs") Boolean checkAllLogs,
         @Nullable @QueryParam("trustedTests") Boolean trustedTests,
         @Nullable @QueryParam("tagSelected") String tagSelected,
+        @Nullable @QueryParam("tagForHistSelected") String tagForHistSelected,
         @Nullable @QueryParam("displayMode") String displayMode,
         @Nullable @QueryParam("sortOption") String sortOption,
         @Nullable @QueryParam("count") Integer mergeCnt,
         @Nullable @QueryParam("showTestLongerThan") Integer 
showTestLongerThan) {
-        return getTestFailsResultsNoSync(branchOrNull, checkAllLogs, 
trustedTests, tagSelected, displayMode, sortOption, mergeCnt, 
showTestLongerThan).toString();
+        return getTestFailsResultsNoSync(branchOrNull, checkAllLogs, 
trustedTests, tagSelected, tagForHistSelected,
+            displayMode, sortOption, mergeCnt, showTestLongerThan).toString();
     }
 
     @GET
@@ -96,11 +100,13 @@ public class GetTrackedBranchTestResults {
         @Nullable @QueryParam("checkAllLogs") Boolean checkAllLogs,
         @Nullable @QueryParam("trustedTests") Boolean trustedTests,
         @Nullable @QueryParam("tagSelected") String tagSelected,
+        @Nullable @QueryParam("tagForHistSelected") String tagForHistSelected,
         @Nullable @QueryParam("displayMode") String displayMode,
         @Nullable @QueryParam("sortOption") String sortOption,
         @Nullable @QueryParam("count") Integer mergeCnt,
         @Nullable @QueryParam("showTestLongerThan") Integer 
showTestLongerThan) {
-        return latestBuildResults(branch, checkAllLogs, trustedTests, 
tagSelected, SyncMode.NONE, displayMode, sortOption, mergeCnt, 
showTestLongerThan);
+        return latestBuildResults(branch, checkAllLogs, trustedTests, 
tagSelected, tagForHistSelected,
+            SyncMode.NONE, displayMode, sortOption, mergeCnt, 
showTestLongerThan);
     }
 
     @GET
@@ -111,11 +117,13 @@ public class GetTrackedBranchTestResults {
         @Nullable @QueryParam("checkAllLogs") Boolean checkAllLogs,
         @Nullable @QueryParam("trustedTests") Boolean trustedTests,
         @Nullable @QueryParam("tagSelected") String tagSelected,
+        @Nullable @QueryParam("tagForHistSelected") String tagForHistSelected,
         @Nullable @QueryParam("displayMode") String displayMode,
         @Nullable @QueryParam("sortOption") String sortOption,
         @Nullable @QueryParam("count") Integer mergeCnt,
         @Nullable @QueryParam("showTestLongerThan") Integer 
showTestLongerThan) {
-        return latestBuildResults(branch, checkAllLogs, trustedTests, 
tagSelected, SyncMode.RELOAD_QUEUED, displayMode, sortOption, mergeCnt, 
showTestLongerThan);
+        return latestBuildResults(branch, checkAllLogs, trustedTests, 
tagSelected, tagForHistSelected,
+            SyncMode.RELOAD_QUEUED, displayMode, sortOption, mergeCnt, 
showTestLongerThan);
     }
 
     @NotNull private DsSummaryUi latestBuildResults(
@@ -123,6 +131,7 @@ public class GetTrackedBranchTestResults {
         @Nullable Boolean checkAllLogs,
         @Nullable Boolean trustedTests,
         @Nullable String tagSelected,
+        @Nullable String tagForHistSelected,
         @Nonnull SyncMode mode,
         @Nullable String displayMode,
         @Nullable String sortOption,
@@ -138,7 +147,7 @@ public class GetTrackedBranchTestResults {
 
         return injector.getInstance(IDetailedStatusForTrackedBranch.class)
             .getTrackedBranchTestFailures(branch, checkAllLogs, 
actualMergeBuilds, creds, mode,
-                Boolean.TRUE.equals(trustedTests), tagSelected,
+                Boolean.TRUE.equals(trustedTests), tagSelected, 
tagForHistSelected,
                 DisplayMode.parseStringValue(displayMode),
                 SortOption.parseStringValue(sortOption),
                 maxDurationSec);
@@ -180,7 +189,7 @@ public class GetTrackedBranchTestResults {
 
         return injector.getInstance(TrackedBranchChainsProcessor.class)
             .getTrackedBranchTestFailures(branchOpt, checkAllLogs, cntLimit, 
creds, mode,
-                false, null, DisplayMode.OnlyFailures, null, -1);
+                false, null, null, DisplayMode.OnlyFailures, null, -1);
     }
 
     /**
diff --git a/ignite-tc-helper-web/src/main/webapp/current.html 
b/ignite-tc-helper-web/src/main/webapp/current.html
index f98cff9..31168e0 100644
--- a/ignite-tc-helper-web/src/main/webapp/current.html
+++ b/ignite-tc-helper-web/src/main/webapp/current.html
@@ -61,8 +61,8 @@ function showQueryForm() {
         data: {
             tagSelected: '',
             tagsPresent: [""],
-            tagForHistorySelected: '',
-            tagsForHistoryPresent: [],
+            tagForHistSelected: '',
+            tagsForHistPresent: [],
 
             displayMode: 'Failures',
             sortOption: 'FailureRate',
@@ -118,10 +118,10 @@ function showQueryForm() {
     if (showTestLongerThan != null)
         gVue.$data.showTestLongerThan = showTestLongerThan;
 
-    let tagForHistorySelected = findGetParameter("tagForHistorySelected");
-    if (tagForHistorySelected != null) {
-        gVue.$data.tagsForHistoryPresent.push(tagForHistorySelected);
-        gVue.$data.tagForHistorySelected = tagForHistorySelected;
+    let tagForHistSelected = findGetParameter("tagForHistSelected");
+    if (tagForHistSelected != null) {
+        gVue.$data.tagsForHistPresent.push(tagForHistSelected);
+        gVue.$data.tagForHistSelected = tagForHistSelected;
     }
 
     genLink();
@@ -177,8 +177,8 @@ function parmsForRest() {
 
     curReqParms += "&hideFlakyFailures=" + gVue.$data.hideFlakyFailures;
 
-    if (gVue.$data.tagForHistorySelected != null)
-        curReqParms += "&tagForHistorySelected=" + 
gVue.$data.tagForHistorySelected;
+    if (gVue.$data.tagForHistSelected != null)
+        curReqParms += "&tagForHistSelected=" + gVue.$data.tagForHistSelected;
 
     if (gVue.$data.showTestLongerThan != null)
         curReqParms += "&showTestLongerThan=" + gVue.$data.showTestLongerThan;
@@ -267,7 +267,7 @@ function loadPartialData() {
 
 function showData(result) {
     let setOfTags = new Set(gVue.$data.tagsPresent);
-    let setOfHistTags = new Set(gVue.$data.tagForHistorySelected);
+    let setOfHistTags = new Set(gVue.$data.tagForHistSelected);
     for (let i = 0; i < result.servers.length; i++) {
         let chain = result.servers[i];
 
@@ -286,7 +286,7 @@ function showData(result) {
     }
 
     gVue.$data.tagsPresent = Array.from(setOfTags);
-    gVue.$data.tagsForHistoryPresent = Array.from(setOfHistTags);
+    gVue.$data.tagsForHistPresent = Array.from(setOfHistTags);
 
     //var txtUrl = "rest/tracked/results/txt" + parmsForRest();
 
@@ -321,10 +321,10 @@ function showData(result) {
                         </select>
 
                         <span title="Tag filter for filtering history of 
suites">History tag filter: </span>
-                        <select v-model="tagForHistorySelected" 
@change="formChanged">
+                        <select v-model="tagForHistSelected" 
@change="formChanged">
                             <option disabled value="">Please select 
one</option>
 
-                            <option v-for="option in tagsForHistoryPresent" 
v-bind:value="option">
+                            <option v-for="option in tagsForHistPresent" 
v-bind:value="option">
                                 {{ option }}
                             </option>
                         </select>
diff --git 
a/ignite-tc-helper-web/src/test/java/org/apache/ignite/ci/tcbot/chain/TrackedBranchProcessorTest.java
 
b/ignite-tc-helper-web/src/test/java/org/apache/ignite/ci/tcbot/chain/TrackedBranchProcessorTest.java
index c1f83fc..0720d39 100644
--- 
a/ignite-tc-helper-web/src/test/java/org/apache/ignite/ci/tcbot/chain/TrackedBranchProcessorTest.java
+++ 
b/ignite-tc-helper-web/src/test/java/org/apache/ignite/ci/tcbot/chain/TrackedBranchProcessorTest.java
@@ -121,7 +121,7 @@ public class TrackedBranchProcessorTest {
             false,
             1,
             mock, SyncMode.RELOAD_QUEUED,
-            false, null, DisplayMode.OnlyFailures, null,
+            false, null, null, DisplayMode.OnlyFailures, null,
             -1);
 
         Gson gson = new GsonBuilder().setPrettyPrinting().create();
diff --git 
a/tcbot-engine/src/main/java/org/apache/ignite/tcbot/engine/tracked/IDetailedStatusForTrackedBranch.java
 
b/tcbot-engine/src/main/java/org/apache/ignite/tcbot/engine/tracked/IDetailedStatusForTrackedBranch.java
index 5621432..4edad4a 100644
--- 
a/tcbot-engine/src/main/java/org/apache/ignite/tcbot/engine/tracked/IDetailedStatusForTrackedBranch.java
+++ 
b/tcbot-engine/src/main/java/org/apache/ignite/tcbot/engine/tracked/IDetailedStatusForTrackedBranch.java
@@ -34,6 +34,7 @@ public interface IDetailedStatusForTrackedBranch {
      * @param syncMode Sync mode.
      * @param calcTrustedTests Calculate trusted tests count.
      * @param tagSelected Selected tag based filter. If null or empty all data 
is returned.
+     * @param tagForHistSelected Selected tag for filtering history 
(applicable to reruns and history stripe).
      * @param displayMode Suites and tests display mode. Default - failures 
only.
      * @param sortOption Sort mode
      * @param maxDurationSec Show test as failed if duration is greater than 
provided seconds count.
@@ -46,8 +47,10 @@ public interface IDetailedStatusForTrackedBranch {
         SyncMode syncMode,
         boolean calcTrustedTests,
         @Nullable String tagSelected,
+        @Nullable String tagForHistSelected,
         @Nullable DisplayMode displayMode,
-        @Nullable SortOption sortOption, int maxDurationSec);
+        @Nullable SortOption sortOption,
+        int maxDurationSec);
 
     //  * @param baseTrackedBranch Branch tracked branch in Bot, has a 
priority if both TC & Bot branches (baseBranchForTcParm) present.
 }
diff --git 
a/tcbot-engine/src/main/java/org/apache/ignite/tcbot/engine/tracked/TrackedBranchChainsProcessor.java
 
b/tcbot-engine/src/main/java/org/apache/ignite/tcbot/engine/tracked/TrackedBranchChainsProcessor.java
index 7bf1aba..3cdd780 100644
--- 
a/tcbot-engine/src/main/java/org/apache/ignite/tcbot/engine/tracked/TrackedBranchChainsProcessor.java
+++ 
b/tcbot-engine/src/main/java/org/apache/ignite/tcbot/engine/tracked/TrackedBranchChainsProcessor.java
@@ -69,6 +69,7 @@ public class TrackedBranchChainsProcessor implements 
IDetailedStatusForTrackedBr
         SyncMode syncMode,
         boolean calcTrustedTests,
         @Nullable String tagSelected,
+        @Nullable String tagForHistSelected,
         @Nullable DisplayMode displayMode,
         @Nullable SortOption sortOption,
         int maxDurationSec) {

Reply via email to