Commit fbd089e7 authored by Spiros Koulouzis's avatar Spiros Koulouzis

Chaned from system call to java call

parent 7da2d687
...@@ -20,6 +20,13 @@ ...@@ -20,6 +20,13 @@
<version>1.0-SNAPSHOT</version> <version>1.0-SNAPSHOT</version>
</dependency> </dependency>
<dependency>
<groupId>nl.uva.sne.drip</groupId>
<artifactId>drip-provisioning-core</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
<dependency> <dependency>
<groupId>com.rabbitmq</groupId> <groupId>com.rabbitmq</groupId>
<artifactId>amqp-client</artifactId> <artifactId>amqp-client</artifactId>
......
...@@ -241,14 +241,15 @@ public class Consumer extends DefaultConsumer { ...@@ -241,14 +241,15 @@ public class Consumer extends DefaultConsumer {
} }
String cmd = "java -jar " + jarFilePath + " ec2=" + ec2ConfFilePath + " exogeni=" + geniConfFilePath + " logDir=" + logDir + " topology=" + mainTopologyPath; String cmd = "java -jar " + jarFilePath + " ec2=" + ec2ConfFilePath + " exogeni=" + geniConfFilePath + " logDir=" + logDir + " topology=" + mainTopologyPath;
try { Provisioning.ProvisioningCore.main(cmd.split(" "));
Logger.getLogger(Consumer.class.getName()).log(Level.INFO, "Executing: " + cmd); // try {
Process p = Runtime.getRuntime().exec(cmd); // Logger.getLogger(Consumer.class.getName()).log(Level.INFO, "Executing: " + cmd);
p.waitFor(); // Process p = Runtime.getRuntime().exec(cmd);
} catch (IOException | InterruptedException e) { // p.waitFor();
// TODO Auto-generated catch block // } catch (IOException | InterruptedException e) {
Logger.getLogger(Consumer.class.getName()).log(Level.SEVERE, null, e); // // TODO Auto-generated catch block
} // Logger.getLogger(Consumer.class.getName()).log(Level.SEVERE, null, e);
// }
topologyElement x = new topologyElement(); topologyElement x = new topologyElement();
x.topologyName = "kubernetes"; x.topologyName = "kubernetes";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment