All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.taotao.boot.idgenerator.uid.buffer.RejectedPutBufferHandler Maven / Gradle / Ivy

package com.taotao.boot.idgenerator.uid.buffer;

/**
 * If tail catches the cursor it means that the ring buffer is full, any more buffer put request will be rejected.
 * Specify the policy to handle the reject. This is a Lambda supported interface
 * 
 */
@FunctionalInterface
public interface RejectedPutBufferHandler {

    /**
     * Reject put buffer request
     * 
     * @param ringBuffer
     * @param uid
     */
    void rejectPutBuffer(RingBuffer ringBuffer, long uid);
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy