public interface Fuseable
Fuseable.QueueSubscription
.Modifier and Type | Interface and Description |
---|---|
static interface |
Fuseable.ConditionalSubscriber<T>
A subscriber variant that can immediately tell if it consumed
the value or not, avoiding the usual request(1) for dropped
values.
|
static interface |
Fuseable.QueueSubscription<T>
Contract queue-fusion based optimizations for supporting subscriptions.
|
static interface |
Fuseable.ScalarCallable<T>
Marker interface indicating that the target can return a value or null
immediately and thus a viable target for assembly-time optimizations.
|
static interface |
Fuseable.SynchronousSubscription<T>
Base class for synchronous sources which have fixed size and can
emit its items in a pull fashion, thus avoiding the request-accounting
overhead in many cases.
|
Modifier and Type | Field and Description |
---|---|
static int |
ANY
Indicates the QueueSubscription should decide what fusion it performs (input only).
|
static int |
ASYNC
Indicates the QueueSubscription can perform only async-fusion.
|
static int |
NONE
Indicates the QueueSubscription can't support the requested mode.
|
static int |
SYNC
Indicates the QueueSubscription can perform sync-fusion.
|
static int |
THREAD_BARRIER
Indicates that the queue will be drained from another thread
thus any queue-exit computation may be invalid at that point.
|
static final int NONE
static final int SYNC
static final int ASYNC
static final int ANY
static final int THREAD_BARRIER
For example, an asyncSource.map().publishOn().subscribe()
sequence where asyncSource
is async-fuseable, publishOn may fuse the whole sequence into a single Queue which invokes the mapper
function on its poll()
method that is on another thread that whereas the unfused sequence
would have invoked the mapper on the previous thread. If such mapper is costly, it would escape its
thread bound this way.