Package org.hornetq.core.journal

Examples of org.hornetq.core.journal.RecordInfo


      {
         beforeJournalOperation();

         journal.appendDeleteRecordTransactional(txID, element);

         tx.deletes.add(new RecordInfo(element, (byte)0, null, true, (short)0));
      }

      journal.debugWait();
   }
View Full Code Here


   protected void removeRecordsForID(final long id)
   {
      for (ListIterator<RecordInfo> iter = records.listIterator(); iter.hasNext();)
      {
         RecordInfo info = iter.next();

         if (info.id == id)
         {
            iter.remove();
         }
View Full Code Here

      Iterator<RecordInfo> iterActual = actual.iterator();

      while (iterExpected.hasNext())
      {
         RecordInfo rexpected = iterExpected.next();

         RecordInfo ractual = iterActual.next();

         if (rexpected.id != ractual.id || rexpected.isUpdate != ractual.isUpdate)
         {
            printJournalLists(expected, actual);
         }
View Full Code Here

         {
            operation = lineProperties.getProperty("operation");

            if (operation.equals("AddRecord"))
            {
               RecordInfo info = ImportJournal.parseRecord(lineProperties);
               journal.appendAddRecord(info.id, info.userRecordType, info.data, false);
            }
            else if (operation.equals("AddRecordTX"))
            {
               long txID = ImportJournal.parseLong("txID", lineProperties);
               AtomicInteger counter = ImportJournal.getCounter(txID, txCounters);
               counter.incrementAndGet();
               RecordInfo info = ImportJournal.parseRecord(lineProperties);
               journal.appendAddRecordTransactional(txID, info.id, info.userRecordType, info.data);
            }
            else if (operation.equals("AddRecordTX"))
            {
               long txID = ImportJournal.parseLong("txID", lineProperties);
               AtomicInteger counter = ImportJournal.getCounter(txID, txCounters);
               counter.incrementAndGet();
               RecordInfo info = ImportJournal.parseRecord(lineProperties);
               journal.appendAddRecordTransactional(txID, info.id, info.userRecordType, info.data);
            }
            else if (operation.equals("UpdateTX"))
            {
               long txID = ImportJournal.parseLong("txID", lineProperties);
               AtomicInteger counter = ImportJournal.getCounter(txID, txCounters);
               counter.incrementAndGet();
               RecordInfo info = ImportJournal.parseRecord(lineProperties);
               journal.appendUpdateRecordTransactional(txID, info.id, info.userRecordType, info.data);
            }
            else if (operation.equals("Update"))
            {
               RecordInfo info = ImportJournal.parseRecord(lineProperties);
               journal.appendUpdateRecord(info.id, info.userRecordType, info.data, false);
            }
            else if (operation.equals("DeleteRecord"))
            {
               long id = ImportJournal.parseLong("id", lineProperties);
View Full Code Here

   {
      long id = ImportJournal.parseLong("id", properties);
      byte userRecordType = ImportJournal.parseByte("userRecordType", properties);
      boolean isUpdate = ImportJournal.parseBoolean("isUpdate", properties);
      byte[] data = ImportJournal.parseEncoding("data", properties);
      return new RecordInfo(id, userRecordType, data, isUpdate, (short)0);
   }
View Full Code Here

            long percent = (long)((((double)reccount) / ((double)totalSize)) * 100f);

            log.info(percent + "% loaded");
         }

         RecordInfo record = records.get(reccount);
         byte[] data = record.data;

         HornetQBuffer buff = HornetQBuffers.wrappedBuffer(data);

         byte recordType = record.getUserRecordType();

         switch (recordType)
         {
            case ADD_LARGE_MESSAGE:
            {
View Full Code Here

               long percent = (long)((((double)reccount) / ((double)totalSize)) * 100f);

               HornetQServerLogger.LOGGER.percentLoaded(percent);
            }

            RecordInfo record = records.get(reccount);
            byte[] data = record.data;

            HornetQBuffer buff = HornetQBuffers.wrappedBuffer(data);

            byte recordType = record.getUserRecordType();

            switch (recordType)
            {
               case ADD_LARGE_MESSAGE_PENDING:
               {
View Full Code Here

               long percent = (long) ((((double) reccount) / ((double) totalSize)) * 100f);

               HornetQServerLogger.LOGGER.percentLoaded(percent);
            }

            RecordInfo record = records.get(reccount);
            byte[] data = record.data;

            HornetQBuffer buff = HornetQBuffers.wrappedBuffer(data);

            byte recordType = record.getUserRecordType();

            switch (recordType)
            {
               case JournalRecordIds.ADD_LARGE_MESSAGE_PENDING:
               {
View Full Code Here

         beforeJournalOperation();

         journal.appendAddRecord(element, (byte)0, record, sync);

         records.add(new RecordInfo(element, (byte)0, record, false, (short)0));
      }

      journal.debugWait();
   }
View Full Code Here

         beforeJournalOperation();

         journal.appendUpdateRecord(element, (byte)0, updateRecord, sync);

         records.add(new RecordInfo(element, (byte)0, updateRecord, true, (short)0));
      }

      journal.debugWait();
   }
View Full Code Here

TOP

Related Classes of org.hornetq.core.journal.RecordInfo

Copyright © 2018 www.massapicom. 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.