Top Fields Constructors Methods
io.rsocket.core

pack-priv final Class RequestStreamRequesterFlux

extends Flux<Payload>
implements RequesterFrameHandler, LeasePermitHandler, Subscription, Scannable
Class Inheritance
All Implemented Interfaces
reactor.core.Scannable, org.reactivestreams.Subscription, io.rsocket.core.LeasePermitHandler, io.rsocket.core.RequesterFrameHandler, io.rsocket.core.FrameHandler
Static Imports
io.rsocket.core.PayloadValidationUtils.INVALID_PAYLOAD_ERROR_MESSAGE, .PayloadValidationUtils.isValid, .ReassemblyUtils.handleNextSupport, .SendUtils.sendReleasingPayload, io.rsocket.core.StateUtils.*

Field Summary

Modifier and TypeField and Description
pack-priv final ByteBufAllocator
pack-priv final DuplexConnection
pack-priv boolean
pack-priv CompositeByteBuf
pack-priv CoreSubscriber<? super Payload>
pack-priv final int
pack-priv final int
pack-priv final int
pack-priv final Payload
pack-priv final PayloadDecoder
pack-priv long
pack-priv long
pack-priv final RequesterLeaseTracker
pack-priv final RequesterResponderSupport
pack-priv final RequestInterceptor
pack-priv volatile long
pack-priv static final AtomicLongFieldUpdater<RequestStreamRequesterFlux>
pack-priv int

Constructor Summary

AccessConstructor and Description
pack-priv
RequestStreamRequesterFlux(Payload payload, RequesterResponderSupport requesterResponderSupport)

Method Summary

Modifier and TypeMethod and Description
public final void
cancel()

Implements org.reactivestreams.Subscription.cancel.

Request the Publisher to stop sending data and clean up resources.
public CompositeByteBuf
public final void
public final void
public void
handleNext(ByteBuf frame, boolean hasFollows, boolean isLastPayload)

Implements io.rsocket.core.FrameHandler.handleNext.

public final void
public boolean
handlePermit()

Implements io.rsocket.core.LeasePermitHandler.handlePermit.

Called by RequesterLeaseTracker when there is an available lease
public final void
handlePermitError(Throwable
associated lease permit rejection exception
cause
)

Implements io.rsocket.core.LeasePermitHandler.handlePermitError.

Called by RequesterLeaseTracker when there are no lease permit available at the moment and the list of awaiting LeasePermitHandler reached the configured limit
public final void
request(long
the strictly positive number of elements to requests to the upstream Publisher
n
)

Implements org.reactivestreams.Subscription.request.

No events will be sent by a Publisher until demand is signaled via this method.
public Object
scanUnsafe(Scannable.Attr<T>
a Attr to resolve for the component.
key
)

Implements reactor.core.Scannable.scanUnsafe.

This method is used internally by components to define their key-value mappings in a single place.
pack-priv void
sendFirstPayload(Payload payload, long initialRequestN)

public void
public String
stepName()

Overrides default reactor.core.Scannable.stepName.

Return a meaningful String representation of this Scannable in its chain of parents() and actuals().
public void
subscribe(CoreSubscriber<? super Payload>
the Subscriber interested into the published sequence
actual
)

Implements abstract reactor.core.publisher.Flux.subscribe.

Implements reactor.core.CorePublisher.subscribe.

