cadonna commented on a change in pull request #11499: URL: https://github.com/apache/kafka/pull/11499#discussion_r749478922
########## File path: streams/src/main/java/org/apache/kafka/streams/processor/internals/StateUpdater.java ########## @@ -0,0 +1,50 @@ +package org.apache.kafka.streams.processor.internals; + +import java.time.Duration; +import java.util.List; + +public interface StateUpdater { + + /** + * Adds a task (active or standby) to the state updater. + * + * The state of the task will be updated. + * + * @param task task + */ + void add(final Task task); + + /** + * Removes a task (active and standby) from the state updater. + * + * A task is removed from the state updater irrespective of whether its state is up-to-date or not. + * + * @param task tasks to remove + */ + void remove(final Task task); + + /** + * Gets restored active tasks from state restoration/update + * + * @param timeout duration how long the calling thread should wait for restored active tasks + * + * @return list of active tasks with up-to-date states + */ + List<StreamTask> getRestoredActiveTasks(final Duration timeout); Review comment: When the restoration of an active task is completed, the task is returned call to this method. The calling thread can decide how long to wait for the next restored active tasks. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org