aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/com/juick/server/ServerManager.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/com/juick/server/ServerManager.java')
-rw-r--r--src/main/java/com/juick/server/ServerManager.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/main/java/com/juick/server/ServerManager.java b/src/main/java/com/juick/server/ServerManager.java
index d3742503..ee8d2147 100644
--- a/src/main/java/com/juick/server/ServerManager.java
+++ b/src/main/java/com/juick/server/ServerManager.java
@@ -50,7 +50,7 @@ import java.util.stream.Collectors;
*/
@Component
public class ServerManager implements NotificationListener {
- private static Logger logger = LoggerFactory.getLogger("Session");
+ private static final Logger logger = LoggerFactory.getLogger("Session");
@Inject
private MessagesService messagesService;
@@ -58,7 +58,7 @@ public class ServerManager implements NotificationListener {
private SubscriptionService subscriptionService;
@Inject
private UserService userService;
- private CopyOnWriteArrayList<EventSession> sessions = new CopyOnWriteArrayList<>();
+ private final CopyOnWriteArrayList<EventSession> sessions = new CopyOnWriteArrayList<>();
@Value("${service_user:juick}")
private String serviceUsername;
@@ -158,8 +158,8 @@ public class ServerManager implements NotificationListener {
}
public static class EventSession {
- private User user;
- private SseEmitter emitter;
+ private final User user;
+ private final SseEmitter emitter;
public EventSession(User user, SseEmitter sseEmitter) {
this.user = user;