ExportingReader
in package
implements
MetricReaderInterface, MetricSourceRegistryInterface, MetricSourceRegistryUnregisterInterface, DefaultAggregationProviderInterface
uses
DefaultAggregationProviderTrait
FinalYes
Table of Contents
Interfaces
- MetricReaderInterface
- MetricSourceRegistryInterface
- MetricSourceRegistryUnregisterInterface
- DefaultAggregationProviderInterface
Properties
- $closed : bool
- $exporter : MetricExporterInterface
- $registries : array<int, MetricCollectorInterface>
- $sources : array<int, MetricSourceInterface>
- $streamIds : array<int, array<int, array<int, int>>>
Methods
- __construct() : mixed
- add() : void
- collect() : bool
- defaultAggregation() : AggregationInterface|null
- forceFlush() : bool
- shutdown() : bool
- unregisterStream() : void
- doCollect() : bool
Properties
$closed
private
bool
$closed
= false
$exporter read-only
private
MetricExporterInterface
$exporter
$registries
private
array<int, MetricCollectorInterface>
$registries
= []
$sources
private
array<int, MetricSourceInterface>
$sources
= []
$streamIds
private
array<int, array<int, array<int, int>>>
$streamIds
= []
Methods
__construct()
public
__construct(MetricExporterInterface $exporter) : mixed
Parameters
- $exporter : MetricExporterInterface
add()
public
add(MetricSourceProviderInterface $provider, MetricMetadataInterface $metadata, StalenessHandlerInterface $stalenessHandler) : void
Parameters
- $provider : MetricSourceProviderInterface
- $metadata : MetricMetadataInterface
- $stalenessHandler : StalenessHandlerInterface
collect()
public
collect() : bool
Return values
booldefaultAggregation()
public
defaultAggregation(mixed $instrumentType[, array<string|int, mixed> $advisory = [] ]) : AggregationInterface|null
Parameters
- $instrumentType : mixed
- $advisory : array<string|int, mixed> = []
Return values
AggregationInterface|nullforceFlush()
public
forceFlush() : bool
Return values
boolshutdown()
public
shutdown() : bool
Return values
boolunregisterStream()
public
unregisterStream(MetricCollectorInterface $collector, int $streamId) : void
Parameters
- $collector : MetricCollectorInterface
- $streamId : int
doCollect()
private
doCollect() : bool