aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/com/juick/xmpp
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2016-07-06 19:34:54 +0300
committerGravatar Vitaly Takmazov2016-07-06 19:34:54 +0300
commit2ebd7a050acf477b68a72397395a026ec63d89dd (patch)
tree2b6bfce0f397ce92bcbb47571316858faab3a507 /src/main/java/com/juick/xmpp
parent95869ef683a517eb48db1784150ded7661294f8a (diff)
separate thread for xmpp component
Diffstat (limited to 'src/main/java/com/juick/xmpp')
-rw-r--r--src/main/java/com/juick/xmpp/s2s/XMPPComponent.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main/java/com/juick/xmpp/s2s/XMPPComponent.java b/src/main/java/com/juick/xmpp/s2s/XMPPComponent.java
index db7b11ac..5cdce82a 100644
--- a/src/main/java/com/juick/xmpp/s2s/XMPPComponent.java
+++ b/src/main/java/com/juick/xmpp/s2s/XMPPComponent.java
@@ -35,6 +35,7 @@ public class XMPPComponent implements ServletContextListener {
private static final Logger LOGGER = Logger.getLogger(XMPPComponent.class.getName());
public final ExecutorService executorService = Executors.newCachedThreadPool();
+ ExecutorService xmppService = Executors.newSingleThreadExecutor();
public String HOSTNAME = null;
public String STATSFILE = null;
@@ -169,7 +170,7 @@ public class XMPPComponent implements ServletContextListener {
public void contextInitialized(ServletContextEvent sce) {
LOGGER.info("component initialized");
- executorService.submit(() -> {
+ xmppService.submit(() -> {
Properties conf = new Properties();
try {
conf.load(sce.getServletContext().getResourceAsStream("/WEB-INF/juick.conf"));