Skip to content
Snippets Groups Projects
Commit 3b7c6b8d authored by Jonas Arnhold's avatar Jonas Arnhold
Browse files

Fix message receiving on Cloud side

parent f21df38d
No related branches found
No related tags found
No related merge requests found
......@@ -18,7 +18,7 @@ public class CloudService implements Callable<Void> {
boolean connected = false;
while (!connected) {
connected = responder.connect("tcp://localhost:%s".formatted(cloudServicePort));
connected = responder.bind("tcp://localhost:%s".formatted(cloudServicePort));
System.out.printf("Was not able to init cloud service on port %s...%n", cloudServicePort);
ThreadUtils.sleep(5, TimeUnit.SECONDS);
}
......
No preview for this file type
......@@ -47,7 +47,7 @@ public class MessageSender implements Runnable {
Timestamp currentDateTime = new Timestamp(System.currentTimeMillis());
SensorDataBatch sensorDataBatch = new SensorDataBatch(batch, currentDateTime);
System.out.printf("Batch ready to sent: %s\n", sensorDataBatch);
System.out.printf("Trying to sent batch: %s\n", sensorDataBatch);
trySendToCloud(sensorDataBatch);
ThreadUtils.sleep(15, TimeUnit.SECONDS);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment