apache/druid · warning · UOE
This Jobby does not implement getJobStats(), Jobby class
Error message
This Jobby does not implement getJobStats(), Jobby class: [%s]
What it means
Jobby's default getStats() implementation is a stub that throws UOE. A Jobby implementation that does not override getJobStats()-equivalent stats access causes this error when someone asks for job statistics.
Solutions
- Override getStats() in the Jobby implementation to return the job's stats map.
- Avoid calling getStats() on implementations known not to support stats (or check instanceof a stats-capable type).
- Wrap the call in try-catch for UOE and treat stats as unavailable.
Example fix
// before
class MyJob implements Jobby { /* no getStats */ }
// after
@Override
@Nullable
public Map<String, Object> getStats() { return myStatsMap; } Defensive patterns
Strategy: try-catch
Validate before calling
if (!(job instanceof StatsCapableJobby)) { return null; } Type guard
boolean supportsStats(Object job) { try { job.getClass().getMethod("getStats"); return true; } catch (NoSuchMethodException e) { return false; } } Try / catch
try { stats = job.getStats(); } catch (UOE e) { log.warn("Stats unsupported for {}: {}", job.getClass(), e.getMessage()); stats = null; } Prevention
- Override getStats() in every custom Jobby implementation
- Do not assume all Jobby implementations expose stats
- Default stats to null/absent in monitoring code
When it happens
Trigger: Calling getStats() on a Jobby implementation (e.g. a custom job or one of Druid's simple Jobby implementations) that has not overridden getStats().
Common situations: Custom HadoopDruidIndexer job extensions; monitoring/reporting code that uniformly calls getStats() on all jobs in a JobbyContainer.
Related errors
- This Jobby does not implement getErrorMessage(), Jobby class
- Aggregator[ ] cannot vectorize
- AppenderatorsManager methods should only called by services…
- ApproximateHistogramAggregator does not support getFloat()
- ApproximateHistogramAggregator does not support getDouble()
AI-assisted analysis of apache/druid@9b90983fd2 (2026-09-07).
Data as JSON: /api/errors/edcf418eacfdc14e.
Report an issue: GitHub.
Appendix: source
Thrown at processing/src/main/java/org/apache/druid/indexer/Jobby.java:39
import org.apache.druid.java.util.common.UOE;
import javax.annotation.Nullable;
import java.util.Map;
/**
*/
public interface Jobby
{
boolean run();
/**
* @return A map containing statistics for a Jobby, optionally null if the Jobby is unable to provide stats.
*/
@Nullable
default Map<String, Object> getStats()
{
throw new UOE("This Jobby does not implement getJobStats(), Jobby class: [%s]", getClass());
}
/**
* @return A string representing the error that caused a Jobby to fail. Can be null if the Jobby did not fail,
* or is unable to provide an error message.
*/
@Nullable
default String getErrorMessage()
{
throw new UOE("This Jobby does not implement getErrorMessage(), Jobby class: [%s]", getClass());
}
}
View on GitHub (pinned to 9b90983fd2)