Skip to content

Commit c7fbf67

Browse files
authored
Merge pull request #15275 from dauer/issue-14379-remove-dependency-to-tomcat-embed-logging-log4j
Issue 14379 remove dependency to tomcat embed logging log4j
2 parents 82bd3e9 + 05db61e commit c7fbf67

File tree

3 files changed

+11
-10
lines changed

3 files changed

+11
-10
lines changed

grails-data-graphql/core/build.gradle

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@ dependencies {
4040
testImplementation 'com.github.fakemongo:fongo:2.1.1'
4141
testImplementation 'com.h2database:h2:2.2.224'
4242
testImplementation 'org.apache.tomcat:tomcat-jdbc:8.5.97'
43-
testImplementation "org.apache.tomcat.embed:tomcat-embed-logging-log4j:8.5.2"
4443
testImplementation "org.slf4j:slf4j-api:$slf4jVersion"
4544
}
4645

grails-data-graphql/examples/spring-boot-app/build.gradle

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,6 @@ dependencies {
5252
implementation 'junit:junit'
5353
runtimeOnly 'com.h2database:h2'
5454
runtimeOnly 'org.apache.tomcat:tomcat-jdbc'
55-
runtimeOnly "org.apache.tomcat.embed:tomcat-embed-logging-log4j"
5655
implementation 'jakarta.persistence:jakarta.persistence-api'
5756

5857
runtimeOnly "javax.el:javax.el-api"

grails-data-hibernate5/docs/src/docs/asciidoc/gettingStarted/outsideGrails.adoc

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -17,21 +17,21 @@ specific language governing permissions and limitations
1717
under the License.
1818
////
1919

20-
If you wish to use GORM for Hibernate outside of a Grails application you should declare the necessary dependencies for GORM and the database you are using, for example in Gradle:
20+
If you wish to use GORM for Hibernate outside a Grails application you should declare the necessary dependencies for GORM and the database you are using, for example in Gradle:
2121

2222
[source,groovy,subs="attributes"]
2323
----
24-
compile "org.apache.grails.data:grails-data-hibernate5-core:{version}"
25-
runtime "com.h2database:h2:1.4.192"
26-
runtime "org.apache.tomcat:tomcat-jdbc:8.5.0"
27-
runtime "org.apache.tomcat.embed:tomcat-embed-logging-log4j:8.5.0"
28-
runtime "org.slf4j:slf4j-api:1.7.10"
24+
implementation platform("org.apache.grails:grails-bom:{version}")
25+
implementation "org.apache.grails.data:grails-data-hibernate5-core"
26+
runtimeOnly "com.h2database"
27+
runtimeOnly "org.apache.tomcat:tomcat-jdbc"
28+
runtimeOnly "org.slf4j:slf4j-nop"
2929
----
3030

3131
NOTE: The above example also uses the https://www.h2database.com[H2 Database] and Tomcat connection pool.
32-
However other pool implementations are supported including `commons-dbcp`, `tomcat pool` or `hikari`.
32+
However, other pool implementations are supported including `commons-dbcp`, `tomcat pool` or `hikari`.
3333
If a connection pool is not specified `org.springframework.jdbc.datasource.DriverManagerDataSource` is used,
34-
which creates a new connection to the database each time you request a connect.
34+
which creates a new connection to the database each time you request a connection.
3535
The latter will probably cause issues with an H2 in-memory database in that it will create a new in-memory
3636
database each time a connection is requested, losing previously created tables.
3737
Normal databases (`MySql`, `Postgres` or even file-based `H2`) are not affected.
@@ -40,6 +40,9 @@ Then create your entities in the `src/main/groovy` directory and annotate them w
4040

4141
[source,groovy]
4242
----
43+
import grails.gorm.annotation.Entity
44+
import org.grails.datastore.gorm.GormEntity
45+
4346
@Entity
4447
class Person implements GormEntity<Person> { // <1>
4548
String firstName

0 commit comments

Comments
 (0)