public abstract class CalciteTrace extends Object
tracers used within
org.apache.calcite class libraries.
Please ensure that every tracer used in org.apache.calcite is added to
this class as a public static final member called
componentTracer. For example, getPlannerTracer() is the
tracer used by all classes which take part in the query planning process.
The javadoc in this file is the primary source of information on what
tracers are available, so the javadoc against each tracer member must be an
up-to-date description of what that tracer does. Be sure to describe what
tracing level is required to obtain each category of tracing.
In the class where the tracer is used, create a private (or
perhaps protected) static final member called
tracer.
| Modifier and Type | Field and Description |
|---|---|
static Logger |
PARSER_LOGGER
The "org.apache.calcite.sql.parser" tracer reports parser events in
SqlParser and other classes (at level
Level.FINE or higher). |
| Constructor and Description |
|---|
CalciteTrace() |
| Modifier and Type | Method and Description |
|---|---|
static ThreadLocal<Function2<Void,File,String>> |
getDynamicHandler()
Thread-local handler that is called with dynamically generated Java code.
|
static Logger |
getParserTracer()
The "org.apache.calcite.sql.parser" tracer reports parse events.
|
static Logger |
getPlannerTracer()
The "org.apache.calcite.plan.RelOptPlanner" tracer prints the query
optimization process.
|
static Logger |
getRelImplementorTracer()
The "org.apache.calcite.rel.RelImplementorImpl" tracer reports when
expressions are bound to variables (
Level.FINE) |
static Logger |
getSqlTimingTracer()
The tracer "org.apache.calcite.sql.timing" traces timing for
various stages of query processing.
|
static Logger |
getSqlToRelTracer()
The "org.apache.calcite.sql2rel" tracer reports parse events.
|
static Logger |
getStatementTracer()
The "org.apache.calcite.prepare.Prepare" tracer prints the generated
program at level
Level.FINE or higher. |
public static final Logger PARSER_LOGGER
SqlParser and other classes (at level
Level.FINE or higher).public static Logger getPlannerTracer()
Levels:
Level.FINE prints rules as they fire;
Level.FINER prints and validates the whole expression pool
and rule queue as each rule fires;
Level.FINEST prints finer details like rule importances.
public static Logger getStatementTracer()
Level.FINE or higher.public static Logger getRelImplementorTracer()
Level.FINE)public static Logger getSqlTimingTracer()
CalciteTimingTracerpublic static Logger getParserTracer()
public static Logger getSqlToRelTracer()
public static ThreadLocal<Function2<Void,File,String>> getDynamicHandler()
Copyright © 2012–2015 The Apache Software Foundation. All rights reserved.