make BundledApps implement primitive interface

This commit is contained in:
Jonathan Shook
2022-08-16 00:42:58 -05:00
parent b395f14918
commit a0344d65c9
11 changed files with 35 additions and 17 deletions

View File

@@ -1,3 +1,19 @@
<!--
~ Copyright (c) 2022 nosqlbench
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an "AS IS" BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

View File

@@ -40,11 +40,11 @@ public class VirtDataMainApp implements BundledApp {
}
public static void main(String[] args) {
new VirtDataMainApp().appMain(args);
new VirtDataMainApp().applyAsInt(args);
}
@Override
public int appMain(String[] args) {
public int applyAsInt(String[] args) {
if (args.length == 0) {
System.out.println("Usage: app (" + APP_TESTMAPPER + "|" + APP_GENDOCS + "|" + APP_DIAGNOSE +")");
return 1;

View File

@@ -14,7 +14,7 @@
* limitations under the License.
*/
package io.nosqlbench.virtdata.userlibs.apps.valuesapp;
package io.nosqlbench.virtdata.userlibs.apps.valuechecker;
import io.nosqlbench.virtdata.core.bindings.ResolverDiagnostics;
import io.nosqlbench.virtdata.core.bindings.VirtData;
@@ -59,7 +59,7 @@ public class VirtDataCheckPerfApp {
runData = checker.call();
System.out.println(runData.toString());
} catch (Exception e) {
throw new RuntimeException("Error while checking performance: " + e.toString(), e);
throw new RuntimeException("Error while checking performance: " + e, e);
}
}