Package com.illumon.iris.db.v2.utils
Class AsyncErrorLogger
java.lang.Object
com.illumon.iris.db.v2.utils.AsyncErrorLogger
A static implementation for simple, ephemeral, error recording within a single query. Errors recorded by
InstrumentedListeners
will be appended to an in memory table, which can be retrieved via getErrorLog()-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic DynamicTableGet the in-memory error table.static voidlog(DBDateTime time, UpdatePerformanceTracker.Entry entry, UpdatePerformanceTracker.Entry sourceEntry, Throwable originalException) Write a row describing an error to the error logging table.
-
Constructor Details
-
AsyncErrorLogger
public AsyncErrorLogger()
-
-
Method Details
-
getErrorLog
Get the in-memory error table.- Returns:
- the error
table
-
log
public static void log(@NotNull DBDateTime time, @Nullable UpdatePerformanceTracker.Entry entry, @Nullable UpdatePerformanceTracker.Entry sourceEntry, @NotNull Throwable originalException) throws IOException Write a row describing an error to the error logging table.- Parameters:
time- the time the error occurredentry- theUpdatePerformanceTracker.Entrydescribing the failed operationsourceEntry- the parentUpdatePerformanceTracker.EntryoriginalException- the exception to record- Throws:
IOException- if an error occurs while writing to the table.
-