Documentation
¶
Index ¶
- type MetricSerializer
- type Serializer
- func (s *Serializer) AreSeriesEnabled() bool
- func (s *Serializer) AreSketchesEnabled() bool
- func (s *Serializer) SendAgentShutdownEvent(ctx context.Context, e *event.Event) error
- func (s *Serializer) SendAgentchecksMetadata(m marshaler.JSONMarshaler) error
- func (s *Serializer) SendEvents(events event.Events) error
- func (s *Serializer) SendHostMetadata(m marshaler.JSONMarshaler) error
- func (s *Serializer) SendIterableSeries(serieSource metrics.SerieSource) error
- func (s *Serializer) SendMetadata(m marshaler.JSONMarshaler) error
- func (s *Serializer) SendOrchestratorManifests(msgs []types.ProcessMessageBody, hostName, clusterID string) error
- func (s *Serializer) SendOrchestratorMetadata(msgs []types.ProcessMessageBody, hostName, clusterID string, payloadType int) error
- func (s *Serializer) SendProcessesMetadata(data interface{}) error
- func (s *Serializer) SendServiceChecks(serviceChecks servicecheck.ServiceChecks) error
- func (s *Serializer) SendSketch(sketches metrics.SketchesSource) error
- func (s *Serializer) SketchesV2Domains() []string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MetricSerializer ¶
type MetricSerializer interface {
SendEvents(e event.Events) error
SendServiceChecks(serviceChecks servicecheck.ServiceChecks) error
SendIterableSeries(serieSource metrics.SerieSource) error
AreSeriesEnabled() bool
SendSketch(sketches metrics.SketchesSource) error
AreSketchesEnabled() bool
SendMetadata(m marshaler.JSONMarshaler) error
SendHostMetadata(m marshaler.JSONMarshaler) error
SendProcessesMetadata(data interface{}) error
SendAgentchecksMetadata(m marshaler.JSONMarshaler) error
SendOrchestratorMetadata(msgs []types.ProcessMessageBody, hostName, clusterID string, payloadType int) error
SendOrchestratorManifests(msgs []types.ProcessMessageBody, hostName, clusterID string) error
SendAgentShutdownEvent(ctx context.Context, e *event.Event) error
}
MetricSerializer represents the interface of method needed by the aggregator to serialize its data
type Serializer ¶
type Serializer struct {
Forwarder forwarder.Forwarder
Strategy compression.Compressor
// contains filtered or unexported fields
}
Serializer serializes metrics to the correct format and routes the payloads to the correct endpoint in the Forwarder
func NewSerializer ¶
func NewSerializer(forwarder forwarder.Forwarder, orchestratorForwarder orchestratorForwarder.Component, compressor compression.Compressor, config config.Component, logger log.Component, hostName string) *Serializer
NewSerializer returns a new Serializer initialized
func NewSerializerWithEndpointRouting ¶ added in v0.86.0
func NewSerializerWithEndpointRouting(forwarder forwarder.Forwarder, orchestratorForwarder orchestratorForwarder.Component, compressor compression.Compressor, config config.Component, logger log.Component, hostName string, routing configutils.MetricsEndpointRouting) *Serializer
NewSerializerWithEndpointRouting creates a serializer with endpoint metric filters.
func (*Serializer) AreSeriesEnabled ¶
func (s *Serializer) AreSeriesEnabled() bool
AreSeriesEnabled returns whether series are enabled for serialization
func (*Serializer) AreSketchesEnabled ¶
func (s *Serializer) AreSketchesEnabled() bool
AreSketchesEnabled returns whether sketches are enabled for serialization
func (*Serializer) SendAgentShutdownEvent ¶ added in v0.81.0
SendAgentShutdownEvent serializes and sends the Agent Shutdown lifecycle event through a bounded one-shot forwarder path instead of batching it with ordinary events.
func (*Serializer) SendAgentchecksMetadata ¶
func (s *Serializer) SendAgentchecksMetadata(m marshaler.JSONMarshaler) error
SendAgentchecksMetadata serializes a metadata payload and sends it to the forwarder
func (*Serializer) SendEvents ¶
func (s *Serializer) SendEvents(events event.Events) error
SendEvents serializes a list of event and sends the payload to the forwarder
func (*Serializer) SendHostMetadata ¶
func (s *Serializer) SendHostMetadata(m marshaler.JSONMarshaler) error
SendHostMetadata serializes a metadata payload and sends it to the forwarder
func (*Serializer) SendIterableSeries ¶
func (s *Serializer) SendIterableSeries(serieSource metrics.SerieSource) error
SendIterableSeries serializes a list of series and sends the payload to the forwarder
func (*Serializer) SendMetadata ¶
func (s *Serializer) SendMetadata(m marshaler.JSONMarshaler) error
SendMetadata serializes a metadata payload and sends it to the forwarder
func (*Serializer) SendOrchestratorManifests ¶
func (s *Serializer) SendOrchestratorManifests(msgs []types.ProcessMessageBody, hostName, clusterID string) error
SendOrchestratorManifests serializes & send orchestrator manifest payloads
func (*Serializer) SendOrchestratorMetadata ¶
func (s *Serializer) SendOrchestratorMetadata(msgs []types.ProcessMessageBody, hostName, clusterID string, payloadType int) error
SendOrchestratorMetadata serializes & send orchestrator metadata payloads
func (*Serializer) SendProcessesMetadata ¶
func (s *Serializer) SendProcessesMetadata(data interface{}) error
SendProcessesMetadata serializes a payload and sends it to the forwarder. Used only by the legacy processes metadata collector.
func (*Serializer) SendServiceChecks ¶
func (s *Serializer) SendServiceChecks(serviceChecks servicecheck.ServiceChecks) error
SendServiceChecks serializes a list of serviceChecks and sends the payload to the forwarder
func (*Serializer) SendSketch ¶
func (s *Serializer) SendSketch(sketches metrics.SketchesSource) error
SendSketch serializes a list of SketSeriesList and sends the payload to the forwarder
func (*Serializer) SketchesV2Domains ¶ added in v0.86.0
func (s *Serializer) SketchesV2Domains() []string
SketchesV2Domains returns the configured domains that sketches are sent to over the v2 intake, which cannot carry OpenTelemetry histograms. It uses the same routing as SendSketch, but counts the MRF domain even while failover is off, since failover can be turned on later. The names are the ones matched against use_v3_api.distributions.endpoints.