Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tests: Add logging to a bunch of modules #7086

Merged
merged 1 commit into from
Jun 21, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions servers/jax-rs-tests/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ dependencies {
testImplementation(project(":nessie-jaxrs-testextension"))
testImplementation(libs.slf4j.jcl.over.slf4j)
testRuntimeOnly(libs.h2)
testRuntimeOnly(libs.logback.classic)

testCompileOnly(libs.microprofile.openapi)

Expand Down
30 changes: 30 additions & 0 deletions servers/jax-rs-tests/src/test/resources/logback-test.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!--

Copyright (C) 2020 Dremio

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

-->
<configuration debug="true">
<contextListener class="ch.qos.logback.classic.jul.LevelChangePropagator"/>
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%date{ISO8601} [%thread] %-5level %logger{36} - %msg%n</pattern>
</encoder>
</appender>
<root>
<level value="${test.log.level:-WARN}"/>
<appender-ref ref="console"/>
</root>
</configuration>
1 change: 1 addition & 0 deletions servers/services/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ dependencies {
testFixturesApi(project(":nessie-versioned-storage-testextension"))
testFixturesApi(project(":nessie-versioned-storage-inmemory"))
testFixturesApi(project(":nessie-versioned-storage-jdbc"))
testFixturesImplementation(libs.logback.classic)
intTestImplementation(project(":nessie-versioned-storage-cassandra"))
intTestImplementation(project(":nessie-versioned-storage-rocksdb"))
intTestImplementation(project(":nessie-versioned-storage-mongodb"))
Expand Down
30 changes: 30 additions & 0 deletions servers/services/src/intTest/resources/logback-test.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!--

Copyright (C) 2020 Dremio

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

-->
<configuration debug="true">
Copy link
Contributor

Choose a reason for hiding this comment

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

Would it be possible to have just one file inside src/testFixtures instead of 2 under src/test and src/intTest? Just curious.

<contextListener class="ch.qos.logback.classic.jul.LevelChangePropagator"/>
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%date{ISO8601} [%thread] %-5level %logger{36} - %msg%n</pattern>
</encoder>
</appender>
<root>
<level value="${test.log.level:-WARN}"/>
<appender-ref ref="console"/>
</root>
</configuration>
30 changes: 30 additions & 0 deletions servers/services/src/test/resources/logback-test.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!--

Copyright (C) 2020 Dremio

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

-->
<configuration debug="true">
<contextListener class="ch.qos.logback.classic.jul.LevelChangePropagator"/>
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%date{ISO8601} [%thread] %-5level %logger{36} - %msg%n</pattern>
</encoder>
</appender>
<root>
<level value="${test.log.level:-WARN}"/>
<appender-ref ref="console"/>
</root>
</configuration>
1 change: 1 addition & 0 deletions versioned/spi/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ dependencies {

testImplementation(platform(libs.junit.bom))
testImplementation(libs.bundles.junit.testing)
testRuntimeOnly(libs.logback.classic)

testCompileOnly(platform(libs.jackson.bom))
testCompileOnly("com.fasterxml.jackson.core:jackson-annotations")
Expand Down
30 changes: 30 additions & 0 deletions versioned/spi/src/test/resources/logback-test.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!--

Copyright (C) 2020 Dremio

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

-->
<configuration debug="true">
<contextListener class="ch.qos.logback.classic.jul.LevelChangePropagator"/>
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%date{ISO8601} [%thread] %-5level %logger{36} - %msg%n</pattern>
</encoder>
</appender>
<root>
<level value="${test.log.level:-WARN}"/>
<appender-ref ref="console"/>
</root>
</configuration>
1 change: 1 addition & 0 deletions versioned/storage/batching/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -46,4 +46,5 @@ dependencies {
testImplementation(project(path = ":nessie-protobuf-relocated", configuration = "shadow"))
testImplementation(platform(libs.junit.bom))
testImplementation(libs.bundles.junit.testing)
testRuntimeOnly(libs.logback.classic)
}
30 changes: 30 additions & 0 deletions versioned/storage/batching/src/test/resources/logback-test.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!--

Copyright (C) 2020 Dremio

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

-->
<configuration debug="true">
<contextListener class="ch.qos.logback.classic.jul.LevelChangePropagator"/>
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%date{ISO8601} [%thread] %-5level %logger{36} - %msg%n</pattern>
</encoder>
</appender>
<root>
<level value="${test.log.level:-WARN}"/>
<appender-ref ref="console"/>
</root>
</configuration>
1 change: 1 addition & 0 deletions versioned/storage/bigtable/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ dependencies {
intTestRuntimeOnly(libs.docker.java.api)
intTestImplementation(platform(libs.junit.bom))
intTestImplementation(libs.bundles.junit.testing)
intTestRuntimeOnly(libs.logback.classic)
}

// Testcontainers is not supported on Windows :(
Expand Down
30 changes: 30 additions & 0 deletions versioned/storage/bigtable/src/intTest/resources/logback-test.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!--

Copyright (C) 2020 Dremio

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

-->
<configuration debug="true">
<contextListener class="ch.qos.logback.classic.jul.LevelChangePropagator"/>
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%date{ISO8601} [%thread] %-5level %logger{36} - %msg%n</pattern>
</encoder>
</appender>
<root>
<level value="${test.log.level:-WARN}"/>
<appender-ref ref="console"/>
</root>
</configuration>
1 change: 1 addition & 0 deletions versioned/storage/cache/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -48,4 +48,5 @@ dependencies {

testImplementation(platform(libs.junit.bom))
testImplementation(libs.bundles.junit.testing)
testRuntimeOnly(libs.logback.classic)
}
30 changes: 30 additions & 0 deletions versioned/storage/cache/src/test/resources/logback-test.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!--

Copyright (C) 2020 Dremio

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

-->
<configuration debug="true">
<contextListener class="ch.qos.logback.classic.jul.LevelChangePropagator"/>
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%date{ISO8601} [%thread] %-5level %logger{36} - %msg%n</pattern>
</encoder>
</appender>
<root>
<level value="${test.log.level:-WARN}"/>
<appender-ref ref="console"/>
</root>
</configuration>
1 change: 1 addition & 0 deletions versioned/storage/cassandra/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ dependencies {
intTestRuntimeOnly(libs.docker.java.api)
intTestImplementation(platform(libs.junit.bom))
intTestImplementation(libs.bundles.junit.testing)
intTestRuntimeOnly(libs.logback.classic)
}

// Testcontainers is not supported on Windows :(
Expand Down
30 changes: 30 additions & 0 deletions versioned/storage/cassandra/src/intTest/resources/logback-test.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!--

Copyright (C) 2020 Dremio

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

-->
<configuration debug="true">
<contextListener class="ch.qos.logback.classic.jul.LevelChangePropagator"/>
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%date{ISO8601} [%thread] %-5level %logger{36} - %msg%n</pattern>
</encoder>
</appender>
<root>
<level value="${test.log.level:-WARN}"/>
<appender-ref ref="console"/>
</root>
</configuration>
1 change: 1 addition & 0 deletions versioned/storage/common/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ dependencies {
testImplementation(project(":nessie-versioned-storage-testextension"))
testImplementation(project(":nessie-versioned-storage-inmemory"))
testImplementation(project(":nessie-versioned-storage-common-tests"))
testRuntimeOnly(libs.logback.classic)

jmhImplementation(libs.jmh.core)
jmhImplementation(project(":nessie-versioned-storage-common-tests"))
Expand Down
30 changes: 30 additions & 0 deletions versioned/storage/common/src/test/resources/logback-test.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!--

Copyright (C) 2020 Dremio

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

-->
<configuration debug="true">
<contextListener class="ch.qos.logback.classic.jul.LevelChangePropagator"/>
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%date{ISO8601} [%thread] %-5level %logger{36} - %msg%n</pattern>
</encoder>
</appender>
<root>
<level value="${test.log.level:-WARN}"/>
<appender-ref ref="console"/>
</root>
</configuration>
1 change: 1 addition & 0 deletions versioned/storage/dynamodb/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ dependencies {
intTestRuntimeOnly(libs.docker.java.api)
intTestImplementation(platform(libs.junit.bom))
intTestImplementation(libs.bundles.junit.testing)
intTestRuntimeOnly(libs.logback.classic)
}

// Testcontainers is not supported on Windows :(
Expand Down
30 changes: 30 additions & 0 deletions versioned/storage/dynamodb/src/intTest/resources/logback-test.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!--

Copyright (C) 2020 Dremio

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

-->
<configuration debug="true">
<contextListener class="ch.qos.logback.classic.jul.LevelChangePropagator"/>
<appender name="console" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%date{ISO8601} [%thread] %-5level %logger{36} - %msg%n</pattern>
</encoder>
</appender>
<root>
<level value="${test.log.level:-WARN}"/>
<appender-ref ref="console"/>
</root>
</configuration>
1 change: 1 addition & 0 deletions versioned/storage/inmemory/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,5 @@ dependencies {
testImplementation(project(":nessie-versioned-storage-common-tests"))
testImplementation(platform(libs.junit.bom))
testImplementation(libs.bundles.junit.testing)
testRuntimeOnly(libs.logback.classic)
}