Skip to content

Commit

Permalink
[dsmr] Set Thread name and daemon state (openhab#8325)
Browse files Browse the repository at this point in the history
Signed-off-by: Hilbrand Bouwkamp <[email protected]>
  • Loading branch information
Hilbrand authored and CSchlipp committed Sep 12, 2020
1 parent d6fd9c5 commit 8c235bc
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,8 @@ public void initialize() {
this.dsmrDevice = dsmrDevice; // otherwise Eclipse will give a null pointer error on the next line :-(
dsmrDeviceRunnable = new DSMRDeviceRunnable(dsmrDevice, this);
dsmrDeviceThread = new Thread(dsmrDeviceRunnable);
dsmrDeviceThread.setName("OH-binding-" + getThing().getUID());
dsmrDeviceThread.setDaemon(true);
dsmrDeviceThread.start();
watchdog = scheduler.scheduleWithFixedDelay(this::alive, receivedTimeoutNanos, receivedTimeoutNanos,
TimeUnit.NANOSECONDS);
Expand Down

0 comments on commit 8c235bc

Please sign in to comment.