Skip to content

Commit

Permalink
Enable warning/error logs from libraries in tests
Browse files Browse the repository at this point in the history
Warning and errors are rarely seen by engineers, but still it's better
not to hide them, they may (now or in the future) contain some
actionable information. When a library over-verbosely logs some
warnings/errors, let's suppress these selectively.
  • Loading branch information
findepi committed May 29, 2024
1 parent 54f563c commit 5e5b9c2
Show file tree
Hide file tree
Showing 13 changed files with 17 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,9 @@ public final class AccumuloQueryRunner
{
static {
Logging logging = Logging.initialize();
logging.setLevel("org.apache.accumulo", Level.OFF);
logging.setLevel("org.apache.zookeeper", Level.OFF);
logging.setLevel("org.apache.curator", Level.OFF);
logging.setLevel("org.apache.accumulo", Level.WARN);
logging.setLevel("org.apache.zookeeper", Level.WARN);
logging.setLevel("org.apache.curator", Level.WARN);
}

private static final Logger LOG = Logger.get(AccumuloQueryRunner.class);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ public final class BigQueryQueryRunner

static {
Logging logging = Logging.initialize();
logging.setLevel("com.google.cloud.bigquery.storage", Level.OFF);
logging.setLevel("com.google.cloud.bigquery.storage", Level.WARN);
}

private BigQueryQueryRunner() {}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ private CassandraQueryRunner() {}

static {
Logging logging = Logging.initialize();
logging.setLevel("com.datastax.oss.driver.internal", Level.OFF);
logging.setLevel("com.datastax.oss.driver.internal", Level.WARN);
}

public static Builder builder(CassandraServer server)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public final class ClickHouseQueryRunner
{
static {
Logging logging = Logging.initialize();
logging.setLevel("com.clickhouse.jdbc.internal", Level.OFF);
logging.setLevel("com.clickhouse.jdbc.internal", Level.WARN);
}

public static final String TPCH_SCHEMA = "tpch";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,9 @@ public final class DeltaLakeQueryRunner
{
static {
Logging logging = Logging.initialize();
logging.setLevel("org.apache.parquet.filter2.compat.FilterCompat", Level.OFF);
logging.setLevel("com.amazonaws.util.Base64", Level.OFF);
logging.setLevel("com.google.cloud", Level.OFF);
logging.setLevel("org.apache.parquet.filter2.compat.FilterCompat", Level.WARN);
logging.setLevel("com.amazonaws.util.Base64", Level.WARN);
logging.setLevel("com.google.cloud", Level.WARN);
}

public static final String DELTA_CATALOG = "delta";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ private ElasticsearchQueryRunner() {}

static {
Logging logging = Logging.initialize();
logging.setLevel("org.elasticsearch.client.RestClient", Level.OFF);
logging.setLevel("org.elasticsearch.client.RestClient", Level.WARN);
}

private static final Logger LOG = Logger.get(ElasticsearchQueryRunner.class);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ private HudiQueryRunner() {}

static {
Logging logging = Logging.initialize();
logging.setLevel("org.apache.hudi", Level.OFF);
logging.setLevel("org.apache.hudi", Level.WARN);
}

private static final String SCHEMA_NAME = "tests";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ private IcebergQueryRunner() {}

static {
Logging logging = Logging.initialize();
logging.setLevel("org.apache.iceberg", Level.OFF);
logging.setLevel("org.apache.iceberg", Level.WARN);
}

public static Builder builder()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ private KafkaQueryRunner() {}

static {
Logging logging = Logging.initialize();
logging.setLevel("org.apache.kafka", Level.OFF);
logging.setLevel("org.apache.kafka", Level.WARN);
}

private static final Logger log = Logger.get(KafkaQueryRunner.class);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public final class MariaDbQueryRunner
{
static {
Logging logging = Logging.initialize();
logging.setLevel("org.mariadb.jdbc", Level.OFF);
logging.setLevel("org.mariadb.jdbc", Level.WARN);
}

private static final String TPCH_SCHEMA = "tpch";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ private MongoQueryRunner() {}

static {
Logging logging = Logging.initialize();
logging.setLevel("org.mongodb.driver", Level.OFF);
logging.setLevel("org.mongodb.driver", Level.WARN);
}

private static final String TPCH_SCHEMA = "tpch";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ private OpenSearchQueryRunner() {}

static {
Logging logging = Logging.initialize();
logging.setLevel("org.opensearch.client.RestClient", Level.OFF);
logging.setLevel("org.opensearch.client.RestClient", Level.WARN);
}

private static final Logger LOG = Logger.get(OpenSearchQueryRunner.class);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ private SqlServerQueryRunner() {}

static {
Logging logging = Logging.initialize();
logging.setLevel("com.microsoft.sqlserver.jdbc", Level.OFF);
logging.setLevel("com.microsoft.sqlserver.jdbc", Level.WARN);
}

private static final Logger log = Logger.get(SqlServerQueryRunner.class);
Expand Down

0 comments on commit 5e5b9c2

Please sign in to comment.