pulsar4s icon indicating copy to clipboard operation
pulsar4s copied to clipboard

Akka Source add supervision configuration

Open KannarFr opened this issue 4 years ago • 3 comments

The consumer used in the pulsar4s Akka Source is closed and stops the stream for every encountered error.

I think we should use the supervision decider optionally passed to the flow. I don't know if it's possible yet, if not we should have a way to pass a partial function to define the behavior to have during exception on consumption.

I am particularly interested in parsing issues during consumption. I would like to Skip the message and continue to the Next message. So Supervision.Resume looks good.

KannarFr avatar Dec 16 '21 15:12 KannarFr

@gmethvin WDYT?

KannarFr avatar Dec 16 '21 15:12 KannarFr

nvm, ConsumerMessage[T].valueTry should be enough.

KannarFr avatar Dec 16 '21 15:12 KannarFr

The parsing errors are already exposed with valueTry but there might be others where it would make sense to use a supervision decider.

gmethvin avatar Dec 16 '21 18:12 gmethvin