raboof commented on code in PR #1205:
URL: https://github.com/apache/pekko-connectors/pull/1205#discussion_r2366159785
##########
sse/src/main/scala/org/apache/pekko/stream/connectors/sse/scaladsl/EventSource.scala:
##########
@@ -111,7 +113,12 @@ object EventSource {
.flatMap(Unmarshal(_).to[EventSource])
.fallbackTo(Future.successful(noEvents))
}
- def recover(eventSource: EventSource) =
eventSource.recoverWithRetries(1, { case _ => noEvents })
+ def recover(eventSource: EventSource) = eventSource.recoverWithRetries(1,
+ {
+ case e =>
+ log.warning(e, "SSE Connector is retrying failed stream for: {} ",
uri)
Review Comment:
> The best code design would probably include some user-level choice about
whether to silently retry forever or be notified. I tried to stay away from
editing the code logic… otherwise I'd want to rewrite most of it. :-)
:)
Thanks for your thoughtful changes!
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]