Package org.apache.druid.sql
Class SqlExecutionReporter
java.lang.Object
org.apache.druid.sql.SqlExecutionReporter
Side-car class which reports logs and metrics for an
HttpStatement. This separate class cleanly separates the logic
for running a query from the logic for reporting on that run. A query
can end either with a success or error. This object is created in
the request thread, with the remaining method called either from the
request or response thread, but not both.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidemit()voidReport a query failure with an unknown number of byte written.voidReport a query failure with a known number of byte written.voidplanningTimeNanos(long planningTimeNanos) voidsucceeded(long bytesWritten)
-
Constructor Details
-
SqlExecutionReporter
-
-
Method Details
-
failed
Report a query failure with an unknown number of byte written. ThesqlQuery/bytesmetric will not be emitted. -
failed
Report a query failure with a known number of byte written. It will be emitted assqlQuery/bytes. -
succeeded
public void succeeded(long bytesWritten) -
planningTimeNanos
public void planningTimeNanos(long planningTimeNanos) -
emit
public void emit()
-