aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/org/traccar/ServerManager.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton@traccar.org>2022-06-16 15:07:29 -0700
committerAnton Tananaev <anton@traccar.org>2022-06-16 15:07:29 -0700
commitb47eca7a90438e738eb1486664717cccc277865f (patch)
tree653c6301738d0e20976c323faf8df6a26b38efb6 /src/main/java/org/traccar/ServerManager.java
parent51cdee534cd9990d1de173814fe95c55dead4934 (diff)
downloadtrackermap-server-b47eca7a90438e738eb1486664717cccc277865f.tar.gz
trackermap-server-b47eca7a90438e738eb1486664717cccc277865f.tar.bz2
trackermap-server-b47eca7a90438e738eb1486664717cccc277865f.zip
Refactor web server code
Diffstat (limited to 'src/main/java/org/traccar/ServerManager.java')
-rw-r--r--src/main/java/org/traccar/ServerManager.java11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/main/java/org/traccar/ServerManager.java b/src/main/java/org/traccar/ServerManager.java
index ffb15d8ca..99fb9a494 100644
--- a/src/main/java/org/traccar/ServerManager.java
+++ b/src/main/java/org/traccar/ServerManager.java
@@ -72,11 +72,14 @@ public class ServerManager implements LifecycleObject {
}
@Override
- public void stop() {
- for (TrackerConnector connector: connectorList) {
- connector.stop();
+ public void stop() throws Exception {
+ try {
+ for (TrackerConnector connector : connectorList) {
+ connector.stop();
+ }
+ } finally {
+ GlobalTimer.release();
}
- GlobalTimer.release();
}
}