Interface Subscription
- All Superinterfaces:
Cancelable
The
Subscription
is the link to the actual running Task
.
Due to the asynchronous nature of the Task
execution a Subscription
might not immediately become
active. isActive()
provides an answer if the underlying Task
is already running.
- Since:
- 2.2
- Author:
- Mark Paluch
-
Method Summary
Methods inherited from interface org.springframework.data.redis.stream.Cancelable
cancel
-
Method Details
-
isActive
boolean isActive()- Returns:
- true if the subscription is currently executed.
-
await
- Parameters:
timeout
- must not be null.- Returns:
true
if the subscription was activated.false
if the waiting time elapsed before task was activated.- Throws:
InterruptedException
- if the current thread is interrupted while waiting.
-