org.apache.activemq.artemis.core.persistence.impl.journal.codec.DeliveryCountUpdateEncoding

Here are the examples of the java api class org.apache.activemq.artemis.core.persistence.impl.journal.codec.DeliveryCountUpdateEncoding taken from open source projects.

1. AbstractJournalStorageManager#updateDeliveryCount()

View license
// Other operations
@Override
public void updateDeliveryCount(final MessageReference ref) throws Exception {
    // otherwise the journal will get OME in case of lots of redeliveries
    if (ref.getDeliveryCount() == ref.getPersistedCount()) {
        return;
    }
    ref.setPersistedCount(ref.getDeliveryCount());
    DeliveryCountUpdateEncoding updateInfo = new DeliveryCountUpdateEncoding(ref.getQueue().getID(), ref.getDeliveryCount());
    readLock();
    try {
        messageJournal.appendUpdateRecord(ref.getMessage().getMessageID(), JournalRecordIds.UPDATE_DELIVERY_COUNT, updateInfo, syncNonTransactional, getContext(syncNonTransactional));
    } finally {
        readUnLock();
    }
}