Package akka.stream
Interface RestartSettings.RestartFailure
-
- Enclosing class:
- RestartSettings
public static interface RestartSettings.RestartFailureA failure that restarts the stream, passed to the callback ofLogSettings.withFailureLogging.Instances are created by Akka streams. It is a trait so that a callback can be unit tested with an instance created by the test, but it should not be implemented for other purposes, as members may be added in future releases.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.Throwablecause()The failure that restarts the streamintconsecutiveFailures()The number of consecutive restarts including this one, as shown in the default log message.Logging.LogLeveldefaultLogLevel()The level the default logging would log this failure at, as decided by theRestartSettings.LogSettingsand the stream attributes.booleandefaultVerbose()If the default logging would include the stack trace of the failure, always false if it would not log itLoggingAdapterlog()The logging adapter of the restarting stagevoidlogDefault()Log the failure in the same way as the default logging, for failures the callback does not handle itself.
-
-
-
Method Detail
-
cause
java.lang.Throwable cause()
The failure that restarts the stream
-
consecutiveFailures
int consecutiveFailures()
The number of consecutive restarts including this one, as shown in the default log message. Restarts because of completion are counted too.
-
defaultLogLevel
Logging.LogLevel defaultLogLevel()
The level the default logging would log this failure at, as decided by theRestartSettings.LogSettingsand the stream attributes.Attributes.LogLevels.Off(Java:Attributes.logLevelOff()) if it would not be logged.
-
defaultVerbose
boolean defaultVerbose()
If the default logging would include the stack trace of the failure, always false if it would not log it
-
log
LoggingAdapter log()
The logging adapter of the restarting stage
-
logDefault
void logDefault()
Log the failure in the same way as the default logging, for failures the callback does not handle itself. Must only be called from within the callback, on the thread that invokes it. The other members are snapshots that stay valid after the callback returns, this method does not.
-
-