An internal Publisher#subscribe(Subscriber) that will bypass Hooks#onLastOperator(Function) pointcut.
Inherited from reactor.core.publisher.Flux:
allanyasblockFirstblockFirstblockLastblockLastbufferbufferbufferbufferbufferbufferbufferbufferbufferbufferbufferbufferTimeoutbufferTimeoutbufferTimeoutbufferTimeoutbufferTimeoutbufferTimeoutbufferTimeoutbufferTimeoutbufferUntilbufferUntilbufferUntilChangedbufferUntilChangedbufferUntilChangedbufferWhenbufferWhenbufferWhilecachecachecachecachecachecachecancelOncastcheckpointcheckpointcheckpointcollectcollectcollectListcollectMapcollectMapcollectMapcollectMultimapcollectMultimapcollectMultimapcollectSortedListcollectSortedListcombineLatestcombineLatestcombineLatestcombineLatestcombineLatestcombineLatestcombineLatestcombineLatestcombineLatestconcatconcatconcatconcatconcatDelayErrorconcatDelayErrorconcatDelayErrorconcatDelayErrorconcatMapconcatMapconcatMapDelayErrorconcatMapDelayErrorconcatMapDelayErrorconcatMapIterableconcatMapIterableconcatWithconcatWithValuescontextCapturecontextWritecontextWritecountcreatecreatedefaultIfEmptydeferdeferContextualdelayElementsdelayElementsdelaySequencedelaySequencedelaySubscriptiondelaySubscriptiondelaySubscriptiondelayUntildematerializedistinctdistinctdistinctdistinctdistinctUntilChangeddistinctUntilChangeddistinctUntilChangeddoAfterTerminatedoFinallydoFirstdoOnCanceldoOnCompletedoOnDiscarddoOnEachdoOnErrordoOnErrordoOnErrordoOnNextdoOnRequestdoOnSubscribedoOnTerminateelapsedelapsedelementAtelementAtemptyerrorerrorerrorexpandexpandexpandDeepexpandDeepfilterfilterWhenfilterWhenfirstfirstfirstWithSignalfirstWithSignalfirstWithValuefirstWithValueflatMapflatMapflatMapflatMapflatMapDelayErrorflatMapIterableflatMapIterableflatMapSequentialflatMapSequentialflatMapSequentialflatMapSequentialDelayErrorfromfromArrayfromIterablefromStreamfromStreamgenerategenerategenerategetPrefetchgroupBygroupBygroupBygroupBygroupJoinhandlehasElementhasElementshideignoreElementsindexindexintervalintervalintervalintervaljoinjustjustlastlastlimitRatelimitRatelimitRequestloglogloglogloglogmapmapNotNullmaterializemergemergemergemergemergemergemergeComparingmergeComparingmergeComparingmergeComparingDelayErrormergeComparingWithmergeDelayErrormergeOrderedmergeOrderedmergeOrderedmergeOrderedWithmergePrioritymergePrioritymergePrioritymergePriorityDelayErrormergeSequentialmergeSequentialmergeSequentialmergeSequentialmergeSequentialmergeSequentialmergeSequentialDelayErrormergeSequentialDelayErrormergeSequentialDelayErrormergeWithmetricsnamenevernextofTypeonAssemblyonAssemblyonBackpressureBufferonBackpressureBufferonBackpressureBufferonBackpressureBufferonBackpressureBufferonBackpressureBufferonBackpressureBufferonBackpressureDroponBackpressureDroponBackpressureErroronBackpressureLatestonErrorCompleteonErrorCompleteonErrorCompleteonErrorContinueonErrorContinueonErrorContinueonErrorMaponErrorMaponErrorMaponErrorResumeonErrorResumeonErrorResumeonErrorReturnonErrorReturnonErrorReturnonErrorStoponTerminateDetachorparallelparallelparallelpublishpublishpublishpublishpublishNextpublishOnpublishOnpublishOnpushpushrangereducereducereduceWithrepeatrepeatrepeatrepeatrepeatWhenreplayreplayreplayreplayreplayreplayretryretryretryWhensamplesamplesampleFirstsampleFirstsampleTimeoutsampleTimeoutscanscanscanWithshareshareNextsinglesinglesingleOrEmptyskipskipskipskipLastskipUntilskipUntilOtherskipWhilesortsortstartWithstartWithstartWithsubscribesubscribesubscribesubscribesubscribesubscribesubscribesubscribeOnsubscribeOnsubscribeWithswitchIfEmptyswitchMapswitchMapswitchOnFirstswitchOnFirstswitchOnNextswitchOnNexttagtaketaketaketaketakeLasttakeUntiltakeUntilOthertakeWhiletaptaptapthenthenthenEmptythenManytimedtimedtimeouttimeouttimeouttimeouttimeouttimeouttimeouttimestamptimestamptoIterabletoIterabletoIterabletoStreamtoStreamtoStringtransformtransformDeferredtransformDeferredContextualusingusingusingWhenusingWhenwindowwindowwindowwindowwindowwindowwindowwindowTimeoutwindowTimeoutwindowTimeoutwindowTimeoutwindowUntilwindowUntilwindowUntilwindowUntilChangedwindowUntilChangedwindowUntilChangedwindowWhenwindowWhilewindowWhilewithLatestFromzipzipzipzipzipzipzipzipzipzipzipzipzipzipWithzipWithzipWithzipWithzipWithIterablezipWithIterable

Field Detail

allocatorback to summary
pack-priv final ByteBufAllocator allocator
connectionback to summary
pack-priv final DuplexConnection connection
doneback to summary
pack-priv boolean done
framesback to summary
pack-priv CompositeByteBuf frames
inboundSubscriberback to summary
pack-priv CoreSubscriber<? super Payload> inboundSubscriber
maxFrameLengthback to summary
pack-priv final int maxFrameLength
maxInboundPayloadSizeback to summary
pack-priv final int maxInboundPayloadSize
mtuback to summary
pack-priv final int mtu
payloadback to summary
pack-priv final Payload payload
payloadDecoderback to summary
pack-priv final PayloadDecoder payloadDecoder
producedback to summary
pack-priv long produced
requestedback to summary
pack-priv long requested
requesterLeaseTrackerback to summary
pack-priv final RequesterLeaseTracker requesterLeaseTracker
Annotations
@Nullable
requesterResponderSupportback to summary
pack-priv final RequesterResponderSupport requesterResponderSupport
requestInterceptorback to summary
pack-priv final RequestInterceptor requestInterceptor
Annotations
@Nullable
stateback to summary
pack-priv volatile long state
STATEback to summary
pack-priv static final AtomicLongFieldUpdater<RequestStreamRequesterFlux> STATE
streamIdback to summary
pack-priv int streamId

