Feed aggregator

Tigase server administration: Dynamic virtual hosts

Tigase XMPP Server Board - 21 hours 5 min ago

Hello
Is it possible to manage dynamic virtual hosts, for example via MySQL database, but not in init.properties? We need live create and delete vhosts without restarting server. I found here: http://docs.tigase.org/tigase-server/7.0.0/Administration_Guide/webhelp/_virtual_hosts_in_the_tigase_server.html string "They can be put in the database and managed using ad-hoc commands" but no more information. And is it possible to use vhosts in cluster mode?

Thank you

Categories: Tigase Forums

Tigase server development: RE: Connection under XEP-114

Tigase XMPP Server Board - 21 hours 26 min ago

Hello,
I managed component connection for XEP-114 by adding endpoint allowed to:

--comp-name-1 = ext
--comp-class-1 = tigase.server.ext.ComponentProtocol
--external : componentdomain:password:listen:5270

I try now to connect my component under XEP-225.
Can i use same endpoint with same configuration to connect with XEP-225 ?

Thks,

Categories: Tigase Forums

Tigase server administration: RE: Create admin user after switch to mongodb

Tigase XMPP Server Board - Mon, 07/27/2015 - 01:15

Okay. I just want to answer my own question.

There are no classic roles in Tigase.

If you want a user to be admin, just set it in the /[tigase_server_location]/etc/init.properties

--admins = username@domain

Now username@domain will be able to e.g. use the Tigase Web UI.

Categories: Tigase Forums

Tigase server development: RE: how to slove Queue overflow when the tigase server run a wihle

Tigase XMPP Server Board - Sun, 07/26/2015 - 20:49

I consulted the above post, but it seemed not to find a solution.Do you mean I should Remove The "synchronized" in lotout? Please give me some advice.
Thanks in advance!

Categories: Tigase Forums

Tigase server administration: RE: Configuration question.

Tigase XMPP Server Board - Sun, 07/26/2015 - 08:13

I'm not sure if it is possible to restrict MUC room creation only, so only VHost admin could create rooms.

As for IP addresses and STUN, both addresses are used by remote client to detect it's IP external address and type of NAT. So you would need 2 external IP address for this to work properly (so private addresses are not good for this).

Categories: Tigase Forums

Tigase server administration: RE: Configuration question.

Tigase XMPP Server Board - Sun, 07/26/2015 - 07:59

How I can set rules that only admin of the Vhost can create the MUC rooms ?

Categories: Tigase Forums

Tigase server administration: RE: Configuration question.

Tigase XMPP Server Board - Sun, 07/26/2015 - 07:57

Hello Andrzej,
Thanks for reply websocket is working right now after I corrected the port settings. How to set stun server if tigase box behind NAT (firewall) ?
Do I need interface alias for stun-secondary-ip ? They can be all private ?

Categories: Tigase Forums

Tigase server development: RE: Tigase record fail

Tigase XMPP Server Board - Sat, 07/25/2015 - 23:18

Are you getting an error when Tigase is generating Log files?
Is there a specific file size that seems to trigger the failure?

Categories: Tigase Forums

Tigase server development: RE: Messages to Smack clients are duplicated with Stream Management

Tigase XMPP Server Board - Sat, 07/25/2015 - 07:52

the correct android debug xml log is the last one attached

Categories: Tigase Forums

Tigase server development: Messages to Smack clients are duplicated with Stream Management

Tigase XMPP Server Board - Sat, 07/25/2015 - 07:42

Hello,
I've a strange issue that I'm trying to figure out either in stable than development Tigase version: messages sent to Smack 4.1 Android clients are duplicated while ones to XMPPFramework iOS clients are not.
I'm using on both Mobile platforms stream management with stream resumption enabled, and this issue comes only on Smack clients when a user login twice without stream resumption in about 10 minutes from latest message (I guess TCP keep-alive is involved in this estimated average time)

The issue comes both on latest Tigase stable build 7.0.2 than a development 7.1.0-SNAPSHOT-b3891/84db83a3 I'm using for another issue

I've atteched two files that show that both xmpp libraries do the same thing:

1: use compression
2: use tls
3: use stream management
4: connect announcing presence
5: disconnect annoucing presence unavailable

the message sent is sent from Tigase admin user on default virtualhost, to an user on another virtualhost that has LIST policy: domain.tld;sub.domain.tld

<message id="69xbq-10" type="normal" to="kingrichard@sub.domain.tld/Smack" from="admin@domain.tld/Resource"><subject>Test</subject><body>test 1</body>..other xeps here..<amp xmlns="http://jabber.org/protocol/amp"><rule action="error" condition="expire-at" value="2015-07-24T17:01:37Z"/><rule action="error" condition="match-resource" value="other"/></amp>
both error or drop action are used in tests
<rule action="drop" condition="expire-at" value="2015-07-24T17:01:37Z"/><rule action="drop" condition="match-resource" value="other"/>
but the result is the same by the client side, messages arrive and they seems always in RAM.

