[
https://issues.apache.org/jira/browse/KAFKA-4322?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15715322#comment-15715322
]
Damian Guy commented on KAFKA-4322:
-----------------------------------
My only concern with adding the extra methods is that it breaks compatibility.
Anyone that is currently using this feature would get a compile failure and
would need to add the relevant methods that the may or may not care about.
Otherwise i can see the benefits of adding this feature and can understand why
you would want it. At the very least i think this warrants a KIP so there can
be some discussion about it. Also, i'd like to know if there are any
alternative solutions that don't break backward compatibility and aren't
ridiculous.
> StateRestoreCallback begin and end indication
> ---------------------------------------------
>
> Key: KAFKA-4322
> URL: https://issues.apache.org/jira/browse/KAFKA-4322
> Project: Kafka
> Issue Type: Improvement
> Components: streams
> Affects Versions: 0.10.1.0
> Reporter: Mark Shelton
> Assignee: Mark Shelton
> Priority: Minor
>
> In Kafka Streams, the StateRestoreCallback interface provides only a single
> method "restore(byte[] key, byte[] value)" that is called for every key-value
> pair to be restored.
> It would be nice to have "beginRestore" and "endRestore" methods as part of
> StateRestoreCallback.
> Kafka Streams would call "beginRestore" before restoring any keys, and would
> call "endRestore" when it determines that it is done. This allows an
> implementation, for example, to report on the number of keys restored and
> perform a commit after the last key was restored. Other uses are conceivable.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)