timeout

fun Completable.timeout(timeout: Duration, scheduler: Scheduler, other: Completable? = null): Completable

Disposes the current Completable if it does not signal within the timeout, and subscribes to other if provided.

Please refer to the corresponding RxJava document.