make Actor exception logging configurable
Exceptions which are passed on through Futures and get handled by other user code should be possible to silence. I propose a setting for configuring the logging of exceptions:
- log ALL exceptions
- log NONE
- log only SWALLOWED
I would only include Future in the last category, since supervised restarts go through preRestart(cause, ...) user hook where logging can easily be added.
- log ALL exceptions
- log NONE
- log only SWALLOWED
I would only include Future in the last category, since supervised restarts go through preRestart(cause, ...) user hook where logging can easily be added.
Leave a comment
on 2011-08-14 14:27 *
By viktorklang
I think this ticket should be renamed to "harmonized and establish a strategy for handling thrown things inside Futures.
on 2011-08-14 17:02 *
By Derek Williams
Yes, there should be an option to silence exception logging with future, especially for when the exception is going to be contained within a future.
I made a post on the mailing list related to this before, and something else we should come up with is a policy on how exceptions are handled in these cases. I'm pretty sure the current strategy used within futures is based on how netty handles it's futures (as the method names look awfully familiar) and it uses catch-alls to handle exceptions as well.
I've tried to find a good reference on how to handle this in the context of a framework like Akka, but havent found anything. Especially when it comes to flow control throwables, interrupt exceptions, errors, etc.
I might come up with a draft policy (if I find the time) in order to get feedback, especially from those with lots of Java experience. We'll see :)
I made a post on the mailing list related to this before, and something else we should come up with is a policy on how exceptions are handled in these cases. I'm pretty sure the current strategy used within futures is based on how netty handles it's futures (as the method names look awfully familiar) and it uses catch-alls to handle exceptions as well.
I've tried to find a good reference on how to handle this in the context of a framework like Akka, but havent found anything. Especially when it comes to flow control throwables, interrupt exceptions, errors, etc.
I might come up with a draft policy (if I find the time) in order to get feedback, especially from those with lots of Java experience. We'll see :)