Skip to content

Conversation

@dauer
Copy link
Contributor

@dauer dauer commented Dec 5, 2025

Issue 14379 Remove dependency to tomcat-embed-logging-log4j

Fixes #14379

The dependency tomcat-embed-logging-log4j is old, unmaintained and
should not be used.

Updated Hibernate documentation and related example.

Removed tomcat-embed-logging-log4j dependency from GraphQL
The GraphQL code is not active in the grails-core project but I removed
the dependency anyway - it should not be there if we reintroduce the
code again.

dauer added 2 commits December 5, 2025 13:55
The dependency 'tomcat-embed-logging-log4j' is old, unmaintained and
should not be used.
Updated Hibernate documentation and example

apache#14379
The GraphQL code is not active in the grails-core project but I removed
the dependency anyway - it should not be there if we reintroduce the
code again.
@dauer dauer self-assigned this Dec 5, 2025
implementation "org.apache.grails.data:grails-data-hibernate5-core"
runtimeOnly "com.h2database"
runtimeOnly "org.apache.tomcat:tomcat-jdbc"
runtimeOnly "org.slf4j:slf4j-nop"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why recommend nop instead of api? Don't we want the slf4j logging?

Copy link
Contributor Author

@dauer dauer Dec 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just picked the bare minimum - using api is probably a better choise, for a more realistic example.
I wrote a short example for testing, and added nop to get rid of this message:

> Task :Main.main()
SLF4J(W): No SLF4J providers were found.
SLF4J(W): Defaulting to no-operation (NOP) logger implementation
SLF4J(W): See https://www.slf4j.org/codes.html#noProviders for further details.

Copy link
Contributor

@matrei matrei Dec 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't slf4j-api only be used as implementation or compileOnly (if it is provided) and only if the slf4j API is used in the implementation of a library. In that case the downstream user chooses the runtime implementation. In this case, I think a slf4j implementation (like slf4j-nop) is the right choice.

@jdaugherty jdaugherty merged commit c7fbf67 into apache:7.0.x Dec 12, 2025
36 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Remove dependency to tomcat-embed-logging-log4j

3 participants