From 4728a572a5bb06320d76f0b69543d03c5d369d0f Mon Sep 17 00:00:00 2001 From: "U-BASIS\\zhaohui" Date: Wed, 29 Mar 2017 15:45:27 -0400 Subject: [PATCH 1/2] 2297: make ngihtly test on single ingest thread to avoid fe_image_test_4 test results in different order --- .../src/org/sleuthkit/autopsy/testing/RegressionTest.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Testing/test/qa-functional/src/org/sleuthkit/autopsy/testing/RegressionTest.java b/Testing/test/qa-functional/src/org/sleuthkit/autopsy/testing/RegressionTest.java index 112984b33b..d62dffd155 100755 --- a/Testing/test/qa-functional/src/org/sleuthkit/autopsy/testing/RegressionTest.java +++ b/Testing/test/qa-functional/src/org/sleuthkit/autopsy/testing/RegressionTest.java @@ -25,6 +25,7 @@ import junit.framework.Test; import junit.framework.TestCase; import org.netbeans.jemmy.Timeouts; import org.netbeans.junit.NbModuleSuite; +import org.sleuthkit.autopsy.core.UserPreferences; /** * This test expects the following system properties to be set: img_path: The @@ -98,6 +99,7 @@ public class RegressionTest extends TestCase { public void setUp() { logger.info("######## " + AutopsyTestCases.getEscapedPath(System.getProperty("img_path")) + " #######"); Timeouts.setDefault("ComponentOperator.WaitComponentTimeout", 1000000); + UserPreferences.setNumberOfFileIngestThreads(1); //Let nightly test using 1 ingest thread to avoid ordering results in report of insertion to tsk tables } /** From 7f034bf87168260803b1c94b5a7aaa84d759101b Mon Sep 17 00:00:00 2001 From: Eugene Livis Date: Wed, 29 Mar 2017 15:46:57 -0400 Subject: [PATCH 2/2] Fix to have same key word in multiple KW lists --- .../org/sleuthkit/autopsy/keywordsearch/SearchRunner.java | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/KeywordSearch/src/org/sleuthkit/autopsy/keywordsearch/SearchRunner.java b/KeywordSearch/src/org/sleuthkit/autopsy/keywordsearch/SearchRunner.java index 560a90d0db..6db8b6beb3 100644 --- a/KeywordSearch/src/org/sleuthkit/autopsy/keywordsearch/SearchRunner.java +++ b/KeywordSearch/src/org/sleuthkit/autopsy/keywordsearch/SearchRunner.java @@ -370,7 +370,7 @@ public final class SearchRunner { private List keywords; //keywords to search private List keywordListNames; // lists currently being searched private List keywordLists; - private Map keywordToList; //keyword to list name mapping + private Map keywordToList; //keyword to list name mapping private AggregateProgressHandle progressGroup; private final Logger logger = Logger.getLogger(SearchRunner.Searcher.class.getName()); private boolean finalRun = false; @@ -431,8 +431,7 @@ public final class SearchRunner { return null; } - final String queryStr = keyword.getSearchTerm(); - final KeywordList keywordList = keywordToList.get(queryStr); + final KeywordList keywordList = keywordToList.get(keyword); //new subProgress will be active after the initial query //when we know number of hits to start() with @@ -545,7 +544,7 @@ public final class SearchRunner { keywordLists.add(list); for (Keyword k : list.getKeywords()) { keywords.add(k); - keywordToList.put(k.getSearchTerm(), list); + keywordToList.put(k, list); } } }