Monitoring System 0.1.0
System resource monitoring with pluggable collectors and alerting
Loading...
Searching...
No Matches
kcenon::monitoring::trace_exporter_factory Class Reference

Factory for creating trace exporters. More...

#include <trace_exporters.h>

Collaboration diagram for kcenon::monitoring::trace_exporter_factory:
Collaboration graph

Static Public Member Functions

static std::unique_ptr< trace_exporter_interfacecreate_exporter (const trace_export_config &config, const otel_resource &resource=create_service_resource("monitoring_system", "2.0.0"))
 Create a trace exporter based on format.
 
static std::vector< trace_export_formatget_supported_formats (const std::string &backend)
 Get supported formats for a specific backend.
 

Detailed Description

Factory for creating trace exporters.

Definition at line 759 of file trace_exporters.h.

Member Function Documentation

◆ create_exporter()

static std::unique_ptr< trace_exporter_interface > kcenon::monitoring::trace_exporter_factory::create_exporter ( const trace_export_config & config,
const otel_resource & resource = create_service_resource("monitoring_system", "2.0.0") )
inlinestatic

Create a trace exporter based on format.

Definition at line 764 of file trace_exporters.h.

766 {
767
768 switch (config.format) {
771 return std::make_unique<jaeger_exporter>(config);
772
775 return std::make_unique<zipkin_exporter>(config);
776
780 return std::make_unique<otlp_exporter>(config, resource);
781
782 default:
783 return nullptr;
784 }
785 }
@ zipkin_json
Zipkin JSON v2 format.
@ jaeger_thrift
Jaeger Thrift protocol.
@ otlp_http_json
OTLP HTTP JSON protocol.
@ otlp_http_protobuf
OTLP HTTP Protocol Buffers.
@ zipkin_protobuf
Zipkin Protocol Buffers format.

References kcenon::monitoring::trace_export_config::format, kcenon::monitoring::jaeger_grpc, kcenon::monitoring::jaeger_thrift, kcenon::monitoring::otlp_grpc, kcenon::monitoring::otlp_http_json, kcenon::monitoring::otlp_http_protobuf, kcenon::monitoring::zipkin_json, and kcenon::monitoring::zipkin_protobuf.

Referenced by TEST_F().

Here is the caller graph for this function:

◆ get_supported_formats()

static std::vector< trace_export_format > kcenon::monitoring::trace_exporter_factory::get_supported_formats ( const std::string & backend)
inlinestatic

Get supported formats for a specific backend.

Definition at line 790 of file trace_exporters.h.

790 {
791 if (backend == "jaeger") {
793 } else if (backend == "zipkin") {
795 } else if (backend == "otlp") {
798 }
799 return {};
800 }

References kcenon::monitoring::jaeger_grpc, kcenon::monitoring::jaeger_thrift, kcenon::monitoring::otlp_grpc, kcenon::monitoring::otlp_http_json, kcenon::monitoring::otlp_http_protobuf, kcenon::monitoring::zipkin_json, and kcenon::monitoring::zipkin_protobuf.

Referenced by TEST_F().

Here is the caller graph for this function:

The documentation for this class was generated from the following file: