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

cn.sliew.carp.module.queue.redis.test1.Queue Maven / Gradle / Ivy

There is a newer version: 0.0.14
Show newest version
package cn.sliew.carp.module.queue.redis.test1;

import java.time.Duration;
import java.time.temporal.TemporalAmount;
import java.util.List;
import java.util.concurrent.TimeUnit;
import java.util.function.BiConsumer;
import java.util.function.Consumer;

public interface Queue {

    void pull(Consumer callback);

    void pull(Integer maxMessages, Consumer callback);

    void push(TestMessage message);

    void push(TestMessage message, TemporalAmount delay);

    default void reschedule(TestMessage message) {
        reschedule(message, Duration.ZERO);
    }

    void reschedule(TestMessage message, TemporalAmount delay);

    void ensure(TestMessage message, TemporalAmount delay);

    default void retry() {

    }

    default void clear() {

    }

    TemporalAmount getAckTimeout();

    List> getDeadMessageCallbacks();

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy