Package org.apache.sandesha2.storage.beanmanagers

Examples of org.apache.sandesha2.storage.beanmanagers.SequencePropertyBeanMgr.update()


            }

            MessageRetransmissionAdjuster retransmitterAdjuster = new MessageRetransmissionAdjuster();
            retransmitterAdjuster.adjustRetransmittion(bean);

            mgr.update(bean);

            if (!msgCtx.isServerSide())
              checkForSyncResponses(msgCtx);
           
           
View Full Code Here


          //update if resend=true otherwise delete. (reSend=false
          // means
          // send only once).
          if (bean.isReSend())
            mgr.update(bean);
          else
            mgr.delete(bean.getMessageId());

        }
      } catch (SandeshaException e) {
View Full Code Here

          .retrieve(senderBean.getMessageID());
      if (bean1 != null) {
        if (senderBean.isReSend()) {
          bean1.setSentCount(senderBean.getSentCount());
          bean1.setTimeToSend(senderBean.getTimeToSend());
          senderBeanMgr.update(bean1);
        } else {
          senderBeanMgr.delete(bean1.getMessageID());

          // removing the message from the storage.
          String messageStoredKey = bean1.getMessageContextRefKey();
View Full Code Here

    lastActivatedBean.setValue(Long.toString(currentTime));

    if (added)
      sequencePropertyBeanMgr.insert(lastActivatedBean);
    else
      sequencePropertyBeanMgr.update(lastActivatedBean);

  }

  public static long getLastActivatedTime(String propertyKey, StorageManager storageManager) throws SandeshaException {
View Full Code Here

    noOfMsgsAckedBean.setValue(Long.toString(noOfMsgsAcked));

    if (added)
      seqPropMgr.insert(noOfMsgsAckedBean);
    else
      seqPropMgr.update(noOfMsgsAckedBean);

    // setting the completed_messages list. This gives all the messages of
    // the sequence that were acked.
    SequencePropertyBean allCompletedMsgsBean = seqPropMgr.retrieve(sequencePropertyKey,
        Sandesha2Constants.SequenceProperties.CLIENT_COMPLETED_MESSAGES);
View Full Code Here

    }

    String str = ackedMessagesList.toString();
    allCompletedMsgsBean.setValue(str);

    seqPropMgr.update(allCompletedMsgsBean);

    String lastOutMsgNoStr = SandeshaUtil.getSequenceProperty(sequencePropertyKey,
        Sandesha2Constants.SequenceProperties.LAST_OUT_MESSAGE_NO, storageManager);
    if (lastOutMsgNoStr != null) {
      long highestOutMsgNo = 0;
View Full Code Here

              receivedMsgsBean.setValue(receivedMsgStr);
             
              //TODO correct the syntac into '[received msgs]'
             
              seqPropMgr.update(receivedMsgsBean);

              ApplicationMsgProcessor ackProcessor = new ApplicationMsgProcessor();
              ackProcessor.sendAckIfNeeded(rmMsgContext,
                  receivedMsgStr);
View Full Code Here

            log.debug(message);
            allSequencesItr.remove();
           
            //cleaning the invalid data of the all sequences.
            allSequencesBean.setValue(allSequencesList.toString());
            sequencePropMgr.update(allSequencesBean)
           
            throw new SandeshaException (message);
          }

          long nextMsgno = nextMsgBean.getNextMsgNoToProcess();
View Full Code Here

      ArrayList allSequenceList = SandeshaUtil.getArrayListFromString(allSequenceBean.getValue());
      allSequenceList.remove(sequenceID);
   
      //updating
      allSequenceBean.setValue(allSequenceList.toString());
      sequencePropertyBeanMgr.update(allSequenceBean);
    }
  }
 
  private static boolean isRequiredForResponseSide (String name) {
    if (name==null && name.equals(Sandesha2Constants.SequenceProperties.LAST_OUT_MESSAGE_NO))
View Full Code Here

      String str = new Long(msgNo).toString();
      SequencePropertyBean highestMsgNoBean = new SequencePropertyBean (sequenceId,Sandesha2Constants.SequenceProperties.HIGHEST_IN_MSG_NUMBER,str);
      SequencePropertyBean highestMsgKeyBean = new SequencePropertyBean (sequenceId,Sandesha2Constants.SequenceProperties.HIGHEST_IN_MSG_KEY,key);
     
      if (highetsInMsgNoStr!=null) {
        seqPropMgr.update(highestMsgNoBean);
        seqPropMgr.update(highestMsgKeyBean);
      }else{
        seqPropMgr.insert(highestMsgNoBean);
        seqPropMgr.insert(highestMsgKeyBean);
      }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.