This commit is contained in:
Gregor_Dutzler
2019-10-04 16:52:14 +02:00
parent 54aa35563b
commit 6b8cb9cc10
12 changed files with 174 additions and 22 deletions

View File

@@ -1,7 +1,10 @@
package com.wasteinformationserver;
import com.wasteinformationserver.basicutils.Log;
import com.wasteinformationserver.website.Webserver;
import com.wasteinformationserver.mqtt.*;
import org.eclipse.paho.client.mqttv3.MqttException;
import java.net.URISyntaxException;
import java.sql.SQLException;
public class main {
public static void main(String[] args) {
@@ -11,7 +14,7 @@ public class main {
D.printList();
*/
Runtime.getRuntime().addShutdownHook(new Thread(() -> {
/* Runtime.getRuntime().addShutdownHook(new Thread(() -> {
try {
Thread.sleep(200);
Log.warning("Shutting down ...");
@@ -25,9 +28,15 @@ public class main {
Thread mythread = new Thread(() -> new Webserver().startserver());
mythread.start();
Log.message("thread started");
Log.message("thread started");*/
mqtt m=new mqtt();
// m.notifymessage();
try {
m.getDatabasedata();
} catch (SQLException e) {
e.printStackTrace();
}
}
}