Implementation:Apache Druid DoctorDialog
| Knowledge Sources | |
|---|---|
| Domains | Web_Console, Cluster_Health |
| Last Updated | 2026-02-10 10:00 GMT |
Overview
DoctorDialog is a class-based React dialog component that runs automated health checks against a Druid cluster and displays diagnostic results.
Description
The DoctorDialog component presents a "Druid Doctor" interface that iterates through a predefined set of cluster health checks (imported from DOCTOR_CHECKS). Each check can report suggestions, issues, or trigger early termination of the check suite. Results are displayed as BlueprintJS Callout components with appropriate severity icons and intents. A minimum delay of 450ms per check ensures readability of check names during execution.
Usage
Used when an administrator wants to troubleshoot cluster issues by running automated diagnostic checks from the web console.
Code Reference
Source Location
- Repository: Apache Druid
- File: web-console/src/dialogs/doctor-dialog/doctor-dialog.tsx
- Lines: 1-200
Signature
interface Diagnosis {
type: 'suggestion' | 'issue';
check: string;
message: string;
}
export interface DoctorDialogProps {
onClose: () => void;
}
export interface DoctorDialogState {
currentCheckIndex?: number;
diagnoses?: Diagnosis[];
earlyTermination?: string;
}
export class DoctorDialog extends React.PureComponent<DoctorDialogProps, DoctorDialogState>;
Import
import { DoctorDialog } from 'web-console/src/dialogs/doctor-dialog/doctor-dialog';
I/O Contract
Inputs
| Name | Type | Required | Description |
|---|---|---|---|
| onClose | () => void | Yes | Callback invoked when the dialog is closed |
Outputs
| Name | Type | Description |
|---|---|---|
| rendered dialog | JSX.Element | A BlueprintJS Dialog displaying cluster diagnostic results including suggestions, issues, and completion status |
Usage Examples
Basic Usage
<DoctorDialog onClose={() => setShowDoctor(false)} />