I've also attached a log from Tigase side, this is what I see in Tigase logs as soon a duplicated message comes again to the mobile client. It looks like a STREAM_CLOSED event comes and trigger the resending, also this error appear:

<iq type="error" id="7ckgD-74" xmlns="jabber:client" from="kingrichard@sub.domain.tld/Smack"><bind xmlns="urn:ietf:params:xml:ns:xmpp-bind"><jid>kingrichard@sub.domain.tld/Smack</jid></bind><error type="wait" code="404"><recipient-unavailable xmlns="urn:ietf:params:xml:ns:xmpp-stanzas"/></error></iq>

while client is connected indeed. It looks like the previous stream management session was not properly closed and new one didn't invalidated the old one that trigger somehow the message resend.

The strange thing is that on XMPPFramework this doesn't happens and a I see from Tigase logs I've attached only STREAM_CLOSED_UPDATE

I see another 404 but this maybe because the sender weren't available anymore

What do you think about this issue? Could really be a Smack-related issue or a misconfiguration by Tigase side that somehow works with XMPPFramework?
I really don't understand why the message keeps in RAM after is sent instead.

Thanks

Natale

Categories: Tigase Forums

Tigase server administration: RE: Configuration question.

Tigase XMPP Server Board - Sat, 07/25/2015 - 05:40

As for issue with StunComponent please see https://projects.tigase.org/projects/stun/wiki/Configuration as NullPointerException is cause by missing configuration property which is required by StunComponent to initialize properly.

As for issue with WebSocket, I suppose you configured list of C2S allowed ports in your VHost configuration for anon.networklab.ca domain.
This list if set needs to contain also list of allowed WebSocket ports to use.

Categories: Tigase Forums

Tigase server development: User Ip Connection

Tigase XMPP Server Board - Sat, 07/25/2015 - 05:11

Hi, In our use case of tigase, we need to log the IP address that each user connects to the server (when user authenticates) into a database,
is there any automatic way to do this?
if not, how can I add this feature and which part of tigase should be modified?

thanks
Behnam Hatami

Categories: Tigase Forums

Tigase server administration: RE: Configuration question.

Tigase XMPP Server Board - Fri, 07/24/2015 - 21:02

Also some web socket issue when it reject connection with message about policy problem. I search information about all those issues, but can't find anything useful yet. Any help will thank you.

2015-07-24 22:58:21.943 [ConnectionOpenThread] ConnectionManager.serviceStarted() FINER: [[ws2s]] Connection started: null, type: accept, Socket: TLS: nullSocket[addr=/public_ip,port=60294,localport=5291], jid: null 2015-07-24 22:58:22.192 [pool-18-thread-2] WebSocketXMPPIOService.processWebSocketHandshake() FINEST: parsing request = GET / HTTP/1.1 Host: webvc.networklab.ca:5291 Connection: Upgrade Pragma: no-cache Cache-Control: no-cache Upgrade: websocket Origin: http://networklab.global Sec-WebSocket-Version: 13 User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/43.0.2357.134 Safari/537.36 Accept-Encoding: gzip, deflate, sdch Accept-Language: en-GB,en-US;q=0.8,en;q=0.6 Sec-WebSocket-Key: DxJIcfk1NfXIMlm5z1ReuQ== Sec-WebSocket-Extensions: permessage-deflate; client_max_window_bits Sec-WebSocket-Protocol: xmpp 2015-07-24 22:58:22.240 [pool-18-thread-1] ClientConnectionManager.xmppStreamOpened() FINER: Stream opened: {xmlns:stream=http://etherx.jabber.org/streams, xmlns=jabber:client, to=networklab.ca, version=1.0} 2015-07-24 22:58:22.240 [pool-18-thread-1] WebSocketXMPPIOService.writeData() FINEST: sending data = <?xml version='1.0'?><stream:stream xmlns='jabber:client' xmlns:stream='http://etherx.jabber.org/streams' id='tigase-error-tigase' from='anon.networklab.ca' version='1.0' xml:lang='en'><stream:error><policy-violation xmlns='urn:ietf:params:xml:ns:xmpp-streams'/></stream:error></stream:stream> 2015-07-24 22:58:22.240 [pool-18-thread-1] WebSocketHybi.encodeFrameAndWrite() FINEST: sending encoded data size = 293
Categories: Tigase Forums

Tigase server development: Tigase record fail

Tigase XMPP Server Board - Fri, 07/24/2015 - 19:50

The general situation,start record and stop record is ok.when record folder file reaches more than several thousands,start record fail.Hard drive is large enough to save files.That why?

Categories: Tigase Forums

Tigase server administration: RE: Configuration question.

Tigase XMPP Server Board - Fri, 07/24/2015 - 17:56

Hello Everyone,
Tried load stun component, but it no loaded give exception.
tigase 7.02

