Skip to content
Permalink
Browse files
Fix build warnings in a few classes due to deprication
  • Loading branch information
Manno15 committed Nov 24, 2021
1 parent ccce2d6 commit dc18e215068e6cce3048bc860739f737b2807f67
Showing 3 changed files with 4 additions and 3 deletions.
@@ -32,7 +32,7 @@ public static void main(String[] args) throws Exception {
Path confFile = Paths.get(args[1], "accumulo.properties");

PerformanceTest perfTest = Class.forName(className).asSubclass(PerformanceTest.class)
.newInstance();
.getDeclaredConstructor().newInstance();

Properties props = new Properties();

@@ -72,7 +72,7 @@ Node getNode(String id) throws Exception {
if (id.endsWith(".xml")) {
node = new Module(id);
} else {
node = (Test) Class.forName(id).newInstance();
node = (Test) Class.forName(id).getDeclaredConstructor().newInstance();
}
nodes.put(id, node);
return node;
@@ -548,7 +548,8 @@ private void loadFromXml() throws Exception {
nodelist = d.getDocumentElement().getElementsByTagName("fixture");
if (nodelist.getLength() > 0) {
Element fixtureEl = (Element) nodelist.item(0);
fixture = (Fixture) Class.forName(getFullName(fixtureEl.getAttribute("id"))).newInstance();
fixture = (Fixture) Class.forName(getFullName(fixtureEl.getAttribute("id")))
.getDeclaredConstructor().newInstance();
}

// parse initial node

0 comments on commit dc18e21

Please sign in to comment.