I have a state store being built from a stream with a custom set of value serdes. In the stream processing I am able to handle errors appropriately with the exception handler, but if I attempt to do a state store getAll and use the iterator.hasNext() or next() or peek methods, any exceptions in the deserialization are thrown. This is proving to be difficult to iterate over the items in the state store and skip bad entries or remove them. I can see different ways this could happen, such as avro schema removed from schema registry (and cache) for an item in the state store. Am I missing an easy way to deal with deserialization exceptions stemming from state store iterator or gets? I will keep playing around, but it was hard to find a way to reliably use the iterator (getAll) when hasNext, next, peekNext, etc all throw exceptions.
Thanks for any help or pointers on how to properly handle exceptions in this case. Carl
