Skip to content

Support multiple log levels #495

@kevin-lee

Description

@kevin-lee

Summary

Support multiple log levels

Version

2.0.0-beta21

Description

val fa: F[A] = ...
fa.log(a => info(s"Blah blah $a") |+| debug(s"abc: $a"))


val fab: F[Either[A, B]] = ...
fab.log(
  err => error(s"Error: $err") |+| warn(s"There must be some issue") |+| debug("Something happened"),
  b => info(s"Result: $b") |+| debug("All good!")
)
val fa: F[A] = ...
fa.log(a => multiLogs(info(s"Blah blah $a"), debug(s"abc: $a")))


val fab: F[Either[A, B]] = ...
fab.log(
  err => multiLogs(
      error(s"Error: $err"),
      warn(s"There must be some issue"),
      debug("Something happened")
    ),
  b => multiLogs(
      info(s"Result: $b"),
      debug("All good!")
    )
)

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions