[jitsi-dev] Lost XMPP message


#1

Hello,

Someone sent me a message (via XMPP). I saw a notification appear (and
it showed part of the message), but the chat window did not appear and
the message does not show up in history. There were no problems with
subsequent messages. The exception below was logged.

I was running a recent nightly, but the same thing also happened a few
weeks ago, with the same contact.

Anyone have any ideas? Should we create an issue?

Regards,
Boris

java.lang.IllegalArgumentException: There is already a history with the
specified ID.
  at
net.java.sip.communicator.impl.history.HistoryServiceImpl.createHistory(HistoryServiceImpl.java:172)
  at
net.java.sip.communicator.impl.msghistory.MessageHistoryServiceImpl.getHistory(MessageHistoryServiceImpl.java:532)
  at
net.java.sip.communicator.impl.msghistory.MessageHistoryServiceImpl.writeMessage(MessageHistoryServiceImpl.java:912)
  at
net.java.sip.communicator.impl.msghistory.MessageHistoryServiceImpl.messageReceived(MessageHistoryServiceImpl.java:843)
  at
net.java.sip.communicator.service.protocol.AbstractOperationSetBasicInstantMessaging.fireMessageEvent(AbstractOperationSetBasicInstantMessaging.java:200)
  at
net.java.sip.communicator.impl.protocol.jabber.OperationSetBasicInstantMessagingJabberImpl.access$1200(OperationSetBasicInstantMessagingJabberImpl.java:36)
  at
net.java.sip.communicator.impl.protocol.jabber.OperationSetBasicInstantMessagingJabberImpl$SmackMessageListener.processPacket(OperationSetBasicInstantMessagingJabberImpl.java:820)
  at
org.jivesoftware.smack.Connection$ListenerWrapper.notifyListener(Connection.java:813)
  at
org.jivesoftware.smack.PacketReader$ListenerNotification.run(PacketReader.java:453)
  at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:439)
  at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
  at java.util.concurrent.FutureTask.run(FutureTask.java:138)
  at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
  at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
  at java.lang.Thread.run(Thread.java:680)


#2

Someone sent me a message (via XMPP). I saw a notification appear (and
it showed part of the message), but the chat window did not appear and
the message does not show up in history. There were no problems with
subsequent messages. The exception below was logged.

I was running a recent nightly, but the same thing also happened a few
weeks ago, with the same contact.

Anyone have any ideas? Should we create an issue?

Well, looking at the stack trace, this is almost guaranteed to fail
(simplified):

if (isHistoryExisting) {
  //Use it
}
else {
  Synchronized {
    if (existing)
      throw;
    else
      //use it
  }
}

HistoryServiceImpl.createHistory could just return it instead of throwing. I
don't see any harm with that - it would rather fix a broken API.

Regards,
Boris

Ingo


#3

Hey Boris,

Yes, please, open a ticket.

The history checks are only supposed to happen in MUCs in the first
place. (And there may be additional problems as well)

Emil

···

On Mon, Aug 19, 2013 at 10:35 AM, Boris Grozev <boris@jitsi.org> wrote:

Hello,

Someone sent me a message (via XMPP). I saw a notification appear (and
it showed part of the message), but the chat window did not appear and
the message does not show up in history. There were no problems with
subsequent messages. The exception below was logged.

I was running a recent nightly, but the same thing also happened a few
weeks ago, with the same contact.

Anyone have any ideas? Should we create an issue?

Regards,
Boris

java.lang.IllegalArgumentException: There is already a history with the
specified ID.
        at
net.java.sip.communicator.impl.history.HistoryServiceImpl.createHistory(HistoryServiceImpl.java:172)
        at
net.java.sip.communicator.impl.msghistory.MessageHistoryServiceImpl.getHistory(MessageHistoryServiceImpl.java:532)
        at
net.java.sip.communicator.impl.msghistory.MessageHistoryServiceImpl.writeMessage(MessageHistoryServiceImpl.java:912)
        at
net.java.sip.communicator.impl.msghistory.MessageHistoryServiceImpl.messageReceived(MessageHistoryServiceImpl.java:843)
        at
net.java.sip.communicator.service.protocol.AbstractOperationSetBasicInstantMessaging.fireMessageEvent(AbstractOperationSetBasicInstantMessaging.java:200)
        at
net.java.sip.communicator.impl.protocol.jabber.OperationSetBasicInstantMessagingJabberImpl.access$1200(OperationSetBasicInstantMessagingJabberImpl.java:36)
        at
net.java.sip.communicator.impl.protocol.jabber.OperationSetBasicInstantMessagingJabberImpl$SmackMessageListener.processPacket(OperationSetBasicInstantMessagingJabberImpl.java:820)
        at
org.jivesoftware.smack.Connection$ListenerWrapper.notifyListener(Connection.java:813)
        at
org.jivesoftware.smack.PacketReader$ListenerNotification.run(PacketReader.java:453)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:439)
        at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
        at java.util.concurrent.FutureTask.run(FutureTask.java:138)
        at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
        at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
        at java.lang.Thread.run(Thread.java:680)

_______________________________________________
dev mailing list
dev@jitsi.org
Unsubscribe instructions and other list options:
http://lists.jitsi.org/mailman/listinfo/dev

--
Emil Ivov, Ph.D. 67000 Strasbourg,
Project Lead France
Jitsi
emcho@jitsi.org PHONE: +33.1.77.62.43.30
https://jitsi.org FAX: +33.1.77.62.47.31