Skip to content

Commit

Permalink
Fixed bug that could not detect TooManyError
Browse files Browse the repository at this point in the history
  • Loading branch information
donggyu04 authored and junoyoon committed Feb 13, 2019
1 parent 98d4e69 commit 4f22459
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -927,14 +927,15 @@ public ConsoleProperties createConsoleProperties(PerfTest perfTest) {
}

/**
* Check if the given perfTest has too many errors. (20%)
* Check if the given perfTest has too many errors. (30%)
*
* @param perfTest perftest
* @return true if too many errors.
*/
@SuppressWarnings("unchecked")
public boolean hasTooManyError(PerfTest perfTest) {
Map<String, Object> result = getStatistics(perfTest);
SamplingModel samplingModel = hazelcastService.get(CACHE_SAMPLING, perfTest.getId());
Map<String, Object> result = gson.fromJson(samplingModel.getRunningSample(), HashMap.class);
Map<String, Object> totalStatistics = MapUtils.getMap(result, "totalStatistics", MapUtils.EMPTY_MAP);
long tests = MapUtils.getDouble(totalStatistics, "Tests", 0D).longValue();
long errors = MapUtils.getDouble(totalStatistics, "Errors", 0D).longValue();
Expand Down

0 comments on commit 4f22459

Please sign in to comment.