Conversation
c507c12 to
1ccb243
Compare
log4cats integrationlog4cats integration
| val callingMethodIndex = stacktraceElements.size - lastIndex | ||
| val callingMethod = stacktraceElements(callingMethodIndex) | ||
| val fileName = | ||
| (callingMethod.getClassName.replace('.', '/') + ".scala").split("\\/").takeRight(1).mkString |
There was a problem hiding this comment.
On JS it returns something like (<jscode>.scala:96229), not sure how to get a source file / line number.
There was a problem hiding this comment.
log4cats doesn't support sourcecode info, but it's a requirement for woof.
Perhaps, I could create a variant of Logger#doLog which doesn't require LogInfo to facilitate log4cats integration.
| override def isErrorEnabled: F[Boolean] = Applicative[F].pure(true) | ||
| override def isWarnEnabled: F[Boolean] = Applicative[F].pure(true) | ||
| override def isInfoEnabled: F[Boolean] = Applicative[F].pure(true) | ||
| override def isDebugEnabled: F[Boolean] = Applicative[F].pure(true) | ||
| override def isTraceEnabled: F[Boolean] = Applicative[F].pure(true) |
There was a problem hiding this comment.
Not sure if it's a problem, but log level filtering works.
There was a problem hiding this comment.
We have something similar in the slf4j-module:
it should probably be reflected as a limitation in the docs
1ccb243 to
b39dfe2
Compare
b39dfe2 to
50265ab
Compare
|
Sorry, I missed this one in the scala steward noise. I'll give it a look next week when I'm back to work :) |
log4cats integrationlog4cats integration
|
@igor-ramazanov did you ever fix the caveats you mentioned in the PR description? Otherwise we might close this. |
Adds
log4catsintegration withoutslf4jmiddleman.Allows using Woof with the new
http4s-1.xas it requiresLoggerFactory[F]forEmberClientBuilderandEmberServerBuilder.Works on JVM.
On JS test needs to be fixed - the
LogInfois a little wonky there.Couldn't run Native locally, apparently it hangs on linking.
Failed to run
mdoctoo.