Skip to content

Commit

Permalink
use logger for ArrowSchema
Browse files Browse the repository at this point in the history
  • Loading branch information
asolimando committed Feb 27, 2024
1 parent d3b69d9 commit 84e1070
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,10 @@
import com.google.common.base.Suppliers;
import com.google.common.collect.ImmutableMap;

import org.apache.calcite.util.trace.CalciteTrace;

import org.checkerframework.checker.nullness.qual.Nullable;
import org.slf4j.Logger;

import java.io.File;
import java.io.FileInputStream;
Expand All @@ -44,6 +47,8 @@
* Schema mapped onto a set of Arrow files.
*/
class ArrowSchema extends AbstractSchema {

protected static final Logger LOGGER = CalciteTrace.getPlannerTracer();
private final Supplier<Map<String, Table>> tableMapSupplier;

/**
Expand Down Expand Up @@ -85,7 +90,7 @@ private static String trim(String s, String suffix) {
private static Map<String, Table> deduceTableMap(File baseDirectory) {
File[] files = baseDirectory.listFiles((dir, name) -> name.endsWith(".arrow"));
if (files == null) {
System.out.println("directory " + baseDirectory + " not found");
LOGGER.info("directory {} not found", baseDirectory);
return ImmutableMap.of();
}

Expand Down

0 comments on commit 84e1070

Please sign in to comment.