diff options
author | Vitaly Takmazov | 2016-12-07 16:00:17 +0300 |
---|---|---|
committer | Vitaly Takmazov | 2016-12-07 16:00:17 +0300 |
commit | 3fc85c266cb30af2898b0d9ba99c2a8577237a41 (patch) | |
tree | d282709ca2a888b93a6796569335b2bcedfd04a3 /juick-xmpp-ft/src/main/java | |
parent | cce0f14568b274d5b92faa94ebad549e1e104616 (diff) |
juick-xmpp-ft: enable logger
Diffstat (limited to 'juick-xmpp-ft/src/main/java')
-rw-r--r-- | juick-xmpp-ft/src/main/java/com/juick/components/XMPPFTServer.java | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/juick-xmpp-ft/src/main/java/com/juick/components/XMPPFTServer.java b/juick-xmpp-ft/src/main/java/com/juick/components/XMPPFTServer.java index 528604dd..236c4c0d 100644 --- a/juick-xmpp-ft/src/main/java/com/juick/components/XMPPFTServer.java +++ b/juick-xmpp-ft/src/main/java/com/juick/components/XMPPFTServer.java @@ -8,6 +8,9 @@ import org.slf4j.LoggerFactory; import org.springframework.core.env.Environment; import rocks.xmpp.addr.Jid; import rocks.xmpp.core.XmppException; +import rocks.xmpp.core.session.Extension; +import rocks.xmpp.core.session.XmppSessionConfiguration; +import rocks.xmpp.core.session.debug.LogbackDebugger; import rocks.xmpp.core.stanza.model.Message; import rocks.xmpp.extensions.component.accept.ExternalComponent; import rocks.xmpp.extensions.filetransfer.FileTransfer; @@ -33,8 +36,11 @@ public class XMPPFTServer implements AutoCloseable { private ExternalComponent component; public XMPPFTServer(Environment env) { + XmppSessionConfiguration configuration = XmppSessionConfiguration.builder() + .debugger(LogbackDebugger.class) + .build(); component = ExternalComponent.create(env.getProperty("component_name", "files"), - env.getProperty("component_password", "secret"), env.getProperty("component_host", "localhost"), + env.getProperty("component_password", "secret"), configuration, env.getProperty("component_host", "localhost"), NumberUtils.toInt(env.getProperty("component_port", "5347"), 5347)); String tmpDir = env.getProperty("upload_tmp_dir", "/tmp"); String juickJid = env.getProperty("xmppbot_jid", "juick@juick.com/Juick"); |