src/main/java/io/reactivex/Flowable.java
@CheckReturnValue
    @BackpressureSupport(BackpressureKind.PASS_THROUGH)
    @SchedulerSupport(SchedulerSupport.NONE)
    public final Flowable<T> doFinally(Action onFinally) {
        ObjectHelper.requireNonNull(onFinally, "onFinally is null");
        return RxJavaPlugins.onAssembly(new FlowableDoFinally<T>(this, onFinally));
    }
@CheckReturnValue
    @BackpressureSupport(BackpressureKind.PASS_THROUGH)
    @SchedulerSupport(SchedulerSupport.NONE)
    public final Flowable<T> doFinally(Action onFinally) {
        ObjectHelper.requireNonNull(onFinally, "onFinally is null");
        return RxJavaPlugins.onAssembly(new FlowableDoFinally<T>(this, onFinally));
    }
@ CheckReturnValue @ BackpressureSupport ( BackpressureKind . PASS_THROUGH ) @ SchedulerSupport ( SchedulerSupport . NONE ) public final Flowable < T > doFinally ( Action onFinally ) { ObjectHelper . requireNonNull ( onFinally , "onFinally is null" ) ; return RxJavaPlugins . onAssembly ( new FlowableDoFinally < T > ( this , onFinally ) ) ; }
Calls the specified action after this Flowable signals onError or onCompleted or gets canceled by
the downstream.
<p>In case of a race between a terminal event and a cancellation, the provided {@code onFinally} action
is executed once per subscription.
<p>Note that the {@code onFinally} action is shared between subscriptions and as such
should be thread-safe.
<dl>
<dt><b>Backpressure:</b></dt>
<dd>The operator doesn't interfere with backpressure which is determined by the source {@code Publisher}'s backpressure
behavior.</dd>
<dt><b>Scheduler:</b></dt>
<dd>{@code doFinally} does not operate by default on a particular {@link Scheduler}.</dd>
<dt><b>Operator-fusion:</b></dt>
<dd>This operator supports normal and conditional Subscribers as well as boundary-limited
synchronous or asynchronous queue-fusion.</dd>
</dl>
<p>History: 2.0.1 - experimental
@param onFinally the action called when this Flowable terminates or gets canceled
@return the new Flowable instance
@since 2.1
Calls the specified action after this Flowable signals onError or onCompleted or gets canceled by the downstream . <p > In case of a race between a terminal event and a cancellation the provided {