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

com.github.wz2cool.localqueue.IReader Maven / Gradle / Ivy

There is a newer version: 0.0.6
Show newest version
package com.github.wz2cool.localqueue;

import com.github.wz2cool.localqueue.model.message.QueueMessage;

import java.util.List;
import java.util.Optional;
import java.util.concurrent.TimeUnit;

public interface IReader {

    QueueMessage take() throws InterruptedException;

    List batchTake(int maxBatchSize) throws InterruptedException;

    Optional take(long timeout, TimeUnit unit) throws InterruptedException;

    List batchTake(int maxBatchSize, long timeout, TimeUnit unit) throws InterruptedException;

    Optional poll();

    List batchPoll(int maxBatchSize);

    void ack(long position);

    void ack(List messages);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy