aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/org/traccar/api/resource/NotificationResource.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton@traccar.org>2023-02-20 14:33:36 -0800
committerAnton Tananaev <anton@traccar.org>2023-02-20 14:33:36 -0800
commitcd1d80896b16c84ae0a8a4631a9dba6955e9e344 (patch)
tree8efd18ee259e2b614c9e4450cf9982d6754cdaa6 /src/main/java/org/traccar/api/resource/NotificationResource.java
parent1439422c6f4ce947f6719743b37fa49f251fc97f (diff)
downloadtrackermap-server-cd1d80896b16c84ae0a8a4631a9dba6955e9e344.tar.gz
trackermap-server-cd1d80896b16c84ae0a8a4631a9dba6955e9e344.tar.bz2
trackermap-server-cd1d80896b16c84ae0a8a4631a9dba6955e9e344.zip
Implement command notificator
Diffstat (limited to 'src/main/java/org/traccar/api/resource/NotificationResource.java')
-rw-r--r--src/main/java/org/traccar/api/resource/NotificationResource.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main/java/org/traccar/api/resource/NotificationResource.java b/src/main/java/org/traccar/api/resource/NotificationResource.java
index d58557601..7005fc083 100644
--- a/src/main/java/org/traccar/api/resource/NotificationResource.java
+++ b/src/main/java/org/traccar/api/resource/NotificationResource.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2016 - 2022 Anton Tananaev (anton@traccar.org)
+ * Copyright 2016 - 2023 Anton Tananaev (anton@traccar.org)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -80,7 +80,7 @@ public class NotificationResource extends ExtendedObjectResource<Notification> {
@POST
@Path("test")
- public Response testMessage() throws MessageException, InterruptedException, StorageException {
+ public Response testMessage() throws MessageException, StorageException {
User user = permissionsService.getUser(getUserId());
for (Typed method : notificatorManager.getAllNotificatorTypes()) {
notificatorManager.getNotificator(method.getType()).send(null, user, new Event("test", 0), null);
@@ -91,7 +91,7 @@ public class NotificationResource extends ExtendedObjectResource<Notification> {
@POST
@Path("test/{notificator}")
public Response testMessage(@PathParam("notificator") String notificator)
- throws MessageException, InterruptedException, StorageException {
+ throws MessageException, StorageException {
User user = permissionsService.getUser(getUserId());
notificatorManager.getNotificator(notificator).send(null, user, new Event("test", 0), null);
return Response.noContent().build();