diff options
Diffstat (limited to 'juick-www/src/main/java/com/juick/www/Main.java')
-rw-r--r-- | juick-www/src/main/java/com/juick/www/Main.java | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/juick-www/src/main/java/com/juick/www/Main.java b/juick-www/src/main/java/com/juick/www/Main.java index 56b886c9..e3457323 100644 --- a/juick-www/src/main/java/com/juick/www/Main.java +++ b/juick-www/src/main/java/com/juick/www/Main.java @@ -82,7 +82,7 @@ public class Main extends HttpServlet implements Stream.StreamListener { sql = new JdbcTemplate(dataSource); sqlSearch = new JdbcTemplate(dataSourceSearch); - setupXmppComponent(conf.getProperty("xmpp_password")); + setupXmppComponent(new JID(conf.getProperty("www_xmpp_jid", "www.juick.local")), conf.getProperty("xmpp_password")); twitterAuth = new TwitterAuth(conf.getProperty("twitter_consumer_key"), conf.getProperty("twitter_consumer_secret")); pagesNewMessage = new NewMessage(conf.getProperty("upload_tmp_dir", "/var/www/juick.com/i/tmp/"), @@ -98,11 +98,11 @@ public class Main extends HttpServlet implements Stream.StreamListener { } } - public void setupXmppComponent(final String password) { + public void setupXmppComponent(final JID componentJid, final String password) { Thread thr = new Thread(() -> { try { Socket socket = new Socket("localhost", 5347); - xmpp = new StreamComponent(new JID("", "www.juick.com", ""), socket.getInputStream(), socket.getOutputStream(), password); + xmpp = new StreamComponent(componentJid, socket.getInputStream(), socket.getOutputStream(), password); xmpp.addListener(Main.this); xmpp.startParsing(); } catch (IOException e) { |