|Constructor and Description|
|Modifier and Type||Method and Description|
Serializes the given metrics and returns the resulting byte array.
public MetricDumpSerialization.MetricSerializationResult serialize(Map<Counter,Tuple2<QueryScopeInfo,String>> counters, Map<Gauge<?>,Tuple2<QueryScopeInfo,String>> gauges, Map<Histogram,Tuple2<QueryScopeInfo,String>> histograms, Map<Meter,Tuple2<QueryScopeInfo,String>> meters)
Metricaccessed in this method throw an exception it will be omitted from the returned
MetricDumpSerialization.MetricSerializationResult. If the serialization of any primitive or String fails then the returned
MetricDumpSerialization.MetricSerializationResultis partially corrupted. Such a result can be deserialized safely by
MetricDumpDeserializer#deserialize(MetricSerializationResult); however only metrics that were fully serialized before the failure will be returned.
counters- counters to serialize
gauges- gauges to serialize
histograms- histograms to serialize
public void close()
Copyright © 2014–2017 The Apache Software Foundation. All rights reserved.