Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- interpretDataLogNoop :: forall a r. InterpreterFor (DataLog a) r
- interpretDataLogLocalNoop :: forall a r. (a -> a) -> InterpreterFor (DataLog a) r
- interpretDataLogToJsonStdout :: forall e a r. Member (Embed IO) r => (e -> Value) -> Sem (DataLog e : r) a -> Sem r a
- logEntryToJson :: forall a. (a -> Value) -> LogEntry a -> Value
- logMessageToJson :: LogMessage -> Value
- annotateCs :: forall a r. Member GhcTime r => CallStack -> a -> Sem r (LogEntry a)
- logCs :: Members [Logger, GhcTime] r => CallStack -> Severity -> Text -> Sem r ()
- setLogLevelFromEnv :: HasCallStack => Member (DataLog (LogEntry LogMessage)) r => Member (Embed IO) r => String -> Severity -> Sem r a -> Sem r a
Documentation
interpretDataLogNoop :: forall a r. InterpreterFor (DataLog a) r Source #
interpretDataLogLocalNoop :: forall a r. (a -> a) -> InterpreterFor (DataLog a) r Source #
interpretDataLogToJsonStdout :: forall e a r. Member (Embed IO) r => (e -> Value) -> Sem (DataLog e : r) a -> Sem r a Source #
logMessageToJson :: LogMessage -> Value Source #
annotateCs :: forall a r. Member GhcTime r => CallStack -> a -> Sem r (LogEntry a) Source #
Log a datalog message with the given severity and provided callstack.
logCs :: Members [Logger, GhcTime] r => CallStack -> Severity -> Text -> Sem r () Source #
Log a text message with the given severity and provided callstack.
setLogLevelFromEnv :: HasCallStack => Member (DataLog (LogEntry LogMessage)) r => Member (Embed IO) r => String -> Severity -> Sem r a -> Sem r a Source #
Set the log level for the duration of the computation to the severity provided in the environment variable of the given name or else the default severity for the duration of the computation.
Values for the log level are case-insensitive and can be one of the following:
- trace
- debug
- info
- warn
- error
- crit