mirror of
https://github.com/nosqlbench/nosqlbench.git
synced 2025-02-25 18:55:28 -06:00
merge fixes
This commit is contained in:
commit
3b6e99faa2
@ -4,8 +4,8 @@
|
||||
<parent>
|
||||
<groupId>io.nosqlbench</groupId>
|
||||
<artifactId>mvn-defaults</artifactId>
|
||||
<version>4.15.45-SNAPSHOT</version>
|
||||
<relativePath>../mvn-defaults/pom.xml</relativePath>
|
||||
<version>4.15.47-SNAPSHOT</version>
|
||||
<relativePath>../mvn-defaults</relativePath>
|
||||
</parent>
|
||||
|
||||
<artifactId>driver-cqld4</artifactId>
|
||||
@ -23,19 +23,19 @@
|
||||
<dependency>
|
||||
<groupId>io.nosqlbench</groupId>
|
||||
<artifactId>engine-api</artifactId>
|
||||
<version>4.15.45-SNAPSHOT</version>
|
||||
<version>4.15.47-SNAPSHOT</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.nosqlbench</groupId>
|
||||
<artifactId>drivers-api</artifactId>
|
||||
<version>4.15.45-SNAPSHOT</version>
|
||||
<version>4.15.47-SNAPSHOT</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>io.nosqlbench</groupId>
|
||||
<artifactId>virtdata-lib-basics</artifactId>
|
||||
<version>4.15.45-SNAPSHOT</version>
|
||||
<version>4.15.47-SNAPSHOT</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
|
@ -4,8 +4,8 @@
|
||||
<parent>
|
||||
<artifactId>mvn-defaults</artifactId>
|
||||
<groupId>io.nosqlbench</groupId>
|
||||
<version>4.15.45-SNAPSHOT</version>
|
||||
<relativePath>../mvn-defaults/pom.xml</relativePath>
|
||||
<version>4.15.47-SNAPSHOT</version>
|
||||
<relativePath>../mvn-defaults</relativePath>
|
||||
</parent>
|
||||
|
||||
<artifactId>driver-direct</artifactId>
|
||||
@ -21,12 +21,12 @@
|
||||
<dependency>
|
||||
<groupId>io.nosqlbench</groupId>
|
||||
<artifactId>drivers-api</artifactId>
|
||||
<version>4.15.45-SNAPSHOT</version>
|
||||
<version>4.15.47-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.nosqlbench</groupId>
|
||||
<artifactId>engine-api</artifactId>
|
||||
<version>4.15.45-SNAPSHOT</version>
|
||||
<version>4.15.47-SNAPSHOT</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
|
@ -1,27 +1,51 @@
|
||||
package io.nosqlbench.engine.api.activityconfig.rawyaml;
|
||||
|
||||
import com.vladsch.flexmark.ast.FencedCodeBlock;
|
||||
import com.vladsch.flexmark.util.ast.Node;
|
||||
|
||||
import java.nio.file.Path;
|
||||
import java.util.Objects;
|
||||
|
||||
final class TestSet {
|
||||
private final String desc;
|
||||
private final Path path;
|
||||
private final int line;
|
||||
public CharSequence info;
|
||||
public CharSequence text;
|
||||
|
||||
public TestSet(String description, CharSequence info, CharSequence text) {
|
||||
public TestSet(String desc, Node infoNode, Node dataNode, Path path) {
|
||||
this.desc = desc;
|
||||
this.info = infoNode.getChars();
|
||||
this.text = dataNode.getFirstChild().getChars();
|
||||
this.line = dataNode.getFirstChild().getLineNumber();
|
||||
this.path = path;
|
||||
}
|
||||
|
||||
public TestSet(String description, CharSequence info, CharSequence text, Path path, int line) {
|
||||
this.desc = description;
|
||||
this.info = info;
|
||||
this.text = text;
|
||||
this.path = path;
|
||||
this.line = line;
|
||||
}
|
||||
|
||||
public TestSet(String description, FencedCodeBlock node) {
|
||||
public TestSet(String description, FencedCodeBlock node, Path path) {
|
||||
this.desc = description;
|
||||
this.info = node.getInfo();
|
||||
text = Objects.requireNonNull(node.getFirstChild()).getChars();
|
||||
this.path = path;
|
||||
this.line = node.getLineNumber();
|
||||
}
|
||||
|
||||
public String getDesc() {
|
||||
return desc;
|
||||
}
|
||||
|
||||
public Path getPath() {
|
||||
return path;
|
||||
}
|
||||
|
||||
public int getLine() {
|
||||
return line;
|
||||
}
|
||||
}
|
||||
|
@ -77,7 +77,7 @@ public class UniformYamlRawReaderTest {
|
||||
|
||||
LinkedList<TestSet> tests = new LinkedList<>();
|
||||
|
||||
List<Content<?>> yaml = NBIO.fs().prefix("target/test-classes/workload_definition/").name("templated_workloads").extension("md").list();
|
||||
List<Content<?>> yaml = NBIO.fs().prefix("target/classes/workload_definition/").name("templated_workloads").extension("md").list();
|
||||
|
||||
Pattern emphasis = Pattern.compile("\\*(.*?)\\*\n");
|
||||
Class<?> fcbclass = FencedCodeBlock.class;
|
||||
@ -98,14 +98,15 @@ public class UniformYamlRawReaderTest {
|
||||
node = node.getNext();
|
||||
index=0;
|
||||
}
|
||||
|
||||
if (p.test(node)) {
|
||||
List<Node> found = p.get();
|
||||
// System.out.println(summarize(found));
|
||||
String label = heading + String.format("-%02d", (++index));
|
||||
testblocks.add(new TestBlock(
|
||||
new TestSet(label,found.get(0).getChars(),found.get(1).getFirstChild().getChars()),
|
||||
new TestSet(label,found.get(2).getChars(),found.get(3).getFirstChild().getChars()),
|
||||
new TestSet(label,found.get(4).getChars(),found.get(5).getFirstChild().getChars())
|
||||
new TestSet(label,found.get(0),found.get(1),content.asPath()),
|
||||
new TestSet(label,found.get(2),found.get(3),content.asPath()),
|
||||
new TestSet(label,found.get(4),found.get(5),content.asPath())
|
||||
));
|
||||
node=found.get(found.size()-1);
|
||||
}
|
||||
@ -285,12 +286,12 @@ public class UniformYamlRawReaderTest {
|
||||
*/
|
||||
private void validateYamlWithJson(String desc, String yaml, String json) {
|
||||
System.out.format("%-40s","- checking yaml->json");
|
||||
List<Map<String, Object>> docmaps = new RawYamlLoader().loadString(logger, yaml);
|
||||
|
||||
StmtsDocList stmts = StatementsLoader.loadString(yaml);
|
||||
// StmtsDocList stmts = StatementsLoader.loadString(yaml);
|
||||
JsonParser parser = new JsonParser();
|
||||
|
||||
try {
|
||||
List<Map<String, Object>> docmaps = new RawYamlLoader().loadString(logger, yaml);
|
||||
JsonElement elem = parser.parse(json);
|
||||
if (elem.isJsonArray()) {
|
||||
Type type = new TypeToken<List<Map<String, Object>>>() {
|
||||
|
@ -500,7 +500,7 @@ public class GrafanaClient {
|
||||
try {
|
||||
response = client.send(rq, HttpResponse.BodyHandlers.ofString());
|
||||
} catch (Exception e) {
|
||||
if (e.getMessage().contains("WWW-Authenticate header missing")) {
|
||||
if (e.getMessage()!=null && e.getMessage().contains("WWW-Authenticate header missing")) {
|
||||
throw new RuntimeException("Java HttpClient was not authorized, and it saw no WWW-Authenticate header" +
|
||||
" in the response, so this is probably Grafana telling you that the auth scheme failed. Normally " +
|
||||
"this error would be thrown by Java HttpClient:" + e.getMessage());
|
||||
|
@ -225,7 +225,7 @@
|
||||
<dependency>
|
||||
<groupId>io.nosqlbench</groupId>
|
||||
<artifactId>driver-cqld4</artifactId>
|
||||
<version>4.15.45-SNAPSHOT</version>
|
||||
<version>4.15.47-SNAPSHOT</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</profile>
|
||||
|
Loading…
Reference in New Issue
Block a user