summaryrefslogtreecommitdiffstats
path: root/model-integration
diff options
context:
space:
mode:
authorJon Bratseth <bratseth@gmail.com>2022-05-16 09:02:39 +0200
committerJon Bratseth <bratseth@gmail.com>2022-05-16 09:02:39 +0200
commit6a18cd0de7c7d593d61e2162690fc46698651da4 (patch)
treee6d9f2cb8464368bd22ffefac5ef0996718ac4e5 /model-integration
parentbbe92324857195e87affc35235218c9417ec415a (diff)
Revert "Revert "Bratseth/constants cleanup 2""
This reverts commit 02f96c03fd5b434788e1c5e77436c99bb7562f77.
Diffstat (limited to 'model-integration')
-rw-r--r--model-integration/src/main/java/ai/vespa/rankingexpression/importer/configmodelview/ImportedMlModels.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/model-integration/src/main/java/ai/vespa/rankingexpression/importer/configmodelview/ImportedMlModels.java b/model-integration/src/main/java/ai/vespa/rankingexpression/importer/configmodelview/ImportedMlModels.java
index 367b840a728..1003ebd8f3f 100644
--- a/model-integration/src/main/java/ai/vespa/rankingexpression/importer/configmodelview/ImportedMlModels.java
+++ b/model-integration/src/main/java/ai/vespa/rankingexpression/importer/configmodelview/ImportedMlModels.java
@@ -3,6 +3,7 @@ package ai.vespa.rankingexpression.importer.configmodelview;
import com.yahoo.concurrent.InThreadExecutorService;
import com.yahoo.path.Path;
+import com.yahoo.yolean.Exceptions;
import java.io.File;
import java.util.Arrays;
@@ -55,7 +56,7 @@ public class ImportedMlModels {
models.put(name, model);
}
} catch (InterruptedException | ExecutionException e) {
- skippedModels.put(name, e.getMessage());
+ skippedModels.put(name, Exceptions.toMessageString(e));
}
});
importedModels = Collections.unmodifiableMap(models);
@@ -97,7 +98,7 @@ public class ImportedMlModels {
if (existing != null) {
try {
throw new IllegalArgumentException("The models in " + child + " and " + existing.get().source() +
- " both resolve to the model name '" + name + "'");
+ " both resolve to the model name '" + name + "'");
} catch (InterruptedException | ExecutionException e) {}
}