From 5fca6a4d829ad6c77fffd772a4006e885129b79b Mon Sep 17 00:00:00 2001 From: Dennis Gove Date: Tue, 13 Jun 2017 09:35:16 -0400 Subject: [PATCH] SOLR-10882: Rewords error message on Anova evaluator --- .../org/apache/solr/client/solrj/io/eval/AnovaEvaluator.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/solr/solrj/src/java/org/apache/solr/client/solrj/io/eval/AnovaEvaluator.java b/solr/solrj/src/java/org/apache/solr/client/solrj/io/eval/AnovaEvaluator.java index 45c3c3f32b7..ca962f1513c 100644 --- a/solr/solrj/src/java/org/apache/solr/client/solrj/io/eval/AnovaEvaluator.java +++ b/solr/solrj/src/java/org/apache/solr/client/solrj/io/eval/AnovaEvaluator.java @@ -19,6 +19,7 @@ package org.apache.solr.client.solrj.io.eval; import java.io.IOException; import java.util.ArrayList; import java.util.List; +import java.util.Locale; import java.util.HashMap; import java.util.Map; @@ -38,8 +39,8 @@ public class AnovaEvaluator extends ComplexEvaluator implements Expressible { public AnovaEvaluator(StreamExpression expression, StreamFactory factory) throws IOException { super(expression, factory); - if(subEvaluators.size() < 2) { - throw new IOException("ANOVA evaluator expects atleast 2 parameters found: "+subEvaluators.size()); + if(subEvaluators.size() < 2){ + throw new IOException(String.format(Locale.ROOT,"Invalid expression %s - expecting at least two values but found %d",expression,subEvaluators.size())); } }