Constructor Detail

RequestStreamRequesterFluxback to summary
pack-priv RequestStreamRequesterFlux(Payload payload, RequesterResponderSupport requesterResponderSupport)

Method Detail

cancelback to summary
public final void cancel()

Implements org.reactivestreams.Subscription.cancel.

Doc from org.reactivestreams.Subscription.cancel.

Request the Publisher to stop sending data and clean up resources.

Data may still be sent to meet previously signalled demand after calling cancel.

Annotations
@Override
getFramesback to summary
public CompositeByteBuf getFrames()

Implements io.rsocket.core.RequesterFrameHandler.getFrames.

Annotations
@Override
handleCompleteback to summary
public final void handleComplete()

Implements io.rsocket.core.FrameHandler.handleComplete.

Annotations
@Override
handleErrorback to summary
public final void handleError(Throwable cause)

Implements io.rsocket.core.FrameHandler.handleError.

Annotations
@Override
handleNextback to summary
public void handleNext(ByteBuf frame, boolean hasFollows, boolean isLastPayload)

Implements io.rsocket.core.FrameHandler.handleNext.

Annotations
@Override
handlePayloadback to summary
public final void handlePayload(Payload p)

Implements io.rsocket.core.RequesterFrameHandler.handlePayload.

Annotations
@Override
handlePermitback to summary
public boolean handlePermit()

Implements io.rsocket.core.LeasePermitHandler.handlePermit.

Doc from io.rsocket.core.LeasePermitHandler.handlePermit.

Called by RequesterLeaseTracker when there is an available lease

Returns:boolean

true to indicate that lease permit was consumed successfully

Annotations
@Override
handlePermitErrorback to summary
public final void handlePermitError(Throwable cause)

Implements io.rsocket.core.LeasePermitHandler.handlePermitError.

Doc from io.rsocket.core.LeasePermitHandler.handlePermitError.

Called by RequesterLeaseTracker when there are no lease permit available at the moment and the list of awaiting LeasePermitHandler reached the configured limit

Parameters
cause:Throwable

associated lease permit rejection exception

Annotations
@Override
requestback to summary
public final void request(long n)

Implements org.reactivestreams.Subscription.request.

Doc from org.reactivestreams.Subscription.request.

No events will be sent by a Publisher until demand is signaled via this method.

It can be called however often and whenever needed—but if the outstanding cumulative demand ever becomes Long.MAX_VALUE or more, it may be treated by the Publisher as "effectively unbounded".

Whatever has been requested can be sent by the Publisher so only signal demand for what can be safely handled.

A Publisher can send less than is requested if the stream ends but then must emit either Subscriber#onError(Throwable) or Subscriber#onComplete().

Parameters
n:long

the strictly positive number of elements to requests to the upstream Publisher

Annotations
@Override
scanUnsafeback to summary
public Object scanUnsafe(Scannable.Attr<T> key)

Implements reactor.core.Scannable.scanUnsafe.

Doc from reactor.core.Scannable.scanUnsafe.

This method is used internally by components to define their key-value mappings in a single place. Although it is ignoring the generic type of the Attr key, implementors should take care to return values of the correct type, and return null if no specific value is available.

For public consumption of attributes, prefer using scan(Attr), which will return a typed value and fall back to the key's default if the component didn't define any mapping.

Parameters
key:Scannable.Attr<T>

a Attr to resolve for the component.

Returns:Object

the value associated to the key for that specific component, or null if none.

Annotations
@Override
@Nullable
sendFirstPayloadback to summary
pack-priv void sendFirstPayload(Payload payload, long initialRequestN)
setFramesback to summary
public void setFrames(CompositeByteBuf byteBuf)

Implements io.rsocket.core.RequesterFrameHandler.setFrames.

Annotations
@Override
stepNameback to summary
public String stepName()

Overrides default reactor.core.Scannable.stepName.

Doc from reactor.core.Scannable.stepName.

Return a meaningful String representation of this Scannable in its chain of parents() and actuals().

Annotations
@Override
@NonNull
subscribeback to summary
public void subscribe(CoreSubscriber<? super Payload> actual)

Implements abstract reactor.core.publisher.Flux.subscribe.

Implements reactor.core.CorePublisher.subscribe.

Doc from reactor.core.publisher.Flux.subscribe.

An internal Publisher#subscribe(Subscriber) that will bypass Hooks#onLastOperator(Function) pointcut.

In addition to behave as expected by Publisher#subscribe(Subscriber) in a controlled manner, it supports direct subscribe-time Context passing.

Parameters
actual:CoreSubscriber<? super Payload>

the Subscriber interested into the published sequence

Annotations
@Override