VYSPER
  1. VYSPER
  2. VYSPER-73

Mutual subscription error in JCR persistence

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: storage
    • Labels:
      None

      Description

      There are exceptions when the mutual subscription is going to be saved to the jcr repo:

      10:55:04,225 | WARN | org.apache.vysper.storage.jcr.roster.JcrRosterManager | try now loading contact user1@vysper.org from node node /accountentity/user2@vysper.org/jabber_iq_roster/user1@vysper.org
      10:55:04,225 | INFO | org.apache.vysper.storage.jcr.roster.JcrRosterManager | item loaded for user2@vysper.org: RosterItem

      {jid=user1@vysper.org, name='null', groups=[], subscriptionType=FROM, askSubscriptionType=NOT_SET}

      10:55:04,230 | ERROR | org.apache.vysper.xmpp.protocol.ProtocolWorker | error executing handler org.apache.vysper.xmpp.modules.core.im.handler.PresenceHandler with stanza presence.type='subscribe'.to='user1@vysper.org'
      java.lang.RuntimeException: org.apache.vysper.xmpp.modules.roster.RosterException: failed to add contact node to roster for user = user2@vysper.org and contact jid = user1@vysper.org
      at org.apache.vysper.xmpp.modules.core.im.handler.PresenceSubscriptionHandler.handleOutboundSubscriptionRequest(PresenceSubscriptionHandler.java:487)
      at org.apache.vysper.xmpp.modules.core.im.handler.PresenceSubscriptionHandler.executeCorePresence(PresenceSubscriptionHandler.java:97)
      at org.apache.vysper.xmpp.modules.core.im.handler.PresenceHandler.executeCore(PresenceHandler.java:67)
      at org.apache.vysper.xmpp.modules.core.base.handler.XMPPCoreStanzaHandler.execute(XMPPCoreStanzaHandler.java:112)
      at org.apache.vysper.xmpp.protocol.worker.AbstractStateAwareProtocolWorker.executeHandler(AbstractStateAwareProtocolWorker.java:67)
      at org.apache.vysper.xmpp.protocol.worker.AbstractStateAwareProtocolWorker.processStanza(AbstractStateAwareProtocolWorker.java:46)
      at org.apache.vysper.xmpp.protocol.ProtocolWorker.processStanza(ProtocolWorker.java:167)
      at org.apache.vysper.xmpp.protocol.QueuedStanzaProcessor$StanzaProcessorUnitOfWork.run(QueuedStanzaProcessor.java:69)
      at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:417)
      at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:269)
      at java.util.concurrent.FutureTask.run(FutureTask.java:123)
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
      at java.lang.Thread.run(Thread.java:613)
      Caused by: org.apache.vysper.xmpp.modules.roster.RosterException: failed to add contact node to roster for user = user2@vysper.org and contact jid = user1@vysper.org
      at org.apache.vysper.storage.jcr.roster.JcrRosterManager.addContact(JcrRosterManager.java:172)
      at org.apache.vysper.xmpp.modules.core.im.handler.PresenceSubscriptionHandler.handleOutboundSubscriptionRequest(PresenceSubscriptionHandler.java:485)
      ... 13 more
      Caused by: javax.jcr.InvalidItemStateException: Item cannot be saved because it has beenmodified externally: node /accountentity/user2@vysper.org/jabber_iq_roster/user1@vysper.org
      at org.apache.jackrabbit.core.ItemImpl.getTransientStates(ItemImpl.java:246)
      at org.apache.jackrabbit.core.ItemImpl.save(ItemImpl.java:931)
      at org.apache.vysper.storage.jcr.roster.JcrRosterManager.addContact(JcrRosterManager.java:169)
      ... 14 more
      10:55:04,233 | WARN | org.apache.vysper.storage.jcr.roster.JcrRosterManager | try now loading contact user1@vysper.org from node node /accountentity/user2@vysper.org/jabber_iq_roster/user1@vysper.org
      10:55:04,233 | WARN | org.apache.vysper.storage.jcr.roster.JcrRosterManager | when loading roster for user user2@vysper.org, contact user1@vysper.org, the ask subscription type is unparsable. skipping!
      org.apache.vysper.xmpp.modules.roster.RosterException: failed to add contact node to roster for user = user2@vysper.org and contact jid = user1@vysper.org
      at org.apache.vysper.storage.jcr.roster.JcrRosterManager.addContact(JcrRosterManager.java:172)
      at org.apache.vysper.xmpp.modules.core.im.handler.PresenceSubscriptionHandler.handleOutboundSubscriptionApproval(PresenceSubscriptionHandler.java:342)
      at org.apache.vysper.xmpp.modules.core.im.handler.PresenceSubscriptionHandler.executeCorePresence(PresenceSubscriptionHandler.java:103)
      at org.apache.vysper.xmpp.modules.core.im.handler.PresenceHandler.executeCore(PresenceHandler.java:67)
      at org.apache.vysper.xmpp.modules.core.base.handler.XMPPCoreStanzaHandler.execute(XMPPCoreStanzaHandler.java:112)
      at org.apache.vysper.xmpp.protocol.worker.AbstractStateAwareProtocolWorker.executeHandler(AbstractStateAwareProtocolWorker.java:67)
      at org.apache.vysper.xmpp.protocol.worker.AbstractStateAwareProtocolWorker.processStanza(AbstractStateAwareProtocolWorker.java:46)
      at org.apache.vysper.xmpp.protocol.ProtocolWorker.processStanza(ProtocolWorker.java:167)
      at org.apache.vysper.xmpp.protocol.QueuedStanzaProcessor$StanzaProcessorUnitOfWork.run(QueuedStanzaProcessor.java:69)
      at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:417)
      at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:269)
      at java.util.concurrent.FutureTask.run(FutureTask.java:123)
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
      at java.lang.Thread.run(Thread.java:613)
      Caused by: javax.jcr.InvalidItemStateException: Item cannot be saved because it has beenmodified externally: node /accountentity/user2@vysper.org/jabber_iq_roster/user1@vysper.org
      at org.apache.jackrabbit.core.ItemImpl.getTransientStates(ItemImpl.java:246)
      at org.apache.jackrabbit.core.ItemImpl.save(ItemImpl.java:931)
      at org.apache.vysper.storage.jcr.roster.JcrRosterManager.addContact(JcrRosterManager.java:169)
      ... 14 more
      10:55:04,238 | ERROR | org.apache.vysper.xmpp.protocol.ProtocolWorker | error executing handler org.apache.vysper.xmpp.modules.core.im.handler.PresenceHandler with stanza presence.type='subscribed'.to='user1@vysper.org'
      java.lang.RuntimeException: org.apache.vysper.xmpp.modules.roster.RosterException: failed to add contact node to roster for user = user2@vysper.org and contact jid = user1@vysper.org
      at org.apache.vysper.xmpp.modules.core.im.handler.PresenceSubscriptionHandler.handleOutboundSubscriptionApproval(PresenceSubscriptionHandler.java:345)
      at org.apache.vysper.xmpp.modules.core.im.handler.PresenceSubscriptionHandler.executeCorePresence(PresenceSubscriptionHandler.java:103)
      at org.apache.vysper.xmpp.modules.core.im.handler.PresenceHandler.executeCore(PresenceHandler.java:67)
      at org.apache.vysper.xmpp.modules.core.base.handler.XMPPCoreStanzaHandler.execute(XMPPCoreStanzaHandler.java:112)
      at org.apache.vysper.xmpp.protocol.worker.AbstractStateAwareProtocolWorker.executeHandler(AbstractStateAwareProtocolWorker.java:67)
      at org.apache.vysper.xmpp.protocol.worker.AbstractStateAwareProtocolWorker.processStanza(AbstractStateAwareProtocolWorker.java:46)
      at org.apache.vysper.xmpp.protocol.ProtocolWorker.processStanza(ProtocolWorker.java:167)
      at org.apache.vysper.xmpp.protocol.QueuedStanzaProcessor$StanzaProcessorUnitOfWork.run(QueuedStanzaProcessor.java:69)
      at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:417)
      at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:269)
      at java.util.concurrent.FutureTask.run(FutureTask.java:123)
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
      at java.lang.Thread.run(Thread.java:613)
      Caused by: org.apache.vysper.xmpp.modules.roster.RosterException: failed to add contact node to roster for user = user2@vysper.org and contact jid = user1@vysper.org
      at org.apache.vysper.storage.jcr.roster.JcrRosterManager.addContact(JcrRosterManager.java:172)
      at org.apache.vysper.xmpp.modules.core.im.handler.PresenceSubscriptionHandler.handleOutboundSubscriptionApproval(PresenceSubscriptionHandler.java:342)
      ... 13 more
      Caused by: javax.jcr.InvalidItemStateException: Item cannot be saved because it has beenmodified externally: node /accountentity/user2@vysper.org/jabber_iq_roster/user1@vysper.org
      at org.apache.jackrabbit.core.ItemImpl.getTransientStates(ItemImpl.java:246)
      at org.apache.jackrabbit.core.ItemImpl.save(ItemImpl.java:931)
      at org.apache.vysper.storage.jcr.roster.JcrRosterManager.addContact(JcrRosterManager.java:169)
      ... 14 more

        Activity

        There are no comments yet on this issue.

          People

          • Assignee:
            Bernd Fondermann
            Reporter:
            Bernd Fondermann
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:

              Development