2015-07-24 19:48:51.446 [main] Configurator.componentAdded() WARNING: ignoring NPE java.lang.NullPointerException at tigase.stun.StunComponent.init(StunComponent.java:167) at tigase.stun.StunComponent.setProperties(StunComponent.java:115) at tigase.conf.ConfiguratorAbstract.setup(ConfiguratorAbstract.java:540) at tigase.conf.ConfiguratorAbstract.componentAdded(ConfiguratorAbstract.java:177) at tigase.conf.Configurator.componentAdded(Configurator.java:50) at tigase.conf.Configurator.componentAdded(Configurator.java:33) at tigase.server.AbstractComponentRegistrator.addComponent(AbstractComponentRegistrator.java:116) at tigase.server.MessageRouter.addComponent(MessageRouter.java:108) at tigase.server.MessageRouter.addRouter(MessageRouter.java:145) at tigase.server.MessageRouter.setProperties(MessageRouter.java:698) at tigase.conf.ConfiguratorAbstract.setup(ConfiguratorAbstract.java:540) at tigase.conf.ConfiguratorAbstract.componentAdded(ConfiguratorAbstract.java:177) at tigase.conf.Configurator.componentAdded(Configurator.java:50) at tigase.conf.Configurator.componentAdded(Configurator.java:33) at tigase.server.AbstractComponentRegistrator.addComponent(AbstractComponentRegistrator.java:116) at tigase.server.MessageRouter.addRegistrator(MessageRouter.java:131) at tigase.server.MessageRouter.setConfig(MessageRouter.java:597) at tigase.server.XMPPServer.start(XMPPServer.java:142) at tigase.server.XMPPServer.main(XMPPServer.java:112)
Categories: Tigase Forums

Tigase server administration: Create admin user after switch to mongodb

Tigase XMPP Server Board - Fri, 07/24/2015 - 08:05

Hello,

I have successfully installed Tigase with mysql and everything worked great.

After I switched to mongodb, I have a new database created in mongodb with default schema, but missing the admin user.

My question is how do I create the admin user in the mongodb?

I'm still new to Tigase. Are there any scripts that can be run from the terminal, that can create admin user?

Thanks

Categories: Tigase Forums

Tigase server development: Plugin processes a packet 2 times from sender

Tigase XMPP Server Board - Fri, 07/24/2015 - 06:21

Hi there,

I develop a plugin to track message statuses (delivered, read) http://xmpp.org/extensions/xep-0333.html

Here is my simple implementation:

public class MessageReadDelivered extends XMPPProcessor implements XMPPProcessorIfc { private static final String ID = "message-read-delivered"; private static final String XMLNS = "urn:xmpp:chat-markers:0"; public static final String RECEIVED_KEY = "received"; public static final String DISPLAYED_KEY = "displayed"; public static final String[] MESSAGE_RECEIVED_PATH = { Message.ELEM_NAME, RECEIVED_KEY}; public static final String[] MESSAGE_DISPLAYED_PATH = { Message.ELEM_NAME, DISPLAYED_KEY}; private static final Logger log = Logger.getLogger(MessageReadDelivered.class.getName()); @Override public String id() { return ID; } @Override public String[] supNamespaces() { return new String[]{XMLNS, XMLNS}; } @Override public String[][] supElementNamePaths() { return new String[][]{MESSAGE_RECEIVED_PATH, MESSAGE_DISPLAYED_PATH}; } @Override public void process(Packet packet, XMPPResourceConnection session, NonAuthUserRepository repo, Queue<Packet> results, Map<String, Object> settings) throws XMPPException { // You may want to skip processing completely if the user is offline. if (session == null) { return; } BareJID id = (packet.getStanzaFrom() != null) ? packet.getStanzaFrom().getBareJID() : null; if (session.isUserId(id) { if (log.isLoggable(Level.INFO)) { log.log(Level.INFO, "packet: {0}, session: {1}", new Object[] { packet, session}); } // do something with status // ... } } }

My test is simple: UserA sends a status to UserB

By some reason I see above log 2 times:

[message-read-delivered Queue Worker 0] MessageReadDelivered.process() INFO: packet: from=c2s@qq-chat1/174.30.0.248_5222_92.117.252.236_52793, to=sess-man@qq-chat1... [message-read-delivered Queue Worker 0] MessageReadDelivered.process() INFO: packet: from=sess-man@qq-chat1, to=sess-man@qq-chat1...

This is not what I expect - my logic works 2 times then.
According to this doc http://docs.tigase.org/tigase-server/7.0.0/Development_Guide/html/#_introduction

The packet has to be processed twice by the session manager. The first time it is processed on behalf of the User A as an outgoing packet and the second time it is processed on behalf of the User B as an incoming packet.

so only once on each side, not 2

To fix this I add:

if (session.isUserId(id) && packet.getPacketFrom().getLocalpart().equals("c2s")) {...

Is it a right solution or should I rewrite this in a some other way?

thank you

Categories: Tigase Forums

Pages

Get in touch

We provide software products, consulting and custom development services

Tigase, Inc.
100 Pine Street, Suite 1250
San Francisco, CA 94111, USA
Phone: (415) 315 9771

Follow us on:

Twitter

Back to Top