Non-blocking credit for a unicast destination.
Instead of blocking when insufficient credits are available for sending a message, this class queues the
message and sends it at a later time when enough credits have been received to send it.
Author: Bela Ban
Constructor and Description
java.util.concurrent.locks.Lock lock) NonBlockingCredit
java.util.function.Consumer< NonBlockingCredit Message> send_function)
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
public NonBlockingCredit(long credits,
public void reset()
public boolean decrementIfEnoughCredits(
Decrements the sender's credits by the size of the message.
msg - The message
credits - The number of bytes to decrement the credits. Is
timeout - Ignored
Returns: True if the message was sent, false if it was queued
Copyright © 1998-2020 Red Hat. All Rights Reserved.