Project

General

Profile

Some NPE problems when high load test of tigase for chat by jMeter.

Wei Sun
Added over 1 year ago

I used jMeter to do High load test on tigase 7.2.0-SNAPSHOT for chatting.

I got some exceptions in file tigase-console.log once I increased the number of users which connected to the tigase-server per second or increasing the number of messages sent per second:

Exceptions1:

2017-09-04 18:06:34.472 [in_171-sess-man]  AbstractMessageReceiver$QueueListener.run()  SEVERE: [in_171-sess-man] Exception during packet processing: from=c2s@touchat/172.16.52.179_5222_222.93.152.4_55469, to=sess-man@touchat, DATA=<message xmlns="jabber:client" type="chat" id="L4g22-5119904" to="user_57262@touchat.touchair.cn"><body>jmeter TestMessage sample</body></message>, SIZE=131, XMLNS=jabber:client, PRIORITY=NORMAL, PERMISSION=NONE, TYPE=chat
java.lang.NullPointerException
        at tigase.server.amp.db.JDBCMsgRepository.storeMessage(JDBCMsgRepository.java:632)
        at tigase.server.amp.db.MsgRepository$MsgRepositoryMDBean.storeMessage(MsgRepository.java:324)
        at tigase.xmpp.impl.OfflineMessages.savePacketForOffLineUser(OfflineMessages.java:398)
        at tigase.xmpp.impl.MessageAmp.postProcess(MessageAmp.java:160)
        at tigase.server.xmppsession.SessionManager.processPacket(SessionManager.java:1713)
        at tigase.server.xmppsession.SessionManager.processPacket(SessionManager.java:476)
        at tigase.server.AbstractMessageReceiver$QueueListener.run(AbstractMessageReceiver.java:1503)

Exceptions2:

2017-09-04 18:06:34.473 [in_171-sess-man]  AbstractMessageReceiver$QueueListener.run()  SEVERE: [in_171-sess-man] Exception during packet processing: from=c2s@touchat/172.16.52.179_5222_222.93.152.4_55469, to=sess-man@touchat, DATA=<message xmlns="jabber:client" type="chat" id="L4g22-5119906" to="user_87261@touchat.touchair.cn"><body>jmeter TestMessage sample</body></message>, SIZE=131, XMLNS=jabber:client, PRIORITY=NORMAL, PERMISSION=NONE, TYPE=chat
java.lang.NullPointerException

how to solve the problems? thanks a lot


Replies (5)

Avatar?id=6023&size=32x32

Added by Artur Hefczyc TigaseTeam over 1 year ago

This seems like a misconfiguration of the Tigase server and problems with database connectivity.

Wojciech, any ideas?

Added by Wojciech Kapcia TigaseTeam over 1 year ago

@Wei Sun - are those complete Stack Traces? Which version exactly are you using? I've checked latest code of 7.2.0-SNAPSHOT and there are no corresponding lines. Please provide complete build information and Tigase version.

Added by Wei Sun over 1 year ago

My exactly version of tigase-server is 9908af23d8ab8f7b186a5b52fed11d922944e24e.

The followings are the tigase.log.0 file and the init.properties file:

There was no these Problems when the number of users connected to the tigase-server or messages sent to tigase-server per second is relatively small (such as several hundred).

Added by Wei Sun over 1 year ago

I think the problems is due to some users do not log in the tigase-server(due to network traffic) although they have been connected to the server,then those users sending message will

cause above problems .it's not problem of tigase-server. thanks.

Added by Wojciech Kapcia TigaseTeam over 1 year ago

It's possible - you could add logic in your test tool to wait for correct authentication from the server before proceeding.

I've also took a look at the sources of that commit and it looks like you are missing from attribute in the messages that you are sending - and those are required by the specification (your assumption about message being addressed/processed but offline user is correct).

    (1-5/5)