public class CodahaleCsvSink
extends java.lang.Object
implements org.apache.spark.metrics.sink.Sink
Sink
for Spark's
metric system reporting metrics (including Beam step metrics) to a CSV file.
The sink is configured using Spark configuration parameters, for example:
"spark.metrics.conf.*.sink.csv.class"="org.apache.beam.runners.spark.structuredstreaming.metrics.sink.CodahaleCsvSink"
"spark.metrics.conf.*.sink.csv.directory"="<output_directory>"
"spark.metrics.conf.*.sink.csv.period"=10
"spark.metrics.conf.*.sink.csv.unit"=seconds
Constructor and Description |
---|
CodahaleCsvSink(java.util.Properties properties,
com.codahale.metrics.MetricRegistry metricRegistry)
Constructor for Spark 3.2.x and later.
|
CodahaleCsvSink(java.util.Properties properties,
com.codahale.metrics.MetricRegistry metricRegistry,
org.apache.spark.SecurityManager securityMgr)
Constructor for Spark 3.1.x and earlier.
|
Modifier and Type | Method and Description |
---|---|
void |
report() |
void |
start() |
void |
stop() |
public CodahaleCsvSink(java.util.Properties properties, com.codahale.metrics.MetricRegistry metricRegistry, org.apache.spark.SecurityManager securityMgr)
public CodahaleCsvSink(java.util.Properties properties, com.codahale.metrics.MetricRegistry metricRegistry)