Class TLSClosing
- Direct Known Subclasses:
EagerClose,IgnoreBoth,IgnoreCancel,IgnoreComplete
When integrating a full-duplex transport medium that does not support
half-closing (which means ending one direction of data transfer without
ending the other) into a stream topology, there can be unexpected effects.
Feeding a finite Source into this medium will close the connection after
all elements have been sent, which means that possible replies may not
be received in full. To support this type of usage, the sending and
receiving of data on the same side (e.g. on the Client) need to be
coordinated such that it is known when all replies have been received.
Only then should the transport be shut down.
To support these scenarios it is recommended that the full-duplex transport integration is configurable in terms of termination handling, which means that the user can optionally suppress the normal (closing) reaction to completion or cancellation events, as is expressed by the possible values of this type:
- EagerClose means to not ignore signals
- IgnoreCancel means to not react to cancellation of the receiving
side unless the sending side has already completed
- IgnoreComplete means to not react to the completion of the sending
side unless the receiving side has already canceled
- IgnoreBoth means to ignore the first termination signal—be that
cancellation or completion—and only act upon the second one
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic TLSClosingJava API: obtain theEagerClosesingleton value.static TLSClosingJava API: obtain theIgnoreBothsingleton value.abstract booleanabstract boolean
-
Constructor Details
-
TLSClosing
public TLSClosing()
-
-
Method Details
-
eagerClose
Java API: obtain theEagerClosesingleton value. -
ignoreBoth
Java API: obtain theIgnoreBothsingleton value. -
ignoreCancel
public abstract boolean ignoreCancel() -
ignoreComplete
public abstract boolean ignoreComplete()
-