Summary
When running the DataSQRL test runner, the following warning appears on every Flink task startup:
WARN org.apache.iceberg.flink.sink.IcebergStreamWriterMetrics - Cannot load Dropwizard metrics; is org.apache.flink:flink-metrics-dropwizard on the classpath?
java.lang.NoSuchMethodException: Cannot find constructor for interface org.apache.flink.metrics.Histogram
Missing org.apache.flink.dropwizard.metrics.DropwizardHistogramWrapper [java.lang.ClassNotFoundException: ...]
Root Cause
IcebergStreamWriterMetrics attempts to load org.apache.flink.dropwizard.metrics.DropwizardHistogramWrapper in a static initializer. The class is absent because flink-metrics-dropwizard is not included in the test runner classpath/fat-jar.
Impact
- Severity: Low — the sink falls back gracefully and ingestion is unaffected.
- Effect: Histogram metrics (write latency, file size distributions, etc.) from the Iceberg sink are silently unavailable.
- Noise: The WARN pollutes test runner logs on every task startup.
Fix
Add flink-metrics-dropwizard as a runtime dependency, matching the Flink version in use:
<dependency>
<groupId>org.apache.flink</groupId>
<artifactId>flink-metrics-dropwizard</artifactId>
<version>${flink.version}</version>
<scope>runtime</scope>
</dependency>
Environment
- Observed:
2026-06-23 15:10:01
- Operator:
SourceIngestionStats: Writer (1/1)#0
- Failing class:
org.apache.iceberg.flink.sink.IcebergStreamWriterMetrics
Summary
When running the DataSQRL test runner, the following warning appears on every Flink task startup:
Root Cause
IcebergStreamWriterMetricsattempts to loadorg.apache.flink.dropwizard.metrics.DropwizardHistogramWrapperin a static initializer. The class is absent becauseflink-metrics-dropwizardis not included in the test runner classpath/fat-jar.Impact
Fix
Add
flink-metrics-dropwizardas a runtime dependency, matching the Flink version in use:Environment
2026-06-23 15:10:01SourceIngestionStats: Writer (1/1)#0org.apache.iceberg.flink.sink.IcebergStreamWriterMetrics